Changelog is missing changes #2741

Closed
opened 2025-12-29 18:21:37 +01:00 by adam · 5 comments
Owner

Originally created by @tlofreso on GitHub (Jul 15, 2019).

Environment

  • Python version: Python 3.6.6
  • NetBox version: v2.6.1

Steps to Reproduce

  1. bulk create IP addresses: 10.1.1.[100-140]/24
  2. delete newly created IPs via api ($ip = list of IDs for IPs: 10.1.1.100-140):
foreach ($ip in $ips) {
Invoke-RestMethod -Uri "$($base_url)/ipam/ip-addresses/$($ip)/" -Headers $headers -Method Delete
}
  1. Check changelog for all changes done

Expected Behavior

  • Script will make the following call for each id provided:
Invoke-RestMethod -Uri "$($base_url)/ipam/ip-addresses/$($ip)/" -Headers $headers -Method Delete
  • A unique Request ID should should exist on page */extras/changelog for each id provided

Observed Behavior

  • number of changelog Request IDs < number of ids provided on page */extras/changelog
  • In other words, number of documented changes in changelog is less than actual changes made.
  • All changes do occur as they should, but not all are logged.
Originally created by @tlofreso on GitHub (Jul 15, 2019). <!-- NOTE: This form is only for reproducible bugs. If you need assistance with NetBox installation, or if you have a general question, DO NOT open an issue. Instead, post to our mailing list: https://groups.google.com/forum/#!forum/netbox-discuss Please describe the environment in which you are running NetBox. Be sure that you are running an unmodified instance of the latest stable release before submitting a bug report. --> ### Environment * Python version: Python 3.6.6 <!-- Example: 3.5.4 --> * NetBox version: v2.6.1 <!-- Example: 2.5.2 --> <!-- Describe in detail the exact steps that someone else can take to reproduce this bug using the current stable release of NetBox (or the current beta release where applicable). Begin with the creation of any necessary database objects and call out every operation being performed explicitly. If reporting a bug in the REST API, be sure to reconstruct the raw HTTP request(s) being made: Don't rely on a wrapper like pynetbox. --> ### Steps to Reproduce 1. bulk create IP addresses: `10.1.1.[100-140]/24` 2. delete newly created IPs via api (`$ip` = list of IDs for IPs: 10.1.1.100-140): ``` foreach ($ip in $ips) { Invoke-RestMethod -Uri "$($base_url)/ipam/ip-addresses/$($ip)/" -Headers $headers -Method Delete } ``` 3. Check changelog for all changes done <!-- What did you expect to happen? --> ### Expected Behavior - Script will make the following call for each id provided: ``` Invoke-RestMethod -Uri "$($base_url)/ipam/ip-addresses/$($ip)/" -Headers $headers -Method Delete ``` - A unique **Request ID** should should exist on page */extras/changelog for each **id** provided <!-- What happened instead? --> ### Observed Behavior - number of changelog **Request ID**s < number of **id**s provided on page */extras/changelog - In other words, number of documented changes in changelog is less than actual changes made. - All changes do occur as they should, but not all are logged.
adam closed this issue 2025-12-29 18:21:37 +01:00
Author
Owner

@jeremystretch commented on GitHub (Jul 16, 2019):

I'm not able to reproduce this using raw API calls: A change is recorded both during the creation and the deletion of each IP address.

Please note that bug reports must be fully reproducible by others without relying on any external tools. The partial script you posted cannot be reproduced. You may request that this be reopened if you are able to reproduce the issue using only raw API requests (e.g. through curl).

@jeremystretch commented on GitHub (Jul 16, 2019): I'm not able to reproduce this using raw API calls: A change is recorded both during the creation and the deletion of each IP address. Please note that bug reports must be fully reproducible by others without relying on any external tools. The partial script you posted cannot be reproduced. You may request that this be reopened if you are able to reproduce the issue using only raw API requests (e.g. through `curl`).
Author
Owner

@tlofreso commented on GitHub (Jul 16, 2019):

With curl, batch deleting 11 IPs via API:

[user@netbox ~]$ curl -X DELETE -H "Authorization: Token a013555c26e6e12d5040dc750ffdaa7000358219" -H "Content-Type: application/json" -H "Accept: application/json; indent=4" -k https://netbox/api/ipam/ip-addresses/[19444-19454]/

[1/11]: https://netbox/api/ipam/ip-addresses/19444/ --> <stdout>
--_curl_--https://netbox/api/ipam/ip-addresses/19444/

[2/11]: https://netbox/api/ipam/ip-addresses/19445/ --> <stdout>
--_curl_--https://netbox/api/ipam/ip-addresses/19445/

[3/11]: https://netbox/api/ipam/ip-addresses/19446/ --> <stdout>
--_curl_--https://netbox/api/ipam/ip-addresses/19446/

[4/11]: https://netbox/api/ipam/ip-addresses/19447/ --> <stdout>
--_curl_--https://netbox/api/ipam/ip-addresses/19447/

[5/11]: https://netbox/api/ipam/ip-addresses/19448/ --> <stdout>
--_curl_--https://netbox/api/ipam/ip-addresses/19448/

[6/11]: https://netbox/api/ipam/ip-addresses/19449/ --> <stdout>
--_curl_--https://netbox/api/ipam/ip-addresses/19449/

[7/11]: https://netbox/api/ipam/ip-addresses/19450/ --> <stdout>
--_curl_--https://netbox/api/ipam/ip-addresses/19450/

[8/11]: https://netbox/api/ipam/ip-addresses/19451/ --> <stdout>
--_curl_--https://netbox/api/ipam/ip-addresses/19451/

[9/11]: https://netbox/api/ipam/ip-addresses/19452/ --> <stdout>
--_curl_--https://netbox/api/ipam/ip-addresses/19452/

[10/11]: https://netbox/api/ipam/ip-addresses/19453/ --> <stdout>
--_curl_--https://netbox/api/ipam/ip-addresses/19453/

[11/11]: https://netbox/api/ipam/ip-addresses/19454/ --> <stdout>
--_curl_--https://netbox/api/ipam/ip-addresses/19454/
[user@netbox ~]$ 

Changelog showing < 11 changes:

image

Also note user column. The Auth Z token used above belongs to user 'Datacom'

@tlofreso commented on GitHub (Jul 16, 2019): With curl, batch deleting 11 IPs via API: ``` [user@netbox ~]$ curl -X DELETE -H "Authorization: Token a013555c26e6e12d5040dc750ffdaa7000358219" -H "Content-Type: application/json" -H "Accept: application/json; indent=4" -k https://netbox/api/ipam/ip-addresses/[19444-19454]/ [1/11]: https://netbox/api/ipam/ip-addresses/19444/ --> <stdout> --_curl_--https://netbox/api/ipam/ip-addresses/19444/ [2/11]: https://netbox/api/ipam/ip-addresses/19445/ --> <stdout> --_curl_--https://netbox/api/ipam/ip-addresses/19445/ [3/11]: https://netbox/api/ipam/ip-addresses/19446/ --> <stdout> --_curl_--https://netbox/api/ipam/ip-addresses/19446/ [4/11]: https://netbox/api/ipam/ip-addresses/19447/ --> <stdout> --_curl_--https://netbox/api/ipam/ip-addresses/19447/ [5/11]: https://netbox/api/ipam/ip-addresses/19448/ --> <stdout> --_curl_--https://netbox/api/ipam/ip-addresses/19448/ [6/11]: https://netbox/api/ipam/ip-addresses/19449/ --> <stdout> --_curl_--https://netbox/api/ipam/ip-addresses/19449/ [7/11]: https://netbox/api/ipam/ip-addresses/19450/ --> <stdout> --_curl_--https://netbox/api/ipam/ip-addresses/19450/ [8/11]: https://netbox/api/ipam/ip-addresses/19451/ --> <stdout> --_curl_--https://netbox/api/ipam/ip-addresses/19451/ [9/11]: https://netbox/api/ipam/ip-addresses/19452/ --> <stdout> --_curl_--https://netbox/api/ipam/ip-addresses/19452/ [10/11]: https://netbox/api/ipam/ip-addresses/19453/ --> <stdout> --_curl_--https://netbox/api/ipam/ip-addresses/19453/ [11/11]: https://netbox/api/ipam/ip-addresses/19454/ --> <stdout> --_curl_--https://netbox/api/ipam/ip-addresses/19454/ [user@netbox ~]$ ``` Changelog showing < 11 changes: ![image](https://user-images.githubusercontent.com/20543834/61303463-88f22300-a7b5-11e9-9b9b-da4f25a04040.png) Also note user column. The Auth Z token used above belongs to user 'Datacom'
Author
Owner

@DanSheps commented on GitHub (Jul 16, 2019):

I am unable to reproduce this on master and using pynetbox. I suspect there is something wrong with your procedure as evidenced by the fact that there are two different users authenticating and deleting these addresses.

@DanSheps commented on GitHub (Jul 16, 2019): I am unable to reproduce this on master and using pynetbox. I suspect there is something wrong with your procedure as evidenced by the fact that there are two different users authenticating and deleting these addresses.
Author
Owner

@tlofreso commented on GitHub (Jul 16, 2019):

I'll test on a separate out of box install and update. We only see the issue when doing a batch of changes via the API in quick succession.

Consider closed for now until I can eliminate some of the variables we're identifying.

@tlofreso commented on GitHub (Jul 16, 2019): I'll test on a separate out of box install and update. We only see the issue when doing a batch of changes via the API in quick succession. Consider closed for now until I can eliminate some of the variables we're identifying.
Author
Owner

@tlofreso commented on GitHub (Jul 16, 2019):

FYI, I agree with you. I am not able to reproduce this on a new install :(

Will spend some time troubleshooting our prod deployment. Thank you for your efforts

@tlofreso commented on GitHub (Jul 16, 2019): FYI, I agree with you. I am not able to reproduce this on a new install :( Will spend some time troubleshooting our prod deployment. Thank you for your efforts
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#2741