Skip to content

Custom field with trailing white space unable to import #15082

@ponchofiesta

Description

@ponchofiesta

Deployment Type

Self-hosted

NetBox Version

v3.6.9

Python Version

3.8

Steps to Reproduce

  1. Create custom field for Virtual machine with multi selection
  2. One value has a trailing whitespace, e.g. "bla "
  3. Try to import this value via CSV:
id,cf_CustField
123,bla

This won't work too:

id,cf_CustField
123,"bla "

But this works:

id,cf_CustField
123,"bla ,anotherBla"

Expected Behavior

It will get imported

Suggestion: By default remove any leading and trailing white spaces form field values.

Observed Behavior

Error: "Record 1 cf_CustField: Select a valid choice. bla is not one of the available choices."

Metadata

Metadata

Labels

severity: lowDoes not significantly disrupt application functionality, or a workaround is availablestatus: acceptedThis issue has been accepted for implementationtype: bugA confirmed report of unexpected behavior in the application

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions