Rewrite all imports to pull constants from constants.py instead of models.py #1385

Closed
opened 2025-12-29 16:31:57 +01:00 by adam · 1 comment
Owner

Originally created by @jeremystretch on GitHub (Nov 6, 2017).

Issue type

[x] Feature request
[ ] Bug report
[ ] Documentation

Environment

  • Python version: 3.5.2
  • NetBox version: 2.2.4

Description

This issue is just for housekeeping. A while back we moved all constant variable declarations into a constants.py file within each app, but many of the import statements were never updated and still pull constants indirectly via models.py.

Originally created by @jeremystretch on GitHub (Nov 6, 2017). ### Issue type [x] Feature request <!-- An enhancement of existing functionality --> [ ] Bug report <!-- Unexpected or erroneous behavior --> [ ] Documentation <!-- A modification to the documentation --> ### Environment * Python version: 3.5.2 * NetBox version: 2.2.4 ### Description This issue is just for housekeeping. A while back we moved all constant variable declarations into a `constants.py` file within each app, but many of the import statements were never updated and still pull constants indirectly via `models.py`.
adam added the type: housekeeping label 2025-12-29 16:31:57 +01:00
adam closed this issue 2025-12-29 16:31:58 +01:00
Author
Owner

@jeremystretch commented on GitHub (Nov 7, 2017):

I've also taken this opportunity to reorganize all import statements. The resulting diff looks huge but it's merely housekeeping.

@jeremystretch commented on GitHub (Nov 7, 2017): I've also taken this opportunity to reorganize all import statements. The resulting diff looks huge but it's merely housekeeping.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#1385