Adding Interface with a character class with one item taken literally #850

Closed
opened 2025-12-29 16:26:21 +01:00 by adam · 1 comment
Owner

Originally created by @zevlag on GitHub (Apr 10, 2017).

Issue type: Bug

Python version: 2.7
NetBox version: v2.0-beta2
I tried adding this interface GigabitEthernet0/0/2.[80] and it was added literally instead of as GigabitEthernet0/0/2.80, even though a range such as GigabitEthernet0/0/2.[80,81] works properly.

Expected behaviour or bug?

Originally created by @zevlag on GitHub (Apr 10, 2017). ### Issue type: Bug <!-- If filing a bug, please indicate the version of Python and NetBox you are running. (This is not necessary for feature requests.) --> **Python version:** 2.7 **NetBox version:** v2.0-beta2 I tried adding this interface `GigabitEthernet0/0/2.[80]` and it was added literally instead of as `GigabitEthernet0/0/2.80`, even though a range such as `GigabitEthernet0/0/2.[80,81]` works properly. Expected behaviour or bug? <!-- If filing a bug, please record the exact steps taken to reproduce the bug and any errors messages that are generated. If filing a feature request, please precisely describe the data model or workflow you would like to see implemented, and provide a use case. -->
adam closed this issue 2025-12-29 16:26:21 +01:00
Author
Owner

@jeremystretch commented on GitHub (Apr 10, 2017):

Expected behavior. The regex checks for the presence of a comma within brackets. Otherwise, it would be impossible to create an interface with brackets in the name.

@jeremystretch commented on GitHub (Apr 10, 2017): Expected behavior. The regex checks for the presence of a comma within brackets. Otherwise, it would be impossible to create an interface with brackets in the name.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#850