-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
#2347: First hack of ignoring already tagged items #2349
Conversation
|
||
if not force: | ||
mood_str = item.get('mood_acoustic', u'') | ||
if len(mood_str) != 0: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
or simply
if mood_str:
@@ -118,7 +119,13 @@ def commands(self): | |||
|
|||
def func(lib, opts, args): | |||
items = lib.items(ui.decargs(args)) | |||
self._fetch_info(items, ui.should_write()) | |||
self._fetch_info(items, ui.should_write(),opts.force_refetch or self.config['force']) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
,opts.force_refetch => , opts.force_refetch
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks fantastic; thank you! @Kraymer has a couple of small suggestions, and I found one addition that could be useful here. And would you mind adding just a sentence or two about the new option to the plugin's documentation page (docs/plugins/acousticbrainz.rst
)?
@@ -118,7 +119,13 @@ def commands(self): | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we might need something like this to make the command-line flag work:
cmd.parser.add_option(
u'-f', u'--force', dest='force_refetch',
action='store_true', default=False,
help=u're-download data if present',
)
#2347: First hack of ignoring already tagged items
Looks perfect! Thank you! ✨ 🚀 🤖 I've merged this for inclusion in the next release. |
Improve the speed of fetching acousticbrainz data. Ignore already existing data.