#12764: views tests fail with psycopg1 backend
------------------------------------------+---------------------------------
Reporter: kmtracey | Owner: nobody
Status: new | Milestone: 1.2
Component: Database layer (models, ORM) | Version: SVN
Keywords: | Stage: Unreviewed
Has_patch: 0 |
------------------------------------------+---------------------------------
2 of 39 tests fail, reason looks to be the same for both:
{{{
.........E...E.........................
======================================================================
ERROR: test_bad_content_type
(regressiontests.views.tests.defaults.DefaultsTests)
----------------------------------------------------------------------
Traceback (most recent call last):
File
"D:\u\kmt\django\trunk\tests\regressiontests\views\tests\defaults.py",
line 47, in test_bad_content_type
response = self.client.get(short_url)
File "d:\u\kmt\django\trunk\django\test\client.py", line 286, in get
response = self.request(**r)
File "d:\u\kmt\django\trunk\django\core\handlers\base.py", line 101, in
get_response
response = callback(request, *callback_args, **callback_kwargs)
File "d:\u\kmt\django\trunk\django\views\defaults.py", line 35, in
shortcut
return real_shortcut(request, content_type_id, object_id)
File "d:\u\kmt\django\trunk\django\contrib\contenttypes\views.py", line
10, in shortcut
content_type = ContentType.objects.get(pk=content_type_id)
File "d:\u\kmt\django\trunk\django\db\models\manager.py", line 132, in
get
return self.get_query_set().get(*args, **kwargs)
File "d:\u\kmt\django\trunk\django\db\models\query.py", line 334, in get
num = len(clone)
File "d:\u\kmt\django\trunk\django\db\models\query.py", line 79, in
__len__
self._result_cache = list(self.iterator())
File "d:\u\kmt\django\trunk\django\db\models\query.py", line 267, in
iterator
for row in compiler.results_iter():
File "d:\u\kmt\django\trunk\django\db\models\sql\compiler.py", line 685,
in results_iter
for rows in self.execute_sql(MULTI):
File "d:\u\kmt\django\trunk\django\db\models\sql\compiler.py", line 740,
in execute_sql
cursor.execute(sql, params)
File "d:\u\kmt\django\trunk\django\db\backends\postgresql\base.py", line
57, in execute
return self.cursor.execute(smart_str(sql, self.charset),
self.format_params(params))
DatabaseError: ERROR: value "4242424242" is out of range for type integer
SELECT "django_content_type"."id", "django_content_type"."name",
"django_content_type"."app_label", "django_content_type
"."model" FROM "dja
======================================================================
ERROR: test_shortcut_bad_pk
(regressiontests.views.tests.defaults.DefaultsTests)
----------------------------------------------------------------------
Traceback (most recent call last):
File
"D:\u\kmt\django\trunk\tests\regressiontests\views\tests\defaults.py",
line 35, in test_shortcut_bad_pk
response = self.client.get(short_url)
File "d:\u\kmt\django\trunk\django\test\client.py", line 286, in get
response = self.request(**r)
File "d:\u\kmt\django\trunk\django\core\handlers\base.py", line 101, in
get_response
response = callback(request, *callback_args, **callback_kwargs)
File "d:\u\kmt\django\trunk\django\views\defaults.py", line 35, in
shortcut
return real_shortcut(request, content_type_id, object_id)
File "d:\u\kmt\django\trunk\django\contrib\contenttypes\views.py", line
11, in shortcut
obj = content_type.get_object_for_this_type(pk=object_id)
File "d:\u\kmt\django\trunk\django\contrib\contenttypes\models.py", line
102, in get_object_for_this_type
return
self.model_class()._default_manager.using(self._state.db).get(**kwargs)
File "d:\u\kmt\django\trunk\django\db\models\query.py", line 334, in get
num = len(clone)
File "d:\u\kmt\django\trunk\django\db\models\query.py", line 79, in
__len__
self._result_cache = list(self.iterator())
File "d:\u\kmt\django\trunk\django\db\models\query.py", line 267, in
iterator
for row in compiler.results_iter():
File "d:\u\kmt\django\trunk\django\db\models\sql\compiler.py", line 685,
in results_iter
for rows in self.execute_sql(MULTI):
File "d:\u\kmt\django\trunk\django\db\models\sql\compiler.py", line 740,
in execute_sql
cursor.execute(sql, params)
File "d:\u\kmt\django\trunk\django\db\backends\postgresql\base.py", line
57, in execute
return self.cursor.execute(smart_str(sql, self.charset),
self.format_params(params))
DatabaseError: ERROR: value "4242424242" is out of range for type integer
SELECT "views_author"."id", "views_author"."name" FROM "views_author"
WHERE "views_author"."id" = '4242424242'
----------------------------------------------------------------------
Ran 39 tests in 20.800s
FAILED (errors=2)
Destroying test database 'default'...
Destroying test database 'other'...
}}}
--
Ticket URL: <http://code.djangoproject.com/ticket/12764>
Django <http://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en.