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

The Site ID variable on cable termination objects is not updated when nested locations are moved from one site to another. #12474

Closed
Chiniquy opened this issue May 4, 2023 · 1 comment · Fixed by #12630
Assignees
Labels
status: accepted This issue has been accepted for implementation type: bug A confirmed report of unexpected behavior in the application

Comments

@Chiniquy
Copy link

Chiniquy commented May 4, 2023

NetBox version

v.3.5.0

Python version

3.10

Steps to Reproduce

Create Site 1
Create Location 1 in Site 1
Create Sublocation 1 in Site 1 with Location 1 as parent
Create Rack 1 in Sublocation 1
Create Device 1 in Rack 1
Create Device 2 in Rack 1
Create an interface in each device
Create a cable linking these interfaces together

Create Site nr 2
Move Location 1 from Site 1 to Site 2
Delete Site 1

Expected Behavior

Site 1 should be deleted

Observed Behavior

Site is not deleted, even though it is empty.
Throws error
<class 'IndexError'>
list index out of range

@Chiniquy Chiniquy added the type: bug A confirmed report of unexpected behavior in the application label May 4, 2023
@Chiniquy
Copy link
Author

Chiniquy commented May 4, 2023

It works as expected if we do not make Sublocation 1 but simply put the rack and equipment in Location 1, and then move Location 1 from Site 1 to Site 2.

It also works as expected after we delete the cable object after getting the IndexError.

@DanSheps DanSheps added the status: needs owner This issue is tentatively accepted pending a volunteer committed to its implementation label May 4, 2023
@arthanson arthanson self-assigned this May 16, 2023
@arthanson arthanson added status: accepted This issue has been accepted for implementation and removed status: needs owner This issue is tentatively accepted pending a volunteer committed to its implementation labels May 16, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 14, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
status: accepted This issue has been accepted for implementation type: bug A confirmed report of unexpected behavior in the application
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants