Skip to content

Fixes #142: Renamed filters module to resolve collision with netbox-branching#143

Open
arcticash wants to merge 1 commit intoDanSheps:mainfrom
arcticash:filters-naming-collision
Open

Fixes #142: Renamed filters module to resolve collision with netbox-branching#143
arcticash wants to merge 1 commit intoDanSheps:mainfrom
arcticash:filters-naming-collision

Conversation

@arcticash
Copy link
Copy Markdown

@arcticash arcticash commented Mar 17, 2026

Renamed netbox_lifecycle/templatetags/filters.py to netbox_lifecycle_filters.py and updated all {% load filters %} references.

This PR Fixes issue #142

Root Cause

The plugin's templatetag module templatetags/filters.py conflicts with netbox-branching (Thanks to @cruse1977 for the pointer!) as both used utilities/templatetags/filters.py. The library from netbox-ranching is resolved first during {% load filters %}, meaning date_badge_class is never found.

Changes

  • Renamed netbox_lifecycle/templatetags/filters.py to netbox_lifecycle/templatetags/netbox_lifecycle_filters.py
  • Updated {% load filters %} to {% load netbox_lifecycle_filters %} in all affected templates
  • Updated import in tests/test_templatetags.py

Testing

Tested against NetBox 4.5.4 and 4.5.5 with netbox-lifecycle 1.1.8 and netbox-branching . Device detail pages now load correctly with lifecycle date badges rendering as expected.

@arcticash arcticash changed the title Fixes #142: Renamed filters module to resolve collision with netbox core module Fixes #142: Renamed filters module to resolve collision with netbox-branching Mar 18, 2026
@arcticash
Copy link
Copy Markdown
Author

Updated the PR description to reflect the actual root cause being netbox-branching plugin and not netbox core as originally suspected

@cruse1977
Copy link
Copy Markdown

Note - we are renaming this is in branching ; but for completeness, we should do both

@jsenecal
Copy link
Copy Markdown
Collaborator

Tests failures are not related to this change, otherwise, this looks good to me.

@jsenecal jsenecal requested a review from DanSheps March 19, 2026 20:37
@DanSheps DanSheps enabled auto-merge March 26, 2026 00:59
@DanSheps
Copy link
Copy Markdown
Owner

@jsenecal Can you fix the conflict?

@jsenecal
Copy link
Copy Markdown
Collaborator

jsenecal commented Mar 27, 2026

Hi @DanSheps this is not my work, I don't seem to have the rights to commit on @arcticash pr branch.
@arcticash, can you fix the conflicts, we fixed a lot of linitng errors so things moved around a lot...

@DanSheps
Copy link
Copy Markdown
Owner

Sorry, for some reason thought it was yours. If it doesn't get updated by eod I might close it out and redo it

auto-merge was automatically disabled April 2, 2026 23:01

Head branch was pushed to by a user without write access

@arcticash arcticash closed this Apr 2, 2026
auto-merge was automatically disabled April 2, 2026 23:01

Pull request was closed

@arcticash arcticash force-pushed the filters-naming-collision branch from 895ee21 to fd4baf0 Compare April 2, 2026 23:01
…filters.py and updated all {% load filters %} references
@arcticash arcticash reopened this Apr 2, 2026
@arcticash
Copy link
Copy Markdown
Author

Not sure if this has already been included in a separate change but I've re-applied the module renaming on top of the latest changes to main

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.

4 participants