[Iplant-api-dev] agave app parameters with validators (and enums)

Ghiban, Cornel ghiban at cshl.edu
Mon Aug 25 11:36:51 MST 2014


Hi,

I'm trying to add a new app where one of the parameters is of
enumeration type:

        {
            "id": "library_type",
            "value": {
                "default": "fr-unstranded",
                "type": "enumeration",
                "enum_values": [
                    "fr-unstranded",
                    "fr-firststrand",
                    "fr-unstranded"
                    ],
                "validator" : "",
                "visible": true,
                "required": true
            }
        },

Submitting the json I get this error:

Validator field found for parameter library_type description. Validator
field is not applicable for enumeration parameter types.

After I remove the validator I get this message:

'software.parameter.value.validator' is not a valid regular expression.

Am I missing something?

Also, could you give me an example of a validator that works for
integers? These failed for some reason: "[0-9]*", "[0-9]+", "2", "^2$",
"\\d+"


Thanks,
Cornel



More information about the Iplant-api-dev mailing list