simone / django-compositekey

Django Composite Multiple PrimaryKey
77 stars 16 forks source link

ValueError: need more than 5 values to unpack #32

Closed liangent closed 10 years ago

liangent commented 10 years ago
Traceback (most recent call last):
  File "<console>", line 1, in <module>
  File "/usr/lib/python2.7/dist-packages/django/db/models/query.py", line 71, in __repr__
    data = list(self[:REPR_OUTPUT_SIZE + 1])
  File "/usr/lib/python2.7/dist-packages/django/db/models/query.py", line 96, in __iter__
    self._fetch_all()
  File "/usr/lib/python2.7/dist-packages/django/db/models/query.py", line 857, in _fetch_all
    self._result_cache = list(self.iterator())
  File "/usr/local/lib/python2.7/dist-packages/compositekey/db/models/query.py", line 155, in iterator
    for row in compiler.results_iter():
  File "/usr/lib/python2.7/dist-packages/django/db/models/sql/compiler.py", line 713, in results_iter
    for rows in self.execute_sql(MULTI):
  File "/usr/lib/python2.7/dist-packages/django/db/models/sql/compiler.py", line 776, in execute_sql
    sql, params = self.as_sql()
  File "/usr/lib/python2.7/dist-packages/django/db/models/sql/compiler.py", line 84, in as_sql
    ordering, o_params, ordering_group_by = self.get_ordering()
  File "/usr/lib/python2.7/dist-packages/django/db/models/sql/compiler.py", line 403, in get_ordering
    self.query.get_meta(), default_order=asc):
  File "/usr/lib/python2.7/dist-packages/django/db/models/sql/compiler.py", line 437, in find_ordering_name
    field, cols, alias, joins, opts = self._setup_joins(pieces, opts, alias)
  File "/usr/local/lib/python2.7/dist-packages/compositekey/db/models/sql/compiler.py", line 90, in _setup_joins
    opts, alias, False)
ValueError: need more than 5 values to unpack

django-compositekey from pip:

Name: django-compositekey
Version: 1.5.0

Django from Debian:

Package: python-django                   
State: installed
Automatically installed: no
Version: 1.6.6-1
simone commented 10 years ago

Hi django-compositekey 1.5.0 is not compaible with Django 1.6

django-compositekey 1.5.0 is compatible with Django 1.5.x django-compositekey 1.4.0 is compatible with Django 1.4.x

Composite Key for Django 1.6 actually is under development.