Skip to content
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

Reverse query name for 'XXX' clashes #881

Open
frankchen211 opened this issue Nov 19, 2023 · 0 comments
Open

Reverse query name for 'XXX' clashes #881

frankchen211 opened this issue Nov 19, 2023 · 0 comments
Labels

Comments

@frankchen211
Copy link

frankchen211 commented Nov 19, 2023

I have a mixin model class added to all my models, but don't want to have reversed field, so I set related_name="+" to all tags fields.

class TaggableMixin(models.Model):

    tags = TaggableManager(related_name="+")

    class Meta:
        abstract = True

Then I got these errors, how to fix it?

core.Version.tags: (fields.E305) Reverse query name for 'core.Version.tags' clashes with reverse query name for 'core.VariantSet.tags'.
	HINT: Add or change a related_name argument to the definition for 'core.Version.tags' or 'core.VariantSet.tags'.
core.Version.tags: (fields.E305) Reverse query name for 'core.Version.tags' clashes with reverse query name for 'core.Note.tags'.
	HINT: Add or change a related_name argument to the definition for 'core.Version.tags' or 'core.Note.tags'.
....

Django 4.2
latest django-taggit

@rtpg rtpg added the bug label Nov 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants