We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Hello! There is such issue here, but I want to tell about the bug, I think.
from badgify.models import base
base.Badge
base
Next, when adding CustomModel to models.py and set CustomModel path in settings.py:
settings.py
from badgify.models.base.badge import Badge as BaseBadge class GuidaBadge(BaseBadge): class Meta(BaseBadge.Meta): abstract = False
and after run manage.py shell (or runserver or makemigartion) Python will run code line by line: so firstly from badgify.models.base.badge import Badge as BaseBadge would be run. But there is Badge = load_class(settings.BADGE_MODEL) https://github.com/ulule/django-badgify/blob/master/badgify/models/__init__.py#L8
from badgify.models.base.badge import Badge as BaseBadge
Badge = load_class(settings.BADGE_MODEL)
in init.py of models. So python will try to load my custom model while custom model is not run by python. So it is impossible to create custom model.
Have you tried to make custom model?
The text was updated successfully, but these errors were encountered:
Has anyone solved this?
Sorry, something went wrong.
No branches or pull requests
Hello!
There is such issue here, but I want to tell about the bug, I think.
from badgify.models import base
andbase.Badge
but there is no Badge class inbase
module. And init is empty. So is it right?Next, when adding CustomModel to models.py and set CustomModel path in
settings.py
:and after run manage.py shell (or runserver or makemigartion) Python will run code line by line:
so firstly
from badgify.models.base.badge import Badge as BaseBadge
would be run. But there isBadge = load_class(settings.BADGE_MODEL)
https://github.com/ulule/django-badgify/blob/master/badgify/models/__init__.py#L8
in init.py of models. So python will try to load my custom model while custom model is not run by python.
So it is impossible to create custom model.
Have you tried to make custom model?
The text was updated successfully, but these errors were encountered: