﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
11764	Bugfix: typo with avoid.update(..) in  db/models/sql/compiler.py:SQLCompiler:fill_related_selections	Aurelio Tinio	Ramiro Morales	"There looks to be a bug due to a typo in db/models/sql/query.py .

The issue became apparent when it prevented the display of a ForeignKey field in list_display, when there is another ForeignKey to the base class of the model with the following error displayed:

{{{

Caught an exception while rendering: update() takes exactly one argument (2 given)

Original Traceback (most recent call last):
  File ""/tippit/django-projects/django/Django-1.1/django/template/debug.py"", line 71, in render_node
    result = node.render(context)
  File ""/tippit/django-projects/django/Django-1.1/django/template/__init__.py"", line 936, in render
    dict = func(*args)
  File ""/tippit/django-projects/django/Django-1.1/django/contrib/admin/templatetags/admin_list.py"", line 253, in result_list
    'results': list(results(cl))}
  File ""/tippit/django-projects/django/Django-1.1/django/contrib/admin/templatetags/admin_list.py"", line 247, in results
    for res in cl.result_list:
  File ""/tippit/django-projects/django/Django-1.1/django/db/models/query.py"", line 106, in _result_iter
    self._fill_cache()
  File ""/tippit/django-projects/django/Django-1.1/django/db/models/query.py"", line 692, in _fill_cache
    self._result_cache.append(self._iter.next())
  File ""/tippit/django-projects/django/Django-1.1/django/db/models/query.py"", line 238, in iterator
    for row in self.query.results_iter():
  File ""/tippit/django-projects/django/Django-1.1/django/db/models/sql/query.py"", line 287, in results_iter
    for rows in self.execute_sql(MULTI):
  File ""/tippit/django-projects/django/Django-1.1/django/db/models/sql/query.py"", line 2360, in execute_sql
    sql, params = self.as_sql()
  File ""/tippit/django-projects/django/Django-1.1/django/db/models/sql/query.py"", line 395, in as_sql
    self.pre_sql_setup()
  File ""/tippit/django-projects/django/Django-1.1/django/db/models/sql/query.py"", line 589, in pre_sql_setup
    self.fill_related_selections()
  File ""/tippit/django-projects/django/Django-1.1/django/db/models/sql/query.py"", line 1401, in fill_related_selections
    ())
TypeError: update() takes exactly one argument (2 given)
}}}






A patch has been attached applied against changeset 11475."		closed	Database layer (models, ORM)	dev		fixed		django@…	Ready for checkin	1	0	0	0	0	0
