-
Notifications
You must be signed in to change notification settings - Fork 60
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
Null artist on search #267
Comments
Hello, it is not a bug, i change it in enhancement because the information about the artist does not come in the search for songs, so it must be implemented. |
Can we leave it just "empty" |
Yep, is just empty |
I'm afraid to disagree, but this really is a bug. I have been using the same build of ViMusic for well over a year now (since it hasn't been updated on F-Droid since) and until just recently the search would always show the artist and play time for songs available on YouTube Music. Now it just shows the reduced information available for videos - this is not normal. YouTube probably changed their API for songs a bit and now the reverse-engineered InnerTube client falls back to its video parsing methods, which results in this misbehaviour. I'm going to look into this issue a bit myself, but, since I haven't worked with Android applications before and certainly none so complex, help from some of the more experienced developers out here would be amazing! Thanks in advance! PS: Also mentioned this issue in the original ViMusic repo here. |
That’s right, probably YouTube changed the API, so it’s not a bug but a new feature because the structure of the API call needs to be changed. I will also work on this, at the moment it does not create problems when running the application. |
If that's your definition of a bug, I have to totally agree from a developer standpoint. However, from a user standpoint the app doesn't quite do what it is supposed to do and that feels like a bug. But enough of this definition back and forth - I'm really glad that you're also looking into it :) |
Okay, I have found the API change with this simplespython script to replicate the internal song search for "Like Woo" with an expected artist of "Kontra K" and duration of "2:28":
Apparently, Google added another FlexColumn to all songs featuring their play count, which moved the relevant FlexColumn with the artist name, play time and so on from the last one to the middle (index 1). Take a look at lines 730 to 810 in the attached JSON file for more context. A fix should be as easy as changing line 26 in |
Wow! Great, great job! Thank you for your time. |
Fixed issue #267 "Null artist on search".
This will likely be part of a fix for an issue I was investigating where playlists were crashing when they were opened. This was because of the displaying of the full duration of a playlist. The Now that the strings are correct again, the Long-term I see 2 ways that this could be addressed.
One benefit to not storing strings like this that could be derived on-the-fly is that changes in the InnerTube API like this won't result in broken databases that now contain duration strings that don't contain text in the correct format. This would improve long-term stability even when youtube changes their API without breaking existing databases. I realize that this database schema was inherited from ViMusic (and could be mirroring the result format of innertube? I'm not familiar with the API). Purely from looking at the database schema, I believe it could be optimized but I realize it may not be worth it based on legacy compatibility and effort to implement. Personally, from a design perspective, I feel that the current schema isn't ideal and it would be nice to update, however, updating the schema would end up taking a lot of work throughout the code so it could very likely be not not worth it. In addition to the fact that people may want to be able to backup/restore between ViMusic and RiMusic and this would break compatibility. Just wanted to toss out the possibility based on what I saw. |
Hello, I understood that the problem was the function and I commented momentarily in order to solve the crash. In the meantime I will manage the exceptions in the function, in order to insert the listening time of a playlist. |
Available from 0.6.16 now |
Steps to reproduce the bug
Open the app and search.
Expected behavior
The results should show the artist and the duration of the songs.
Actual behavior
The results have null artists and they show the view count instead of the duration.
Screenshots/Screen recordings
Logs
No response
RiMusic version
0.6.14
Android version
Android 13
Additional information
No response
The text was updated successfully, but these errors were encountered: