The user configuration validation rejects integers as default values for floats

Erwan Rouchet
2025-03-26T15:55:15Z

https://redmine.teklia.com/issues/10423

Calling CreateWorkerVersion to declare a worker version with a float user configuration parameter whose default value is 1 or 1.0 fails because the backend expects a float and never an int.

// Fails
{"user_configuration": {
  "field": {
    "title": "meow",
    "type": "float",
    "default": 1.0
  }
}

// Works
{"user_configuration": {
  "field": {
    "title": "meow",
    "type": "float",
    "default": 1.1
  }
}