I have avoided the issue in the short term by not using ATOMIC_REQUESTS and going back to the 1.5 transaction middleware. What could possibly be in my code or project that does not sit well with ATOMIC_REQUESTS?
-- -Tim
On Monday, June 2, 2014 1:50:40 PM UTC-7, Tim Zenderman wrote:
On Monday, June 2, 2014 1:50:40 PM UTC-7, Tim Zenderman wrote:
It seems that after updating to 1.6, we are running into an InterfaceError on different views at random times. I found the some older tickets below where the issues is apparently resolved, but it's not in my case. Could this be related to the ATOMIC setting for postgres? What could I be doing in my code that is screwing with the DB connection?The full stack trace is below. It seems to be happening while the request is starting that the DB connection has already been closed?We are running this on:Ubuntu 12.04Django 1.6.5Psycopg 2.5.3File "django/core/handlers/base.py", line 88, in get_response response = middleware_method(request)File "django/middleware/locale.py", line 32, in process_requestrequest, check_path=check_path)File "django/utils/translation/__init__.py", line 166, in get_language_from_request return _trans.get_language_from_request(request, check_path) File "django/utils/translation/trans_real.py", line 430, in get_language_from_request lang_code = request.session.get('django_language', None) File "django/contrib/sessions/backends/base.py", line 58, in get return self._session.get(key, default)File "django/contrib/sessions/backends/base.py", line 173, in _get_session self._session_cache = self.load()File "django/contrib/sessions/backends/db.py", line 20, in load expire_date__gt=timezone.now()File "django/db/models/manager.py", line 151, in getreturn self.get_queryset().get(*args, **kwargs)File "django/db/models/query.py", line 304, in getnum = len(clone)File "django/db/models/query.py", line 77, in __len__self._fetch_all()File "django/db/models/query.py", line 857, in _fetch_allself._result_cache = list(self.iterator())File "django/db/models/query.py", line 220, in iteratorfor row in compiler.results_iter():File "django/db/models/sql/compiler.py", line 713, in results_iter for rows in self.execute_sql(MULTI):File "django/db/models/sql/compiler.py", line 785, in execute_sql cursor = self.connection.cursor()File "django/db/backends/__init__.py", line 162, in cursor cursor = util.CursorWrapper(self._cursor(), self) File "django/db/backends/__init__.py", line 134, in _cursor return self.create_cursor()File "django/db/utils.py", line 99, in __exit__six.reraise(dj_exc_type, dj_exc_value, traceback)File "django/db/backends/__init__.py", line 134, in _cursor return self.create_cursor()File "django/db/backends/postgresql_psycopg2/base.py", line 137, in create_cursor cursor = self.connection.cursor()Thanks!Tim
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+unsubscribe@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/a64aaa4e-568a-45f0-9201-a60b35c7f973%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
No comments:
Post a Comment