python - django run server error with mysql -
after solve issue "image not found" when run python manage.py syncdb
adding "export dyld_library_path=/usr/local/mysql/lib/" .bash_profile. problem comes python manage.py runserver
know how solve oserror(errno 20)?
system check identified no issues (0 silenced). oct 07, 2014 - 18:19:56 django version 1.8, using settings 'dbtest.settings' starting development server @ http:/127.0.0.1:8000/ quit server control-c. traceback (most recent phone call last): file "manage.py", line 10, in <module> execute_from_command_line(sys.argv) file "/library/python/2.7/site-packages/django-1.8-py2.7.egg/django/core/management/__init__.py", line 330, in execute_from_command_line utility.execute() file "/library/python/2.7/site-packages/django-1.8-py2.7.egg/django/core/management/__init__.py", line 322, in execute self.fetch_command(subcommand).run_from_argv(self.argv) file "/library/python/2.7/site-packages/django-1.8-py2.7.egg/django/core/management/base.py", line 363, in run_from_argv self.execute(*args, **cmd_options) file "/library/python/2.7/site-packages/django-1.8-py2.7.egg/django/core/management/base.py", line 412, in execute output = self.handle(*args, **options) file "/library/python/2.7/site-packages/django-1.8-py2.7.egg/django/core/management/commands/runserver.py", line 80, in handle self.run(**options) file "/library/python/2.7/site-packages/django-1.8-py2.7.egg/django/core/management/commands/runserver.py", line 89, in run autoreload.main(self.inner_run, none, options) file "/library/python/2.7/site-packages/django-1.8-py2.7.egg/django/utils/autoreload.py", line 320, in main reloader(wrapped_main_func, args, kwargs) file "/library/python/2.7/site-packages/django-1.8-py2.7.egg/django/utils/autoreload.py", line 286, in python_reloader reloader_thread() file "/library/python/2.7/site-packages/django-1.8-py2.7.egg/django/utils/autoreload.py", line 262, in reloader_thread alter = fn() file "/library/python/2.7/site-packages/django-1.8-py2.7.egg/django/utils/autoreload.py", line 200, in code_changed stat = os.stat(filename) oserror: [errno 20] not directory: '/library/python/2.7/site-packages/mysql_python-1.2.3-py2.7-macosx-10.9-intel.egg/mysqldb/converters.py'
i realize install both mysql-python , mysql-connector-python packages. changing database 'engine' setting 'django.db.backends.mysql' 'mysql.connector.django', issue solved.
lesson learned here: should utilize virtualenv seek different python package.
python mysql django python-2.7
No comments:
Post a Comment