[Django]-Raise ImproperlyConfigured, exc_info[1], exc_info[2]

9👍

django-mongodb-engine does not support Python 3.x.

Categories

Programming Language :: Python :: 2.5
Programming Language :: Python :: 2.6
Programming Language :: Python :: 2.7

Meaning of the error:

Syntax for the raise statement changed in Python 3.x. raise expression, expression, expression syntax is not valid in Python 3.x.

>>> raise ValueError, 'msg'
  File "<stdin>", line 1
    raise ValueError, 'msg'
                    ^
SyntaxError: invalid syntax

>>> raise ValueError('msg')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ValueError: msg

Leave a comment