django-dajaxice
django-dajaxice copied to clipboard
updatecombo() takes exactly 2 arguments (1 given)
I encountered the same problem in the current build with an example from the site! http://www.dajaxproject.com/fullform/
my code http://pastie.org/7721130
error: Internal Server Error: /dajaxice/teacher_constructor.updatecombo/ Traceback (most recent call last): File "/usr/local/lib/python3.2/dist-packages/django/core/handlers/base.py", line 115, in get_response response = callback(request, _callback_args, *_callback_kwargs) File "/usr/local/lib/python3.2/dist-packages/django/views/generic/base.py", line 68, in view return self.dispatch(request, _args, *_kwargs) File "/usr/local/lib/python3.2/dist-packages/dajaxice/views.py", line 52, in dispatch response = function.call(request, *_data) File "/usr/local/lib/python3.2/dist-packages/dajaxice/core/Dajaxice.py", line 18, in call return self.function(_args, **kwargs) TypeError: updatecombo() takes exactly 2 arguments (1 given)
but
LOCALE_INDEPENDENT_PATHS = (
compile('^/dajaxice/'),
)
doesn't help
File "/usr/local/lib/python3.2/dist-packages/django/conf/init.py", line 47, in _setup
self._wrapped = Settings(settings_module)
File "/usr/local/lib/python3.2/dist-packages/django/conf/init.py", line 130, in init
mod = importlib.import_module(self.SETTINGS_MODULE)
File "/usr/local/lib/python3.2/dist-packages/django/utils/importlib.py", line 35, in import_module
import(name)
File "/media/D/projects/InnoPract/workrepo/edplatform/edplatform/settings.py", line 170, in
And such problem appers not only with this example! python3, django 5, the last dajax
Please, explain why it happens and what to do!
I found this issue googling for "TypeError: Required argument 'filename' (pos 2) not found", when calling compile()
outside a Django project, ie. with the compile()
function from Python's builtin functions.
You should probably fix your import to use Django's compile
instead of the default one.