Malformatted export template clears set filters #6252

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

Originally created by @martinum4 on GitHub (Mar 23, 2022).

Originally assigned to: @jeremystretch on GitHub.

NetBox version

v3.1.9

Python version

3.9

Steps to Reproduce

Reproducable on demo.netbox.dev

  1. Create a malformatted export template for locations that creates an error/exception when running (e.g.
{% for location in queryset %}
{% if location.child.count() = 0 }
{{ location.name }} {% else %}{% endif %}{% endfor %}

Notice the missing % after the 0 )
2. Go to the locations screen and filter for the site, e.g. via https://demo.netbox.dev/dcim/locations/?site_id=21
3. Execute the report, exception gets thrown and the filter for site is deleted

Expected Behavior

Same as with successful running templates, keep the filters

Observed Behavior

Filters are deleted from the URL

Originally created by @martinum4 on GitHub (Mar 23, 2022). Originally assigned to: @jeremystretch on GitHub. ### NetBox version v3.1.9 ### Python version 3.9 ### Steps to Reproduce Reproducable on demo.netbox.dev 1. Create a malformatted export template for locations that creates an error/exception when running (e.g. ``` {% for location in queryset %} {% if location.child.count() = 0 } {{ location.name }} {% else %}{% endif %}{% endfor %} ``` Notice the missing % after the 0 ) 2. Go to the locations screen and filter for the site, e.g. via https://demo.netbox.dev/dcim/locations/?site_id=21 3. Execute the report, exception gets thrown and the filter for site is deleted ### Expected Behavior Same as with successful running templates, keep the filters ### Observed Behavior Filters are deleted from the URL
adam added the type: bugstatus: accepted labels 2025-12-29 19:38:31 +01:00
adam closed this issue 2025-12-29 19:38:31 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#6252