beets/beetsplug
Sam Thursfield b7ccb6f516 export,info: Improve performance of --library mode
The library mode was slow due to use of item.formatted(), which
runs multiple database queries per item. The --include-keys option
didn't help because it filtered the after the queries had already
happened.

This commit reworks filtering so that we only query the fields
that the user requests. In many cases this can dramatically speed up
execution.

Before:

    > /usr/bin/time beet  export -l Bob Dylan > /dev/null
    13.42user 21.56system 0:35.71elapsed 97%CPU (0avgtext+0avgdata 52396maxresident)k

    > /usr/bin/time beet  export -l -i artist,title,path Bob Dylan > /dev/null
    13.25user 21.17system 0:35.14elapsed 97%CPU (0avgtext+0avgdata 52112maxresident)k

After:

    > /usr/bin/time beet  export -l Bob Dylan > /dev/null
    1.46user 0.09system 0:01.60elapsed 97%CPU (0avgtext+0avgdata 51188maxresident)k

    > /usr/bin/time beet  export -l -i artist,title,path Bob Dylan > /dev/null
    0.50user 0.07system 0:00.58elapsed 97%CPU (0avgtext+0avgdata 50632maxresident)k
2020-09-30 20:12:02 +02:00
..
bpd Increment playlist_version when a track is consumed. 2019-11-24 19:27:09 -08:00
lastgenre Merge pull request #3592 from thenktor/patch-2 2020-05-16 10:03:44 -04:00
metasync feat: added github actions 2020-05-25 19:35:15 -04:00
web Fix lint errors 2020-09-20 11:30:12 +10:00
__init__.py Standardize __future__ imports without parentheses 2016-02-28 15:03:51 -08:00
absubmit.py util.command_output: return stderr, too 2019-07-14 18:32:59 +02:00
acousticbrainz.py Issue #2860 Fetch more acousticbrainz fields 2019-07-23 20:25:26 -04:00
badfiles.py confit: replace with confuse in plugins 2019-06-01 10:03:41 +10:00
beatport.py add the extra_tags option to all required plugins 2020-03-28 17:36:02 +10:00
bench.py Allow multiple MB ids to be passed to the importer 2016-01-19 21:43:32 +01:00
bpm.py Merge pull request #1992 from jackwilsdon/add-write-bpm 2017-01-01 23:09:41 -05:00
bpsync.py Improve documentation 2019-10-05 15:07:20 -07:00
bucket.py Resolve W605: invalid escape sequence 2018-08-13 10:41:01 -04:00
chroma.py Update file metadata after generating fingerprintsthrough the submit command. 2020-08-26 13:36:40 +02:00
convert.py Delete after convert (#3700) 2020-08-03 20:20:20 -05:00
cue.py reintroduce default arguments, adapt all occurences of TrackInfo and AlbumInfo to the absence of positional arguments 2020-04-27 11:21:13 +02:00
deezer.py Guard against "empty" albums 2019-10-05 23:12:53 -07:00
discogs.py un-ignore E221 2020-07-11 18:33:08 -07:00
duplicates.py util.command_output: return stderr, too 2019-07-14 18:32:59 +02:00
edit.py Replace more instances of unsafe calls to yaml.load 2019-04-20 01:14:15 +02:00
embedart.py Default quality to 0 which means don't specify 2020-02-18 14:50:57 -05:00
embyupdate.py A little fiddling with embyupdate 2017-01-07 17:07:01 -05:00
export.py export,info: Improve performance of --library mode 2020-09-30 20:12:02 +02:00
fetchart.py fetchart: Improve Cover Art Archive source. (#3748) 2020-09-13 20:27:12 +01:00
filefilter.py Fix incorrect indentation 2019-01-31 00:15:42 +00:00
fish.py Enforce PEP-8 compliance on Fish completion plugin 2020-03-04 07:15:46 +01:00
freedesktop.py Standardize __future__ imports without parentheses 2016-02-28 15:03:51 -08:00
fromfilename.py Fix "line too long" Travis CI error 2017-12-21 15:18:25 +01:00
ftintitle.py Fix #2817: drop in configuration was ignored 2018-02-23 18:18:32 -05:00
fuzzy.py Use new as_str method 2016-06-25 19:16:14 -07:00
gmusic.py gmusic: Fix compatibility with gmusicapi>=12.0.0 2019-05-18 16:32:56 -04:00
hook.py Switch to using check_call for hooks 2019-10-17 11:00:59 +01:00
ihate.py Standardize __future__ imports without parentheses 2016-02-28 15:03:51 -08:00
importadded.py beetsplug/importadded: Add missing path kwarg to update_after_write_time() 2019-06-07 14:17:39 +02:00
importfeeds.py Fix importfeeds plugin on Python 3. 2017-08-12 16:45:13 +01:00
info.py export,info: Improve performance of --library mode 2020-09-30 20:12:02 +02:00
inline.py inline: Fix a ridiculously subtle flexattr bug 2019-06-01 12:28:47 -04:00
ipfs.py Merge pull request #2554 from musoke/python3-plugin-ipfs 2020-07-14 06:58:20 -04:00
keyfinder.py support for keyfinder-cli, which doesn't want the -f flag for paths 2020-01-14 05:07:33 +01:00
kodiupdate.py Make error handling and logging more detailed 2017-08-20 14:51:03 -07:00
lastimport.py Update a lot of URLs to use HTTPS 2019-06-05 03:11:49 +02:00
loadext.py Add loadext plugin 2019-04-21 15:10:28 +01:00
lyrics.py lyrics: fix bad_triggers in the google plugin 2020-07-12 22:23:17 +02:00
mbcollection.py mbcollection: Make sure missing albums are removed from collections correctly. 2018-02-23 12:34:33 +00:00
mbsubmit.py Update a lot of URLs to use HTTPS 2019-06-05 03:11:49 +02:00
mbsync.py Improve documentation 2019-10-05 15:07:20 -07:00
missing.py beetsplug: implement missing -a -t 2017-03-18 19:05:46 -04:00
mpdstats.py mpdstats: Don't record a skip when stopping MPD. 2020-08-10 07:07:17 -07:00
mpdupdate.py mpdupdate: use MPD_PORT env variable 2019-04-19 17:35:42 +10:00
parentwork.py Get the date of the parentwork, which may be different from the date of the child work. 2020-07-03 09:35:15 -07:00
permissions.py replace deprecated log.warn() with log.warning() 2016-08-09 00:33:38 -04:00
play.py Add ability for play plugin to emit utf8 BOM 2018-06-08 23:26:48 -06:00
playlist.py un-ignore E221 2020-07-11 18:33:08 -07:00
plexupdate.py Rename use_secure to secure and add to changelog 2020-06-08 20:19:19 -04:00
random.py random: beets.util.random -> beets.random 2019-04-07 18:46:11 +10:00
replaygain.py Fix new flake8 warnings 2020-05-13 08:20:50 -04:00
rewrite.py Use new as_str method 2016-06-25 19:16:14 -07:00
scrub.py mediafile: import from standalone module 2019-05-29 09:35:14 +10:00
smartplaylist.py fix: revert flake8 change 2020-06-04 02:09:04 -04:00
sonosupdate.py Remove unused import. 2018-04-20 08:25:08 +02:00
spotify.py Integrate MetadataSourcePlugin 2019-09-15 15:59:24 -07:00
subsonicplaylist.py style: flake8 linting 2020-05-25 20:06:43 -04:00
subsonicupdate.py fix(plugin): subsonicupdate rest call 2020-09-04 00:51:03 -04:00
the.py fix regex, add test and changelog entry 2020-07-30 22:42:31 +02:00
thumbnails.py Fix thumbnail plugin pathlib bug (#3360) 2020-07-15 21:00:50 -05:00
types.py confit: replace with confuse in plugins 2019-06-01 10:03:41 +10:00
unimported.py improvements from review #2 2019-10-15 21:54:35 +02:00
zero.py confit: replace with confuse in plugins 2019-06-01 10:03:41 +10:00