mihon
mihon copied to clipboard
Spam when updating progress with MangaUpdates API tracking
Steps to reproduce
- Use a network traffic capture tool like PCAPdroid and set it to capture Mihon network traffic
- Log into MangaUpdates tracking
- Ensure "Update progress after reading" is set to on
- Add an entry to be tracked
- Read one chapter on a tracked entry to trigger the tracker update
- Repeat step 5 until it starts spamming packets at api.mangaupdates.com as seen on the network traffic capture tool
Expected behavior
Mihon sends necessary packets to update the read status for the latest read chapter
Actual behavior
Mihon sends packets to the tracker at a linear rate and does not stop
Crash logs
No response
Mihon version
0.16.1
Android version
Android 14
Device
Google Pixel 7a
Other details
This behavior occurs infrequently and seems unable to be replicated on the offending entry and chapter that initiated the issue. I had to log out of the tracker to stop Mihon from sending packets to the API server as seen under the connections tab in PCAPdroid.
Relevant line from the MangaUpdates news post
I do not know why that coincided with the uptake in traffic, but it appears a misconfiguration in the app causes it to request status on various series every few seconds.
Acknowledgements
- [X] I have searched the existing issues and this is a new ticket, NOT a duplicate or related to another open or closed issue.
- [X] I have written a short but informative title.
- [X] If this is an issue with an official extension, I should be opening an issue in the extensions repository.
- [X] I have gone through the FAQ and troubleshooting guide.
- [X] I have updated the app to version 0.16.1.
- [X] I have updated all installed extensions.
- [X] I will fill out all of the requested information in this form.
Thanks for the in-depth step
I don't know if this is related, but new MangaUpdates entries seem to default to a score of '-1.0' instead of not having a score assigned like earlier versions of Tachiyomi, this may or may not be related.
This spam issue seems to have appeared between versions 0.15.1 and 0.15.3 of Tachiyomi. I don't know if 0.15.2 is affected as I wasn't on that release long enough to trigger this bug.
I'm now certain the issue is due to the invalid rating value and the app having no backoff of any sort.
Series of HTTP requests when the bug happens:
GET https://api.mangaupdates.com/v1/lists/series/17993532456 HTTP/2.0 - 200 OK
GET https://api.mangaupdates.com/v1/series/17993532456/rating HTTP/2.0 - 404 Not Found
POST https://api.mangaupdates.com/v1/lists/series/update HTTP/2.0 - 200 OK
PUT https://api.mangaupdates.com/v1/series/17993532456/rating HTTP/2.0 - 400 Bad Request !!!
GET https://api.mangaupdates.com/v1/lists/series/17993532456 HTTP/2.0 - 200 OK
GET https://api.mangaupdates.com/v1/series/17993532456/rating HTTP/2.0 - 404 Not Found
POST https://api.mangaupdates.com/v1/lists/series/update HTTP/2.0 - 200 OK
PUT https://api.mangaupdates.com/v1/series/17993532456/rating HTTP/2.0 - 400 Bad Request - It's a loop!
... about 10 more loops omitted
POST https://api.mangaupdates.com/v1/lists/series/update HTTP/2.0 - 200 OK
PUT https://api.mangaupdates.com/v1/series/17993532456/rating HTTP/2.0 - 503 Service Unavailable
GET https://api.mangaupdates.com/v1/lists/series/17993532456 HTTP/2.0 - 200 OK
GET https://api.mangaupdates.com/v1/series/17993532456/rating HTTP/2.0 - 503 Service Unavailable
POST https://api.mangaupdates.com/v1/lists/series/update HTTP/2.0 - 503 Service Unavailable
GET https://api.mangaupdates.com/v1/lists/series/17993532456 HTTP/2.0 - 503 Service Unavailable
... All further requests return 503s
@AntsyLich a024218410953a389b8af4880fa7ae6cc30124a2 wouldn't prevent this issue from coming back in the future if a score
value drops below 0 in the future, right? Anything setting that score
column should sanitize the value to ≥ 0, or anything consuming score
should ensure it's ≥ 0 before it touches MangaUpdates logic.