molgenis / molgenis-emx2

MOLGENIS EMX2, the latest version of the MOLGENIS data platform.
GNU Lesser General Public License v3.0
14 stars 16 forks source link

Forms: Warning in non required fields when molgenis.csv includes FALSE or False in required column #3948

Open dtroelofsprins opened 3 months ago

dtroelofsprins commented 3 months ago

What version of EMX2 are you using (see footer) v10.86.0

Describe the bug When the molgenis.csv contains FALSE or False in the required column the forms give a warning for those fields that are not required: image It's just a warning, because the data can be saved without any problems, also uploading data via files works fine.

To Reproduce Steps to reproduce the behavior:

  1. Go to 'https://emx2.dev.molgenis.org'
  2. Create a new schema
  3. Upload the attached molgenis.csv
  4. Goto the LowerTable => add a new record => see that the forms doesn't show any warning for the non required fields (acronym and description)
  5. Goto the UpperTable => add a new record => forms show a warning for the non required field acronym and description: Invalid expression 'FALSE', reason: ReferenceError: Can't find variable: FALSE
  6. Goto the CapTable => add a new record => forms show a warning for the non required field acronym and description: Invalid expression 'False', reason: ReferenceError: Can't find variable: False

Expected behavior The required column should not be restricted to only contain lowercase false in the molgenis.csv. As f.e. in Excel entering false might autocorrect automatically to FALSE. And when processing the molgenis.csv with Python it might happen that it's False.