Skip to content

Add NetBox 4.6.x support (widen compat to 4.5.0 – 4.6.99)#11

Merged
Kani999 merged 1 commit into
masterfrom
feature/netbox-4.6-support
May 11, 2026
Merged

Add NetBox 4.6.x support (widen compat to 4.5.0 – 4.6.99)#11
Kani999 merged 1 commit into
masterfrom
feature/netbox-4.6-support

Conversation

@Kani999
Copy link
Copy Markdown
Collaborator

@Kani999 Kani999 commented May 11, 2026

Summary

Releases 2.2.0 by widening the supported NetBox range from 4.5.0 – 4.5.99 to 4.5.0 – 4.6.99. NetBox 4.6.0 (released 2026-05-05) brings Django 6.0 and several plugin-API deprecations, but a source-level audit confirms none of the public APIs this plugin uses are changed in 4.6 — so this is a metadata-only release.

  • Bumps max_version in PluginConfig from 4.5.994.6.99
  • Bumps pyproject.toml version to 2.2.0
  • Updates README badge, requirements, and compatibility matrix
  • Adds a [2.2.0] CHANGELOG entry documenting the audit findings
  • No changes to views/, templates/, template_override.py, or urls.py

API audit against v4.6.0 upstream tag

Every NetBox import this plugin makes was verified file-by-file against the netbox-community/netbox v4.6.0 tag. All targets are present at the same module path with identical signatures:

Import NetBox 4.6 location Status
ViewTab(label, visible, badge, weight, permission, hide_if_empty) utilities/views.py:244 identical signature
register_model_view(model, name, path, detail, kwargs) utilities/views.py:354 identical signature
htmx_partial utilities/htmx.py present
EnhancedPaginator, get_paginate_count utilities/paginator.py present
TagFilterField utilities/forms/fields/fields.py:106 present
CustomFieldTypeChoices, CustomFieldUIVisibleChoices extras/choices.py present
BaseTable netbox/tables/tables.py:39 present
NetBoxModelFilterSetForm netbox/forms/filtersets.py:18 present
SavedFiltersMixin netbox/forms/mixins.py present
registry['views'][app_label][model_name] shape netbox/registry.py + utilities/views.py:381 identical
PluginConfig, get_plugin_config netbox/plugins/__init__.py, plugins/utils.py present

4.6 deprecations that do not affect this plugin:

Upstream dependency

netbox_custom_objects v0.5.0 declares min_version="4.4.0", max_version="4.6.99" and is recommended on NetBox 4.6. Critically, its customobject.html still lacks {% model_view_tabs object %} in the hardcoded {% block tabs %}, so our template_override.install() mechanism and the copied template remain required and structurally correct.

Test plan

  • ruff check netbox_custom_objects_tab/ — clean
  • ruff format --check netbox_custom_objects_tab/ — 7 files already formatted
  • pytest tests/ under local NetBox 4.5.10 — 53 / 53 passed (regression guard; no source changed)
  • Install under NetBox 4.6.0: confirm PluginConfig.ready() runs without IncompatiblePluginError
  • Combined tab on a Device page: badge, pagination, search, tag/type filter, HTMX in-place updates
  • Typed tabs with typed_models: ['dcim.*']: type-specific columns, filterset sidebar, bulk actions, configure-table
  • CO→CO tab: tab appears on a Custom Object detail page that is referenced by another Type
  • Watch server log for any Django 6.0 deprecation warnings attributable to this plugin (none expected)

Bump max_version from 4.5.99 to 4.6.99 and release as 2.2.0. Source-level
audit against the v4.6.0 upstream tag confirms every NetBox API this plugin
imports is unchanged: ViewTab, register_model_view, htmx_partial,
EnhancedPaginator, get_paginate_count, BaseTable, NetBoxModelFilterSetForm,
SavedFiltersMixin, TagFilterField, CustomFieldTypeChoices,
CustomFieldUIVisibleChoices, and the registry['views'] shape. The 4.6
deprecations of registry['models'] and legacy actions={} view dicts do not
affect this plugin (we touch neither).

Upstream netbox_custom_objects >= 0.5.0 is recommended on NetBox 4.6 (its
max_version covers 4.6.99). The customobject.html template override
remains required - v0.5.0 still hardcodes its tabs block without
{% model_view_tabs object %}.

Verified locally on NetBox 4.5.10: ruff check + format clean, all 53 tests
in tests/ pass. End-to-end verification on a 4.6.0 install pending (no
local 4.6 environment available).
@Kani999 Kani999 self-assigned this May 11, 2026
@Kani999 Kani999 merged commit 379f1d7 into master May 11, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant