Forums

makemigrations returning error since installing tagging?

I'm using the tagging library. As soon as I enabled it in my settings.py makemigrations broke. Now it returns this error:

 02:52 ~/vigil $ python manage.py makemigrations
Migrations for 'directory':
  directory/migrations/0003_organization_address_organization_email_and_more.py
    + Add field address to organization
    + Add field email to organization
    + Add field phone to organization
Migrations for 'tagging':
  /usr/local/lib/python3.13/site-packages/tagging/migrations/0004_alter_tag_id_alter_taggeditem_id.py
    ~ Alter field id on tag
    ~ Alter field id on taggeditem
Traceback (most recent call last):
  File "/home/dmccarville/vigil/manage.py", line 22, in <module>
    main()
    ~~~~^^
  File "/home/dmccarville/vigil/manage.py", line 18, in main
    execute_from_command_line(sys.argv)
    ~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^
  File "/usr/local/lib/python3.13/site-packages/django/core/management/__init__.py", line 442, in execute_from_command_line
    utility.execute()
    ~~~~~~~~~~~~~~~^^
  File "/usr/local/lib/python3.13/site-packages/django/core/management/__init__.py", line 436, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^
  File "/usr/local/lib/python3.13/site-packages/django/core/management/base.py", line 413, in run_from_argv
    self.execute(*args, **cmd_options)
    ~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.13/site-packages/django/core/management/base.py", line 459, in execute
    output = self.handle(*args, **options)
  File "/usr/local/lib/python3.13/site-packages/django/core/management/base.py", line 107, in wrapper
    res = handle_func(*args, **kwargs)
  File "/usr/local/lib/python3.13/site-packages/django/core/management/commands/makemigrations.py", line 259, in handle
    self.write_migration_files(changes)
    ~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^
  File "/usr/local/lib/python3.13/site-packages/django/core/management/commands/makemigrations.py", line 365, in write_migration_files
    with open(writer.path, "w", encoding="utf-8") as fh:
         ~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
PermissionError: [Errno 13] Permission denied: '/usr/local/lib/python3.13/site-packages/tagging/migrations/0004_alter_tag_id_alter_taggeditem_id.py'

At face value, it seems straightforward: makemigrations wants to create something in a location it can't access. I'm just not sure what to do about it.

Looks like tagging package was released without migrations. You should report it there.