return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 994, in _gcd_import
File "<frozen importlib._bootstrap>", line 971, in _find_and_load
File "<frozen importlib._bootstrap>", line 955, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 665, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 678, in exec_module
File "<frozen importlib._bootstrap>", line 219, in
_call_with_frames_removed
File "/home/gvera/Fynsa/fynsa_src/fynsa/BASES/admin.py", line 3, in
<module>
'''from .formularios_bases import f_facturas_bases'''
'''File "/home/gvera/Fynsa/fynsa_src/fynsa/BASES/formularios_bases.py",
line 27, in <module>'''
''' class f_fechas_comite(forms.Form):'''
'''File "/home/gvera/Fynsa/fynsa_src/fynsa/BASES/formularios_bases.py",
line 29, in f_fechas_comite'''
'''fecha_final = forms.DateField(widget=forms.DateInput(attrs={'class
':'form-control mx-2','type':'date'}),label='fecha final', required=True,
initial=bases.objects.latest('fecha'))'''
File "/home/gvera/Fynsa/fynsa_env/lib/python3.6/site-
packages/django/db/models/manager.py", line 82, in manager_method
return getattr(self.get_queryset(), name)(*args, **kwargs)
File "/home/gvera/Fynsa/fynsa_env/lib/python3.6/site-
packages/django/db/models/query.py", line 649, in latest
--
Ticket URL: <https://code.djangoproject.com/ticket/32268>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
Old description:
> This issues raises when you want to add or delete a field from a model
> and that model is used in a form before. We have here the egg-chicken
> problem. makemigrations parse the form (i do not why) and he detect
> changes on those fields and raise the error. (Bold fonts):
> I fixed that issue commenting or replacing all the lines with
> bases.objects.all() (the compromised model) by anything or an empty
> string on the form. After that i ran makemigrations again, migrate, re-
> composed fake lines on the forms and that was right.
New description:
packages/django/db/models/query.py, line 649, in latest
--
--
Ticket URL: <https://code.djangoproject.com/ticket/32268#comment:1>
* status: new => closed
* resolution: => invalid
Comment:
I'm sorry but from the current description I don't understand what kind of
issue you're trying to report. `makemigrations` has nothing to do with
forms and you cannot work with nonexistent fields. It looks like a support
question, so please use as a support channel. Closing per
TicketClosingReasons/UseSupportChannels.
--
Ticket URL: <https://code.djangoproject.com/ticket/32268#comment:2>