public
Created

test

  • Download Gist
traceback
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65
Creating test database for alias 'default'...
E
======================================================================
ERROR: test_register_save (jobs.tests.TagSaveAndLoadTest)
----------------------------------------------------------------------
Traceback (most recent call last):
File "E:\ev\site\project\jobs\tests.py", line 24, in test_register_save
response = self.client.post('/register/save_tags/', {'skilltags' : json.dump
s(tag_dict)})
File "C:\Python27\lib\site-packages\django\test\client.py", line 455, in post
response = super(Client, self).post(path, data=data, content_type=content_ty
pe, **extra)
File "C:\Python27\lib\site-packages\django\test\client.py", line 256, in post
return self.request(**r)
File "C:\Python27\lib\site-packages\django\core\handlers\base.py", line 111, i
n get_response
response = callback(request, *callback_args, **callback_kwargs)
File "C:\Python27\lib\site-packages\django\views\generic\base.py", line 47, in
view
return self.dispatch(request, *args, **kwargs)
File "C:\Python27\lib\site-packages\django\views\generic\base.py", line 68, in
dispatch
return handler(request, *args, **kwargs)
File "E:\ev\site\project\..\project\jobs\views.py", line 69, in post
Skill.objects.filter(user=request.user).delete()
File "C:\Python27\lib\site-packages\django\db\models\manager.py", line 141, in
filter
return self.get_query_set().filter(*args, **kwargs)
File "C:\Python27\lib\site-packages\django\db\models\query.py", line 550, in f
ilter
return self._filter_or_exclude(False, *args, **kwargs)
File "C:\Python27\lib\site-packages\django\db\models\query.py", line 568, in _
filter_or_exclude
clone.query.add_q(Q(*args, **kwargs))
File "C:\Python27\lib\site-packages\django\db\models\sql\query.py", line 1172,
in add_q
can_reuse=used_aliases, force_having=force_having)
File "C:\Python27\lib\site-packages\django\db\models\sql\query.py", line 1107,
in add_filter
connector)
File "C:\Python27\lib\site-packages\django\db\models\sql\where.py", line 67, i
n add
value = obj.prepare(lookup_type, value)
File "C:\Python27\lib\site-packages\django\db\models\sql\where.py", line 316,
in prepare
return self.field.get_prep_lookup(lookup_type, value)
File "C:\Python27\lib\site-packages\django\db\models\fields\related.py", line
136, in get_prep_lookup
return self._pk_trace(value, 'get_prep_lookup', lookup_type)
File "C:\Python27\lib\site-packages\django\db\models\fields\related.py", line
209, in _pk_trace
v = getattr(field, prep_func)(lookup_type, v, **kwargs)
File "C:\Python27\lib\site-packages\django\db\models\fields\__init__.py", line
292, in get_prep_lookup
return self.get_prep_value(value)
File "C:\Python27\lib\site-packages\django\db\models\fields\__init__.py", line
479, in get_prep_value
return int(value)
TypeError: int() argument must be a string or a number, not 'AnonymousUser'
 
----------------------------------------------------------------------
Ran 1 test in 0.388s
 
FAILED (errors=1)
Destroying test database for alias 'default'...

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.