Skip to content

Script list is slow when having large script files/a lot of scripts #8924

@kkthxbye-code

Description

@kkthxbye-code

NetBox version

v3.1.9

Python version

3.9

Steps to Reproduce

  1. Create script file with following content in the script directory (test1.py): content
  2. Duplicate it a bunch of times: for i in {2..20}; do cp test1.py "test$i.py"; done
  3. Open the script list view - /extras/scripts/

Expected Behavior

Load times should not be multiple seconds

Observed Behavior

On my i7 9700 the load times are roughly 2.3 seconds for the above example. On our production server (weaker single core performance) the performance impact is larger.

I have implemented a fix (#8925) which reduces the load time for the reproduction example from ~2300 ms to ~160 ms.

Metadata

Metadata

Assignees

Labels

status: acceptedThis issue has been accepted for implementationtype: bugA confirmed report of unexpected behavior in the application

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions