Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot set virtual chassis master to null using API #1399

Closed
jakubkrysl opened this issue Feb 22, 2022 · 0 comments · Fixed by #1410
Closed

Cannot set virtual chassis master to null using API #1399

jakubkrysl opened this issue Feb 22, 2022 · 0 comments · Fixed by #1410
Labels
type: bug Something isn't working as expected

Comments

@jakubkrysl
Copy link

Environment

  • Python version: 3.6.8
  • Nautobot version: 1.2.4

I tried to remove master of virtual chassis using REST API (punautobot), but got error. The error shows on server as Bad request in django.requests. It's possible to do it in UI, but not in API. As per @glennmatthews the fix is to add allow_null=True to nautobot.dcim.api.serializers.VirtualChassisSerializer.master
See thread on Slack: https://networktocode.slack.com/archives/C01NWPK6WHL/p1645551180089729

Steps to Reproduce

  1. Create virtual chassis
  2. Create device
  3. Add device to virtual chassis
  4. Set the device as master of the virtual chassis
  5. Try to clear master of the virtual chassis using API

Expected Behavior

Chassis has no master, the device is assigned to the virtual chassis

Observed Behavior

{'master': ['This field may not be null.']}

@bryanculver bryanculver added status: accepted type: bug Something isn't working as expected labels Feb 22, 2022
bryanculver added a commit that referenced this issue Mar 3, 2022
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 2, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
type: bug Something isn't working as expected
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants