Opened 11 years ago

Closed 11 years ago

#22025 closed Bug (fixed)

TypeError in the dumpdata command when listing "app app.Model"

Reported by: eliben@… Owned by: nobody
Component: Core (Management commands) Version: dev
Severity: Normal Keywords:
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: yes Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

When running:

$ python manage.py dumpdata  blogapp blogapp.Tag

I get:

Traceback (most recent call last):
  File "manage.py", line 10, in <module>
    execute_from_command_line(sys.argv)
  ...
  ...
TypeError: argument of type 'NoneType' is not iterable

A fix is in this pull request: https://github.com/django/django/pull/2262

Change History (4)

comment:1 by Baptiste Mispelon, 11 years ago

Needs tests: set
Triage Stage: UnreviewedAccepted

Hi,

I can indeed reproduce the issue.

The pull request looks reasonable but you'll need to add some tests for it to be merged.

Thanks

comment:2 by anonymous, 11 years ago

Added a test in the pull request.

in reply to:  2 comment:3 by eliben, 11 years ago

Replying to anonymous:

Added a test in the pull request.

Sorry, logged in now.

comment:4 by Baptiste Mispelon <bmispelon@…>, 11 years ago

Resolution: fixed
Status: newclosed

In 73f51e411372ba3e74ccf5a2c2be88927ac2c6dd:

Fixed #22025 -- Listing app followed by app.Model in dumpdata command

When invoked as follows:

$ python manage.py dumpdata blogapp blogapp.Tag

Django would throw a TypeError. This commit fixes the problem and provides
a test.

Note: See TracTickets for help on using tickets.
Back to Top