Cannot set custom field selection field back to null value #1387

Closed
opened 2025-12-29 16:31:58 +01:00 by adam · 2 comments
Owner

Originally created by @Bill-Irvine on GitHub (Nov 8, 2017).

Issue type

[ ] Feature request
[*] Bug report
[ ] Documentation

Environment

  • Python version: 2.7.5
  • NetBox version: 2.1.5

Description

I have added "circuit status" as a selection based custom field and set it to a non required field.
It seems that I can assign a value to this field within a circuit and change it to another one of the values, but i am unable to set it back to a null value. I receive an exceptions.ValueError

I can change this manually back to null through the api, but cannot do this through the GUI.

Steps to reproduce:

  1. Create a circuit with a custom selection field. In mu case this is "Circuit Status" assign a value to this field, In my case active.

1

  1. Finish editing the circuit (submit) and edit the circuit again, this time move the selection field back to the null value.

2

  1. Finish editing the circuit and try submit. you will recieve the exceptions.ValueError below.

server error

  1. The way i am currently getting around this is to use the API to patch a null value to the custom field.
Originally created by @Bill-Irvine on GitHub (Nov 8, 2017). <!-- Before opening a new issue, please search through the existing issues to see if your topic has already been addressed. Note that you may need to remove the "is:open" filter from the search bar to include closed issues. Check the appropriate type for your issue below by placing an x between the brackets. For assistance with installation issues, or for any other issues other than those listed below, please raise your topic for discussion on our mailing list: https://groups.google.com/forum/#!forum/netbox-discuss Please note that issues which do not fall under any of the below categories will be closed. Due to an excessive backlog of feature requests, we are not currently accepting any proposals which extend NetBox's feature scope. Do not prepend any sort of tag to your issue's title. An administrator will review your issue and assign labels as appropriate. ---> ### Issue type [ ] Feature request <!-- An enhancement of existing functionality --> [*] Bug report <!-- Unexpected or erroneous behavior --> [ ] Documentation <!-- A modification to the documentation --> <!-- Please describe the environment in which you are running NetBox. (Be sure to verify that you are running the latest stable release of NetBox before submitting a bug report.) If you are submitting a bug report and have made any changes to the code base, please first validate that your bug can be recreated while running an official release. --> ### Environment * Python version: 2.7.5<!-- Example: 3.5.4 --> * NetBox version: 2.1.5<!-- Example: 2.1.3 --> <!-- BUG REPORTS must include: * A list of the steps needed for someone else to reproduce the bug * A description of the expected and observed behavior * Any relevant error messages (screenshots may also help) FEATURE REQUESTS must include: * A detailed description of the proposed functionality * A use case for the new feature * A rough description of any necessary changes to the database schema * Any relevant third-party libraries which would be needed --> ### Description I have added "circuit status" as a selection based custom field and set it to a non required field. It seems that I can assign a value to this field within a circuit and change it to another one of the values, but i am unable to set it back to a null value. I receive an exceptions.ValueError I can change this manually back to null through the api, but cannot do this through the GUI. Steps to reproduce: 1. Create a circuit with a custom selection field. In mu case this is "Circuit Status" assign a value to this field, In my case active. ![1](https://user-images.githubusercontent.com/5893433/32523483-56b26aae-c480-11e7-909d-f845a22d113e.PNG) 2. Finish editing the circuit (submit) and edit the circuit again, this time move the selection field back to the null value. ![2](https://user-images.githubusercontent.com/5893433/32523555-ac13894c-c480-11e7-8222-7a0d5f46ccf3.PNG) 3. Finish editing the circuit and try submit. you will recieve the exceptions.ValueError below. ![server error](https://user-images.githubusercontent.com/5893433/32523588-caeba2dc-c480-11e7-86c5-1a7ec684c516.PNG) 4. The way i am currently getting around this is to use the API to patch a null value to the custom field.
adam closed this issue 2025-12-29 16:31:58 +01:00
Author
Owner

@jeremystretch commented on GitHub (Nov 14, 2017):

I'm not able to replicate this. Please upgrade to the latest version of NetBox (v2.2.4) and try again.

@jeremystretch commented on GitHub (Nov 14, 2017): I'm not able to replicate this. Please upgrade to the latest version of NetBox (v2.2.4) and try again.
Author
Owner

@jeremystretch commented on GitHub (Nov 22, 2017):

Closing due to lack of activity.

@jeremystretch commented on GitHub (Nov 22, 2017): Closing due to lack of activity.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#1387