Skip to content

How do I create the db? #1

@zhoufankai

Description

@zhoufankai

There is several errors in my operations.


PS E:\myCode\HellspawnHunterBackend-master> python2 .\manage.py get_scenes
E:\myCode\HellspawnHunterBackend-master
Traceback (most recent call last):
  File ".\manage.py", line 10, in <module>
    execute_from_command_line(sys.argv)
  File "D:\Program Files\Python27\lib\site-packages\django\core\management\__init__.py", line 399, in execute_from_command_line
    utility.execute()
  File "D:\Program Files\Python27\lib\site-packages\django\core\management\__init__.py", line 392, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "D:\Program Files\Python27\lib\site-packages\django\core\management\__init__.py", line 272, in fetch_command
    klass = load_command_class(app_name, subcommand)
  File "D:\Program Files\Python27\lib\site-packages\django\core\management\__init__.py", line 75, in load_command_class
    module = import_module('%s.management.commands.%s' % (app_name, name))
  File "D:\Program Files\Python27\lib\site-packages\django\utils\importlib.py", line 40, in import_module
    __import__(name)
  File "E:\myCode\HellspawnHunterBackend-master\api\management\commands\get_scenes.py", line 11, in <module>
    from core.models import Scene, Team, Membership, Hellspawn
  File "E:\myCode\HellspawnHunterBackend-master\core\models.py", line 44, in <module>
    class Team(BaseModel):
  File "E:\myCode\HellspawnHunterBackend-master\core\models.py", line 47, in Team
    through_fields=('team', 'hellspawn'))
  File "D:\Program Files\Python27\lib\site-packages\django\db\models\fields\related.py", line 1373, in __init__
    super(ManyToManyField, self).__init__(**kwargs)
TypeError: __init__() got an unexpected keyword argument 'through_fields'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions