Thanks for the swift reply. The problem starts with Django 1.8.0. My test 
suite passes on all 1.7.x versions.

On Friday, July 10, 2015 at 2:32:25 PM UTC+1, Tim Graham wrote:
>
> No ideas, but if you could bisect to find the Django commit where the 
> problem started to appear that will probably help.
>
> On Friday, July 10, 2015 at 7:21:37 AM UTC-4, tom.sz...@eporta.com wrote:
>>
>> Hi,
>>
>> I've recently tried upgrading from Django 1.7.6 to 1.8.3 but haven't been 
>> able to get my test suite to pass.
>>
>> My main problem is that all of the tests pass when run individually, but 
>> when run as an entire test suite, many arbitraily fail due to an 
>> *InterfaceError: 
>> connection already closed*:
>>
>>   File 
>> "/usr/local/lib/python2.7/dist-packages/django/db/models/sql/compiler.py"
>> , line 838, in execute_sql
>>     cursor = self.connection.cursor()
>>   File 
>> "/usr/local/lib/python2.7/dist-packages/django/db/backends/base/base.py", 
>> line 164, in cursor
>>     cursor = self.make_cursor(self._cursor())
>>   File 
>> "/usr/local/lib/python2.7/dist-packages/django/db/backends/base/base.py", 
>> line 137, in _cursor
>>     return self.create_cursor()
>>   File "/usr/local/lib/python2.7/dist-packages/django/db/utils.py", line 
>> 97, in __exit__
>>     six.reraise(dj_exc_type, dj_exc_value, traceback)
>>   File 
>> "/usr/local/lib/python2.7/dist-packages/django/db/backends/base/base.py", 
>> line 137, in _cursor
>>     return self.create_cursor()
>>   File 
>> "/usr/local/lib/python2.7/dist-packages/django/db/backends/postgresql_psycopg2/base.py"
>> , line 212, in create_cursor
>>     cursor = self.connection.cursor()
>> InterfaceError: connection already closed
>>
>>
>>
>> I was previously using psycopg2.6 with Postgres 9.3 and have tried 
>> upgrading to psycopg2.6.1 with Postgres 9.4, but this hasn't helped.
>>
>> Forcing all my TestCase classes to inherit from SimpleTestCase resolves 
>> this issue, but inheriting from SimpleTestCase isn't something that I wish 
>> to do.
>>
>> Any help would be much appreciated.
>>
>> Thanks,
>>
>> Tom
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/a903c1be-f53a-452f-8e08-28b637d05df9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to