This repository was archived by the owner on Apr 24, 2025. It is now read-only.
BAT-7558 - Simple list fields broken #24
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Pretty sure this is caused by MongoEngine/mongoengine#1129: in that PR,
verbose_nameis no longer an actual attribute of fields classes. I guess this issue has something to with this document wrapper, scouring fields and trying to ensure the presence ofverbose_nameon them:django-mongodbforms/mongodbforms/documentoptions.py
Lines 187 to 188 in ebaa882
When the form generators encounters a list field though, it tries to grab data from its
field.field:django-mongodbforms/mongodbforms/fieldgenerator.py
Line 338 in ebaa882
Sub-field that seems to be ignored by the wrapper, and thus does not have the optional
verbose_name. If the list's field is declared explicitly with averbose_name, the issue does not occur.→ It seems acceptable for
help_textto be undefined, so I'm doing the same forverbose_name.