neon-jungle / wagtail-birdsong

Create, send, preview, edit and test email campaigns from within Wagtail
BSD 3-Clause "New" or "Revised" License
103 stars 27 forks source link

Migration dependency non-existent #34

Open GuilleAmutio opened 1 year ago

GuilleAmutio commented 1 year ago

Hello!

I'm quite new to Wagtail but I'm trying to install Birdsong and last week it was working with no issues but seems like a new update is not executing a migration

Traceback (most recent call last):
  File "/mnt/c/Users/gamutiod/Documents/POCs/cms/manage.py", line 10, in <module>
    execute_from_command_line(sys.argv)
  File "/home/gamutiod/.local/lib/python3.10/site-packages/django/core/management/__init__.py", line 446, in execute_from_command_line
    utility.execute()
  File "/home/gamutiod/.local/lib/python3.10/site-packages/django/core/management/__init__.py", line 440, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/home/gamutiod/.local/lib/python3.10/site-packages/django/core/management/base.py", line 414, in run_from_argv
    self.execute(*args, **cmd_options)
  File "/home/gamutiod/.local/lib/python3.10/site-packages/django/core/management/base.py", line 460, in execute
    output = self.handle(*args, **options)
  File "/home/gamutiod/.local/lib/python3.10/site-packages/django/core/management/base.py", line 98, in wrapped
    res = handle_func(*args, **kwargs)
  File "/home/gamutiod/.local/lib/python3.10/site-packages/django/core/management/commands/migrate.py", line 108, in handle
    executor = MigrationExecutor(connection, self.migration_progress_callback)
  File "/home/gamutiod/.local/lib/python3.10/site-packages/django/db/migrations/executor.py", line 18, in __init__
    self.loader = MigrationLoader(self.connection)
  File "/home/gamutiod/.local/lib/python3.10/site-packages/django/db/migrations/loader.py", line 58, in __init__
    self.build_graph()
  File "/home/gamutiod/.local/lib/python3.10/site-packages/django/db/migrations/loader.py", line 276, in build_graph
    self.graph.validate_consistency()
  File "/home/gamutiod/.local/lib/python3.10/site-packages/django/db/migrations/graph.py", line 198, in validate_consistency
    [n.raise_error() for n in self.node_map.values() if isinstance(n, DummyNode)]
  File "/home/gamutiod/.local/lib/python3.10/site-packages/django/db/migrations/graph.py", line 198, in <listcomp>
    [n.raise_error() for n in self.node_map.values() if isinstance(n, DummyNode)]
  File "/home/gamutiod/.local/lib/python3.10/site-packages/django/db/migrations/graph.py", line 60, in raise_error
    raise NodeNotFoundError(self.error_message, self.key, origin=self.origin)
django.db.migrations.exceptions.NodeNotFoundError: Migration birdsong.0007_alter_contacttag_tag dependencies reference nonexistent parent node ('taggit', '0005_auto_20220424_2025')

I don´t really know if thats something I did wrong or is related with the latest change.

seb-b commented 1 year ago

yeah I think a bad migration was accidentally added, the dependency might just need to be updated, or maybe just clean it out

In the meantime I think you can get around this by running django-admin migrate --fake birdsong 0007