mirror of
https://github.com/beetbox/beets.git
synced 2026-01-16 05:02:28 +01:00
This function is called from library.Item._getters(), making it a hot path when exporting data. We cache plugin instances but previously we reran `import` for each module on each call. We now return the cached values providing a speed boost for `beet export`. This has a small effect on `beet ls` speed: for me it went 11.00s -> 10.40. It had a significant effect on `beet export` speed when combined with https://github.com/beetbox/beets/pull/3762/. Before: $ time /home/sam/.local/bin/beet 'export' '--library' '--format' 'jsonlines' '--include-keys' 'artist,title,path,mb_artistid,mb_trackid' 'artist+ title+' > /dev/null Executed in 25.13 secs After: $ time /home/sam/.local/bin/beet 'export' '--library' '--format' 'jsonlines' '--include-keys' 'artist,title,path,mb_artistid,mb_trackid' 'artist+ title+' > /dev/null Executed in 10.49 secs |
||
|---|---|---|
| .. | ||
| autotag | ||
| dbcore | ||
| ui | ||
| util | ||
| __init__.py | ||
| __main__.py | ||
| art.py | ||
| config_default.yaml | ||
| importer.py | ||
| library.py | ||
| logging.py | ||
| mediafile.py | ||
| plugins.py | ||
| random.py | ||
| vfs.py | ||