Testing admin inlines painful to debug ("ManagementForm data is missing or has been tampered with")

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Testing admin inlines painful to debug ("ManagementForm data is missing or has been tampered with")

Federico Capoano-2
While writing tests for the admin, I'm clashing with this error message:

"ManagementForm data is missing or has been tampered with".

It's not the first time I do this, but every time the process has been extremely painful because the error message doesn't point out the exact problem.
This time I'm pretty sure to have done everything properly but I just can't find out what's missing, not even by dropping pdb.set_trace() into django's internal code.

I'm wondering if we can improve this error message so that if DEBUG is True we can have some more information about what is missing.

Would that be possible and welcome?

Best regards
Federico

--
You received this message because you are subscribed to the Google Groups "Django developers (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/django-developers.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-developers/2e91370b-fe2b-4e97-afa8-aa80b36273cc%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Testing admin inlines painful to debug ("ManagementForm data is missing or has been tampered with")

Jesse Welborn
I had a similar issue trying to debug InlineModelFormsets. If the root cause is the same I have a PR open to add documentation relating to how Inline Formets deal with prefixes.

Without knowing your specific circumstance it's impossible to know if this is the cause, but if so it was a pain point for me as well.

Regard,
JW

--
You received this message because you are subscribed to the Google Groups "Django developers (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/django-developers.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-developers/22afae72-354b-48b6-b951-fd1692b1e1c1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.