#7684: Strange import problem since upgrading to newforms-admin
---------------------------+------------------------------------------------
Reporter: julien | Owner: nobody
Status: new | Milestone:
Component: Uncategorized | Version: SVN
Keywords: | Stage: Unreviewed
Has_patch: 0 |
---------------------------+------------------------------------------------
*Please note*: I know this may look like it belongs to the user mailing
list, but in [1] we thought Trac would be a better place for it.
I'm having a strange import issue since I have upgraded my project to NFA.
To illustrate the issue I've attached a ZIP with very simple code.
Basically, the project won't run (that is, when the server is restarted
and tries to launch Django). I get the error: "ImportError: cannot import
name MenuItem".
Now, what is very strange here, is that I can get rid of the error in two
different ways:
1) Either by swapping the order of the apps in INSTALLED_APPS:
From:
{{{
INSTALLED_APPS = (
'menu',
'menu_extension',
)
}}}
To:
{{{
INSTALLED_APPS = (
'menu_extension',
'menu',
)
}}}
2) Or by Removing the ugettext call in menu.models:
From:
{{{
caption = models.CharField(_('Caption'), max_length=50)
}}}
To:
{{{
caption = models.CharField('Caption', max_length=50)
}}}
Weird! Does that example uncover a bug in Django or rather my misuse of
Python and/or NFA?
I'm using newforms-admin-SVN-7871.
[1] http://groups.google.com/group/django-
users/browse_thread/thread/9427e8e78b199441#
--
Ticket URL: <http://code.djangoproject.com/ticket/7684>
Django Code <http://code.djangoproject.com/>
The web framework for perfectionists with deadlines
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---