Skip to content

AttributeError: 'module' object has no attribute '__file__' ... when creating the database #3

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
ohmeow opened this issue Mar 27, 2014 · 1 comment

Comments

@ohmeow
Copy link

ohmeow commented Mar 27, 2014

Using Python 3.3.5 and getting this error on last step in the instructions (e.g., "make create_database; ...")

(django_angular_tut-py3)fred@fred-mbp$ make create_database
./manage.py syncdb --noinput
Traceback (most recent call last):
File "./manage.py", line 10, in
execute_from_command_line(sys.argv)
File "/Users/fred/.virtualenvs/django_angular_tut-py3/lib/python3.3/site-packages/django/core/management/init.py", line 399, in execute_from_command_line
utility.execute()
File "/Users/fred/.virtualenvs/django_angular_tut-py3/lib/python3.3/site-packages/django/core/management/init.py", line 392, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/Users/fred/.virtualenvs/django_angular_tut-py3/lib/python3.3/site-packages/django/core/management/base.py", line 242, in run_from_argv
self.execute(_args, *_options.dict)
File "/Users/fred/.virtualenvs/django_angular_tut-py3/lib/python3.3/site-packages/django/core/management/base.py", line 285, in execute
output = self.handle(_args, _options)
File "/Users/fred/.virtualenvs/django_angular_tut-py3/lib/python3.3/site-packages/django/core/management/base.py", line 415, in handle
return self.handle_noargs(
_options)
File "/Users/fred/.virtualenvs/django_angular_tut-py3/lib/python3.3/site-packages/south/management/commands/syncdb.py", line 68, in handle_noargs
migrations = migration.Migrations(app_label)
File "/Users/fred/.virtualenvs/django_angular_tut-py3/lib/python3.3/site-packages/south/migration/base.py", line 64, in call
self.instances[app_label] = super(MigrationsMetaclass, self).call(app_label_to_app_module(app_label), *_kwds)
File "/Users/fred/.virtualenvs/django_angular_tut-py3/lib/python3.3/site-packages/south/migration/base.py", line 90, in init
self.set_application(application, force_creation, verbose_creation)
File "/Users/fred/.virtualenvs/django_angular_tut-py3/lib/python3.3/site-packages/south/migration/base.py", line 163, in set_application
self._load_migrations_module(application.migrations)
File "/Users/fred/.virtualenvs/django_angular_tut-py3/lib/python3.3/site-packages/south/migration/base.py", line 170, in _load_migrations_module
dirname = self.migrations_dir()
File "/Users/fred/.virtualenvs/django_angular_tut-py3/lib/python3.3/site-packages/south/migration/base.py", line 132, in migrations_dir
return os.path.dirname(module.file)
AttributeError: 'module' object has no attribute 'file'
make: *** [create_database] Error 1

@nadirs
Copy link
Contributor

nadirs commented Apr 5, 2014

I've made a pull request that should fix this → #4 (this StackOverflow question helped!)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants