Proposal to change duplicate section name error message if equal to root node name
MartijnR opened this issue ยท 7 comments
Software and hardware versions
pyxform v1.3.3.
Problem description
When naming a group "data", the error message can be confusing.
type | name | label |
---|---|---|
begin group | data | A group |
text | a | Enter text |
end group |
The pyxform error message is "There are two sections with the name data."
Users would generally not understand what the other "data" section is (which is the root node).
Expected behavior
It may to helpful to add the following generic check to that section of code:
if duplicate section name equals the name of the root node, use error message:
"The name "[NAME]" is the same as the form name. Use a different section name (or change the form name in the "name" column of the settings sheet)."
pinging @pbowen-oc
You'll also end up with a problem if you explicitly set the root name to foo
and also have a group
named foo
, right? So I think the word "default" can be removed from the message.
Yes, indeed. Thanks! I'm updating this.
Sure, working on it.
@lognaturel - This is also catching items named data and showing the same error message as for groups/repeats:
Error: The name "data" is the same as the form name. Use a different section name (or change the form name in the "name" column of the settings sheet).
Are you open to changing the text to not refer to a section or should this check not catch items at all?
Test form:
Data item.xlsx