-
Notifications
You must be signed in to change notification settings - Fork 137
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
Apply section name check to sections only #529
Apply section name check to sections only #529
Conversation
This reverts commit 4f1536f.
Indeed, thank you! I had missed @pbowen-oc's #510 (comment) to that effect. Could you please add a test very similar to https://github.com/XLSForm/pyxform/pull/511/files#diff-2f87b2f8ddd9e41e8ebf5bf45472a415f5d2744e146a487aa0516762c79c47cf that verifies that a field name that matches the root node name is accepted? |
…to `tests_v1`. Previously, acceptance of this was only checked in the older `tests`
Sure :) I added one just now. Should I also check the generated XML, or is it enough as-is? I started writing that but threw it away, thinking that it'd add brittleness and duplicate other tests |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🙏 Thank you! Some people I know would be very offended by the lack of explicit assertion and I might add errored=False
to placate them but I don't mind as-is.
Leaving open for a bit in case @gushil, @MartijnR or @pbowen-oc want to sanity check. Any urgency to release?
Codecov Report
@@ Coverage Diff @@
## master #529 +/- ##
=======================================
Coverage 83.94% 83.94%
=======================================
Files 25 25
Lines 3719 3719
Branches 867 867
=======================================
Hits 3122 3122
Misses 452 452
Partials 145 145
Continue to review full report at Codecov.
|
Aye, aye 👍 I don't want to get run out of town or anything 😆
Nope, none at all. |
Fine with me. Thanks! 👍 |
@lognaturel - We would like this update, but there is no urgency on it. |
Why is this the best possible solution? Were any other approaches considered?
#511 is a helpful solution to #510, providing less-confusing error text when a group name matches the root node name, but it also ensnared (unintentionally?) regular question names. Other approaches considered and rejected were:
What are the regression risks?
Some unknown tool could depend on the recently-added check that prevents question names from equaling the form name.
Does this change require updates to documentation? If so, please file an issue here and include the link below.
No; however, if this PR is undesirable, then the documentation should be updated to reflect the new restriction on question names.
Before submitting this PR, please make sure you have:
tests_v1
nosetests
and verified all tests passblack pyxform
to format code