Open lucagubler opened 1 month ago
Updated the script, it was missing all the imports. Noticed a potential other issue, after running I went to the main branch and bulk deleted the two created VRFs, then went to the test branch and tried to bulk-delete the single created VRF and got an error VRF matching query does not exist.
The issue is the script params, the script only runs on the main branch as it's not branch aware, but when you add the script params it is pulling from the active branch so is causing inconsistencies. Am exploring options to fix
Plugin Version
0.4.0
NetBox Version
4.1
Python Version
3.10.12
Steps to Reproduce
This example script can be used to create VRFs and RDs.
And here's the error I receive when running this custom script
Expected Behavior
All VRFs/RD should be created successfully.
Observed Behavior
The first VRF is created, but the second fails. It looks like the lookup, e.g.
VRF.objects.all()
, looks for data from the main branch. This works for the first iteration and a new VRF is created in the new branch. But for the second iteration, the script wants to reserve the same VRF/RD again because it's still available on the main branch. But then it fails because that RD is already taken in my new branch...