Change the max_version check in the PluginConfig to exclude the specified version #5617

Closed
opened 2025-12-29 19:30:11 +01:00 by adam · 2 comments
Owner

Originally created by @tobiasge on GitHub (Nov 5, 2021).

NetBox version

v3.0.9

Feature type

Change to existing functionality

Proposed functionality

Change the max_version check in the PluginConfig to exclude the specified version or add a field to configure the behaviour.

Use case

When developing a plugin I want it to be compatible with all patch releases but not the next major version.
At the moment I can set the max_version to be '3.0.9' and the plugin will not work with '3.0.10'. With the proposed change I would set the max_version to '3.1' and the plugin would work with all minor versions of '3.0.x'.

Database changes

None

External dependencies

None

Originally created by @tobiasge on GitHub (Nov 5, 2021). ### NetBox version v3.0.9 ### Feature type Change to existing functionality ### Proposed functionality Change the `max_version` check in the `PluginConfig` to exclude the specified version or add a field to configure the behaviour. ### Use case When developing a plugin I want it to be compatible with all patch releases but not the next major version. At the moment I can set the `max_version` to be '3.0.9' and the plugin will not work with '3.0.10'. With the proposed change I would set the `max_version` to '3.1' and the plugin would work with all minor versions of '3.0.x'. ### Database changes None ### External dependencies None
adam added the type: feature label 2025-12-29 19:30:11 +01:00
adam closed this issue 2025-12-29 19:30:11 +01:00
Author
Owner

@jeremystretch commented on GitHub (Nov 8, 2021):

I see two problems with this:

  1. It's rather misleading: One would expect the "max" version to be the highest most compatible version.
  2. It's a breaking change to the plugins API.

Instead, you can set max_version to e.g. 3.0.99 to ensure it will be supported up until v3.1. (This was a topic of conversation when the plugins API was being developed.)

@jeremystretch commented on GitHub (Nov 8, 2021): I see two problems with this: 1. It's rather misleading: One would expect the "max" version to be the highest most _compatible_ version. 2. It's a breaking change to the plugins API. Instead, you can set `max_version` to e.g. 3.0.99 to ensure it will be supported up until v3.1. (This was a topic of conversation when the plugins API was being developed.)
Author
Owner

@tobiasge commented on GitHub (Nov 9, 2021):

Ye, it would be misleading. I think I can live with the proposed workaround.

@tobiasge commented on GitHub (Nov 9, 2021): Ye, it would be misleading. I think I can live with the proposed workaround.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#5617