Code Monkey home page Code Monkey logo

Comments (4)

kingbuzzman avatar kingbuzzman commented on July 21, 2024

Hi @eremeevfd, thank you for your issue. I would love to help, but i need a lot more details. How many migrations do you have? Are you sure your migrations are not self referencing? Have you monkey patched migrations in the past? What django version are you using? Have you tried debugging the issue?

from django-squash.

kingbuzzman avatar kingbuzzman commented on July 21, 2024

@eremeevfd can you provide more information on the detail of your issue?

from django-squash.

kingbuzzman avatar kingbuzzman commented on July 21, 2024

Closing this issue in lieu of no feedback. Feel free to open this back up when you have more details. Thank you @eremeevfd

from django-squash.

eremeevfd avatar eremeevfd commented on July 21, 2024

Hello again, sorry I missed your answer. So I plan to reopen issue, cause I tried to squash my migrations again :)

I get this error again:

Traceback (most recent call last):
  File "manage.py", line 21, in <module>
    main()
  File "manage.py", line 17, in main
    execute_from_command_line(sys.argv)
  File "/Users/f.eremeev/haut_ai_team/sasuke/backend/saas_core/venv/lib/python3.8/site-packages/django/core/management/__init__.py", line 419, in execute_from_command_line
    utility.execute()
  File "/Users/f.eremeev/haut_ai_team/sasuke/backend/saas_core/venv/lib/python3.8/site-packages/django/core/management/__init__.py", line 413, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/Users/f.eremeev/haut_ai_team/sasuke/backend/saas_core/venv/lib/python3.8/site-packages/django/core/management/base.py", line 354, in run_from_argv
    self.execute(*args, **cmd_options)
  File "/Users/f.eremeev/haut_ai_team/sasuke/backend/saas_core/venv/lib/python3.8/site-packages/django/core/management/base.py", line 398, in execute
    output = self.handle(*args, **options)
  File "/Users/f.eremeev/haut_ai_team/sasuke/backend/saas_core/venv/lib/python3.8/site-packages/django/core/management/base.py", line 89, in wrapped
    res = handle_func(*args, **kwargs)
  File "/Users/f.eremeev/haut_ai_team/sasuke/backend/saas_core/venv/lib/python3.8/site-packages/django_squash/management/commands/squash_migrations.py", line 102, in handle
    squashed_changes = autodetector.squash(
  File "/Users/f.eremeev/haut_ai_team/sasuke/backend/saas_core/venv/lib/python3.8/site-packages/django_squash/management/commands/lib/autodetector.py", line 241, in squash
    self.convert_migration_references_to_objects(real_loader, graph, changes)
  File "/Users/f.eremeev/haut_ai_team/sasuke/backend/saas_core/venv/lib/python3.8/site-packages/django_squash/management/commands/lib/autodetector.py", line 202, in convert_migration_references_to_objects
    dependency = tuple(migrations[-1])
IndexError: list index out of range

I have 126 migrations.
I think that I don't have self referencing migrations, only merge migrations, referencing others.
I think I didn't have any monkey patches. But maybe you could give one little example, how this could be performed.
My django-named packages:

pip list | grep django
django-extensions                       3.1.3
django-pglocks                          1.0.4
django-polymorphic                      3.0.0
django-prometheus                       2.1.0
django-squash                           0.0.6
djangorestframework                     3.12.4
djangorestframework-csv                 2.1.1
flake8-django                           1.1.2
pytest-django                           4.2.0

I don't know where could I start debugging =/

from django-squash.

Related Issues (10)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.