XLSForm / pyxform

A Python package to create XForms for ODK Collect.
BSD 2-Clause "Simplified" License
77 stars 134 forks source link

Don't check for dynamic label if there is no label #535

Closed lognaturel closed 3 years ago

lognaturel commented 3 years ago

Closes #532

Why is this the best possible solution? Were any other approaches considered?

This is a quick prevention of the crash. I think we should also consider #534.

I also added a couple of tests around numeric choice names because I initially thought that might be the issue and it does seem like something that could regress.

What are the regression risks?

It's an added None check only so I don't believe there are any.

Does this change require updates to documentation? If so, please file an issue here and include the link below.

No.

Before submitting this PR, please make sure you have:

lognaturel commented 3 years ago

@gushil would you be up for a review? This is a fix for #521 which assumed labels were required.

lognaturel commented 3 years ago

No test for dynamic labels here because they're already tested in, for example, #521 right?

That's right.