Replace "obj" context var with "object" for custom links #6116

Closed
opened 2025-12-29 19:36:56 +01:00 by adam · 0 comments
Owner

Originally created by @jeremystretch on GitHub (Feb 18, 2022).

Originally assigned to: @jeremystretch on GitHub.

NetBox version

v3.1.8

Feature type

Change to existing functionality

Proposed functionality

Direct users to use object in custom link text and URL templates instead of obj. Both variables will be supported until NetBox v3.5, which will remove support for the old obj variable.

Use case

object is a more natural name for the variable. obj was originally chosen (perhaps without much consideration) because it matched the underlying code. object is a reserved word in Python, but there is no technical reason not to use it in Jinja2 templates.

Database changes

No response

External dependencies

No response

Originally created by @jeremystretch on GitHub (Feb 18, 2022). Originally assigned to: @jeremystretch on GitHub. ### NetBox version v3.1.8 ### Feature type Change to existing functionality ### Proposed functionality Direct users to use `object` in custom link text and URL templates instead of `obj`. Both variables will be supported until NetBox v3.5, which will remove support for the old `obj` variable. ### Use case `object` is a more natural name for the variable. `obj` was originally chosen (perhaps without much consideration) because it matched the underlying code. `object` is a reserved word in Python, but there is no technical reason not to use it in Jinja2 templates. ### Database changes _No response_ ### External dependencies _No response_
adam added the status: acceptedtype: feature labels 2025-12-29 19:36:56 +01:00
adam closed this issue 2025-12-29 19:36:56 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#6116