the command I used was
python manage.py inspectdb > all_models.py
the error I got was:
File "/xxx/env/lib/python3.5/site-
packages/django/core/management/commands/inspectdb.py", line 278, in
<genexpr>
tup = '(' + ', '.join("'%s'" % column_to_field_name[c] for c in
columns) + ')'
KeyError: None
--
Ticket URL: <https://code.djangoproject.com/ticket/27533>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
Comment (by Wei Ma):
I created a PR https://github.com/django/django/pull/7618 for this bug.
--
Ticket URL: <https://code.djangoproject.com/ticket/27533#comment:1>
Comment (by Max Resnick):
Adding "Needs Tests" flag per PR
Comment[https://github.com/django/django/pull/7618#issuecomment-263023058]
--
Ticket URL: <https://code.djangoproject.com/ticket/27533#comment:2>
* stage: Unreviewed => Accepted
* component: Core (Other) => Database layer (models, ORM)
* needs_tests: 0 => 1
--
Ticket URL: <https://code.djangoproject.com/ticket/27533#comment:3>
Comment (by Wei Ma):
I have closed my PR https://github.com/django/django/pull/7618 due to not
able to create test cases. If anyone want to help, please fork my repo
and add needed tests.
--
Ticket URL: <https://code.djangoproject.com/ticket/27533#comment:4>
* owner: nobody => Michael Sinov
* status: new => assigned
* needs_tests: 1 => 0
Comment:
[https://github.com/django/django/pull/7683 PR]
--
Ticket URL: <https://code.djangoproject.com/ticket/27533#comment:5>
* needs_better_patch: 0 => 1
* has_patch: 1 => 0
--
Ticket URL: <https://code.djangoproject.com/ticket/27533#comment:6>
* has_patch: 0 => 1
--
Ticket URL: <https://code.djangoproject.com/ticket/27533#comment:7>
* status: assigned => closed
* resolution: => fixed
Comment:
In [changeset:"9aca67bea8d42e6c1889f16e5ce297cfc23b91a2" 9aca67be]:
{{{
#!CommitTicketReference repository=""
revision="9aca67bea8d42e6c1889f16e5ce297cfc23b91a2"
Fixed #27533 -- Fixed inspectdb crash if a unique constraint uses an
unsupported type.
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/27533#comment:8>