Re: warning: Not importing directory
Thanks alot for the answer. Its going in the right direction! There is nothing directly going to a 'locale' folder in pythonpath. Indirectly, there are 'locale' folders inside these: C:\Python25\Lib\site-packages\django_cms-2.0.2-py2.5.egg\cms and C:\Python25\Lib\site-packages\blocks These were created after I installed django-cms and django-blocks. Both installations required certain folders to be put in the pythonpath. I've removed everything except c:\python25;c:\python25\scripts\; from my pythonpath. Fortunately my current projects dont use CMS or blocks. On Jan 7, 7:56 pm, Tom Evanswrote: > On Thu, Jan 7, 2010 at 10:41 AM, Delacroy Systems > > > > wrote: > > If I create an __init__.py, I get this: > > 'import site' failed; use -v for traceback > > Traceback (most recent call last): > > File "manage.py", line 2, in > > from django.core.management import execute_manager > > File "c:\python25\Lib\site-packages\django\core\management > > \__init__.py", line > > 3, in > > from optparse import OptionParser, NO_DEFAULT > > File "C:\Python25\lib\optparse.py", line 404, in > > _builtin_cvt = { "int" : (_parse_int, _("integer")), > > File "C:\Python25\lib\gettext.py", line 566, in gettext > > return dgettext(_current_domain, message) > > File "C:\Python25\lib\gettext.py", line 530, in dgettext > > codeset=_localecodesets.get(domain)) > > File "C:\Python25\lib\gettext.py", line 465, in translation > > mofiles = find(domain, localedir, languages, all=1) > > File "C:\Python25\lib\gettext.py", line 437, in find > > for nelang in _expand_lang(lang): > > File "C:\Python25\lib\gettext.py", line 131, in _expand_lang > > from locale import normalize > > ImportError: cannot import name normalize > > Do you have some package which is clobbering the python supplied > 'locale' package? Eg, a folder called 'locale' on your python path? > > locale.normalize has been part of python since 2.0 according to the docs. > > Cheers > > Tom -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
Re: warning: Not importing directory
On Thu, Jan 7, 2010 at 10:41 AM, Delacroy Systemswrote: > If I create an __init__.py, I get this: > 'import site' failed; use -v for traceback > Traceback (most recent call last): > File "manage.py", line 2, in > from django.core.management import execute_manager > File "c:\python25\Lib\site-packages\django\core\management > \__init__.py", line > 3, in > from optparse import OptionParser, NO_DEFAULT > File "C:\Python25\lib\optparse.py", line 404, in > _builtin_cvt = { "int" : (_parse_int, _("integer")), > File "C:\Python25\lib\gettext.py", line 566, in gettext > return dgettext(_current_domain, message) > File "C:\Python25\lib\gettext.py", line 530, in dgettext > codeset=_localecodesets.get(domain)) > File "C:\Python25\lib\gettext.py", line 465, in translation > mofiles = find(domain, localedir, languages, all=1) > File "C:\Python25\lib\gettext.py", line 437, in find > for nelang in _expand_lang(lang): > File "C:\Python25\lib\gettext.py", line 131, in _expand_lang > from locale import normalize > ImportError: cannot import name normalize > Do you have some package which is clobbering the python supplied 'locale' package? Eg, a folder called 'locale' on your python path? locale.normalize has been part of python since 2.0 according to the docs. Cheers Tom -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
Re: warning: Not importing directory
If I create an __init__.py, I get this: 'import site' failed; use -v for traceback Traceback (most recent call last): File "manage.py", line 2, in from django.core.management import execute_manager File "c:\python25\Lib\site-packages\django\core\management \__init__.py", line 3, in from optparse import OptionParser, NO_DEFAULT File "C:\Python25\lib\optparse.py", line 404, in _builtin_cvt = { "int" : (_parse_int, _("integer")), File "C:\Python25\lib\gettext.py", line 566, in gettext return dgettext(_current_domain, message) File "C:\Python25\lib\gettext.py", line 530, in dgettext codeset=_localecodesets.get(domain)) File "C:\Python25\lib\gettext.py", line 465, in translation mofiles = find(domain, localedir, languages, all=1) File "C:\Python25\lib\gettext.py", line 437, in find for nelang in _expand_lang(lang): File "C:\Python25\lib\gettext.py", line 131, in _expand_lang from locale import normalize ImportError: cannot import name normalize On Jan 7, 11:24 am, Daniel Roseman <dan...@roseman.org.uk> wrote: > On Jan 7, 7:40 am, Delacroy Systems <webad...@delacroy.co.za> wrote: > > > How do I solve this? Happens when I do a runserver... > > > warning: Not importing directory 'C:\Python25\Lib\site-packages\blocks > > \locale': missing __init__.py > > warning: Not importing directory 'C:\Python25\Lib\site-packages > > \django_cms-2.0.2-py2.5.egg\cms\locale': missing __init__.py > > warning: Not importing directory 'C:\Python25\Lib\site-packages\blocks > > \locale':missing __init__.py > > warning: Not importing directory 'C:\Python25\Lib\site-packages > > \django_cms-2.0.2-py2.5.egg\cms\locale': missing __init__.py > > Have you tried putting __init__.py files in those directories? > -- > DR. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
Re: warning: Not importing directory
On Jan 7, 7:40 am, Delacroy Systems <webad...@delacroy.co.za> wrote: > How do I solve this? Happens when I do a runserver... > > warning: Not importing directory 'C:\Python25\Lib\site-packages\blocks > \locale': missing __init__.py > warning: Not importing directory 'C:\Python25\Lib\site-packages > \django_cms-2.0.2-py2.5.egg\cms\locale': missing __init__.py > warning: Not importing directory 'C:\Python25\Lib\site-packages\blocks > \locale':missing __init__.py > warning: Not importing directory 'C:\Python25\Lib\site-packages > \django_cms-2.0.2-py2.5.egg\cms\locale': missing __init__.py Have you tried putting __init__.py files in those directories? -- DR. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
warning: Not importing directory
How do I solve this? Happens when I do a runserver... warning: Not importing directory 'C:\Python25\Lib\site-packages\blocks \locale': missing __init__.py warning: Not importing directory 'C:\Python25\Lib\site-packages \django_cms-2.0.2-py2.5.egg\cms\locale': missing __init__.py warning: Not importing directory 'C:\Python25\Lib\site-packages\blocks \locale':missing __init__.py warning: Not importing directory 'C:\Python25\Lib\site-packages \django_cms-2.0.2-py2.5.egg\cms\locale': missing __init__.py Validating models... 0 errors found If I create an __init__.py, I get this: 'import site' failed; use -v for traceback Traceback (most recent call last): File "manage.py", line 2, in from django.core.management import execute_manager File "c:\python25\Lib\site-packages\django\core\management \__init__.py", line 3, in from optparse import OptionParser, NO_DEFAULT File "C:\Python25\lib\optparse.py", line 404, in _builtin_cvt = { "int" : (_parse_int, _("integer")), File "C:\Python25\lib\gettext.py", line 566, in gettext return dgettext(_current_domain, message) File "C:\Python25\lib\gettext.py", line 530, in dgettext codeset=_localecodesets.get(domain)) File "C:\Python25\lib\gettext.py", line 465, in translation mofiles = find(domain, localedir, languages, all=1) File "C:\Python25\lib\gettext.py", line 437, in find for nelang in _expand_lang(lang): File "C:\Python25\lib\gettext.py", line 131, in _expand_lang from locale import normalize ImportError: cannot import name normalize -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.