-
Notifications
You must be signed in to change notification settings - Fork 14
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
Fix queries for library items containing slashes (/) #36
base: main
Are you sure you want to change the base?
Conversation
Running flake8 locally results in warnings caused by the various |
Hey @jodal! Could you help out with these two PRs of mine (the other is #37)? They both get stuck at flake8 complaining about lines in the existing code base that I haven't touched, and I feel uncertain how to proceed. Should I try to look into the existing code and fix the flake8 warnings on a separate PR, or can we somehow ignore the warnings since they are not a result of something I did, and proceed with merging? |
If you could fix it up in your PR that'd be good. It fails, despite you not touching these lines, because the version of flake8 has changed compared to when we last ran CI (and also compared to whatever version you ran locally). The fix is at https://github.com/mopidy/mopidy-soundcloud/pull/132/files |
Thanks a lot @kingosticks, that was really helpful! I added the suggested edits to |
If you run For the PR itself, I don't use beets (and we don't have any tests!) so I'm not well placed to merge this. Maybe @sumpfralle can help. |
Thanks again, and sorry for the extra trouble. This is the first time I'm dealing with automated CI/CD loops.
I didn't know of
I don't have a python3.9 intepreter, but that didn't seem to fail during the integration loop, whereas flake8 doesn't show any errors. Am I missing something? |
Sorry, seems I've misremembered and thought You'll have to manually upgrade your local versions, |
No need to be sorry, I really appreciate your help and patience! In some sense it has been illuminating having these extra complications, since it has also thought me many new things I haven't been aware of! Anyways, I upgraded |
In it's current form, beets library items with slashes
/
in their names are not found correctly. Examples of such items in my library are artists with names such asHarold Budd/Brian Eno
or genres such asAmbient/Experimental
.I poked around
BeetsRemoteClient
inclient.py
, more specifically the_get_objects_by_attribute
-method which makes the queries for Beets Web, and figured that removing the regex search for items containing slashes does the trick.I'm quite sure the regex search could also be adjusted to include slashes, but I couldn't find a way I was happy with, although I got quite close. Since removing the regex search fixes the functionality, I thought it's already a good step forward!
Let me know if I should adjust the PR somehow before it can be accepted!