Closed Minoru closed 4 years ago
Inoreader uses the same API as The Old Reader and FeedHQ, and the code is the same. This means that either Inoreader is broken, or our code is broken for all three services.
Hello @Minoru, I'm José Rui who sent you the message reporting this bug. I've been messing with the Inoreader API directly and it seems broken to me, so I'll contact them and then let you know here their answer. Cheers!
Hey @Minoru, I've managed to mark items as unread directly though the API now. I was just not using it properly yesterday, as I did not know that I needed to change the tag parameter key from 'a' to 'r'. Ups :P.
Therefore it may be a code problem. Could you point me where to start looking, as I'm totally unfamiliar with it? Cheers!
Hey @Minoru, I believe I've found out the problem: I've tried to call the API on Postman the same way Newsboat does and it never returns an OK response, even though marking read works, marking unread does not. It seems to me the issue are the request parameters a=user/-/state/com.google/kept-unread", "a=user/-/state/com.google/tracking-kept-unread" and "ac=edit" that aren't even on the Inoreader API documentation https://www.inoreader.com/developers/edit-tag, if you remove them the feature works properly:
if (read) { postcontent = strprintf::fmt( "i=%s&a=user/-/state/com.google/read", guid); } else { postcontent = strprintf::fmt( "i=%s&r=user/-/state/com.google/read", guid); }
If this fix looks good to you can I make a pull request? Cheers!
If this fix looks good to you can I make a pull request?
Yeah, this looks great. Looking forward to your PR. Thanks for figuring it out!
Inoreader uses the same API as The Old Reader and FeedHQ, and the code is the same. This means that either Inoreader is broken, or our code is broken for all three services.
I checked The Old Reader, and toggling works fine there. I don't have a FeedHQ account, but it appears that this bug is limited to Inoreader.
Newsboat version (copy the output of
newsboat -v
or the first line ofgit show
): r2.20.1-218-g2e8c2 (current HEAD)Config file (copy from ~/.newsboat/config or ~/.config/newsboat/config):
Steps to reproduce the issue:
start Newsboat
press
R
to reload all feednavigate to a feed with at least one read item, enter that feed
find the read item, press
N
to mark it unreadpress
r
to reload this feed againThe item will become read again. Inoreader's web interface doesn't show the item as unread, either.
Other info you think is relevant: Reported by José Rui Barros on the mailing list.