Opened 8 years ago

Closed 7 years ago

Last modified 7 years ago

#6128 closed (duplicate)

Unable to register commands from apps inside the project

Reported by: petrilli Owned by: nobody
Component: Uncategorized Version: master
Severity: Keywords:
Cc: Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

In trying to get the django_evolution application to work, I initially tried installing the application inside my project directory, and then adding it to my INSTALLED_APPS. This would allow the syncdb command to see the necessary actions, however the commands that it registered (./manage.py evolve) never would work. After talking to the mailing list, I moved it to somewhere else on my PYTHON_PATH and adjusted INSTALLED_APPS and now it works. It was believed that this was a known issue, however I can't find anything that seems to apply. The closest was #5212.

This is on SVN at changeset [6894] on Mac OS X 10.5 w/Python 2.5.1.

Change History (6)

comment:1 Changed 8 years ago by russellm

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Triage Stage changed from Unreviewed to Accepted

Just to clarify the details here: The situation is a project called 'myproject', with an application called 'myapp' that registers a user-space management command.

If your PYTHONPATH is set up such that INSTALLED_APPS contains 'myproject.myapp', the user command won't be discovered, even though other management behaviour, such as post-syncdb registered signals, will occur.

If PYTHONPATH is set up such that INSTALLED_APPS contains 'myapp', the command will be registered successfully.

comment:2 follow-up: Changed 8 years ago by jdetaeye

I think ticket #6128 describes the same issue.

comment:3 in reply to: ↑ 2 Changed 8 years ago by jdetaeye

Correction... I meant #5825.

comment:4 follow-up: Changed 7 years ago by Collin Grady <cgrady@…>

If it helps at all with tracking it down, this isn't a global issue - I have no trouble using custom management commands from an app that's inside a project, and in INSTALLED_APPS as 'myproject.myapp'

comment:5 Changed 7 years ago by anonymous

  • Resolution set to duplicate
  • Status changed from new to closed

duplicate of #5825

comment:6 in reply to: ↑ 4 Changed 7 years ago by dusty@…

Replying to Collin Grady <cgrady@the-magi.us>:

If it helps at all with tracking it down, this isn't a global issue - I have no trouble using custom management commands from an app that's inside a project, and in INSTALLED_APPS as 'myproject.myapp'

Indeed, we encountered this bug on our project but it doesn't occur for all developers. The only difference between the two setups that we found so far is that python2.5.1 works and python2.5.2 does not.

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