Skip to content
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

Doesn't work with Press on Android #8

Closed
garryforreg opened this issue Jan 22, 2019 · 3 comments
Closed

Doesn't work with Press on Android #8

garryforreg opened this issue Jan 22, 2019 · 3 comments

Comments

@garryforreg
Copy link

E_ERROR (1) | plugins.local/fever/fever_api.php:578 | Uncaught PDOException: SQLSTATE[HY093]: Invalid parameter number: number of bound variables does not match number of tokens in /volume2/web/tinyrss/plugins.local/fever/fever_api.php:578 Stack trace: #0 /volume2/web/tinyrss/plugins.local/fever/fever_api.php(578): PDOStatement->execute(Array) #1 /volume2/web/tinyrss/plugins.local/fever/fever_api.php(893): FeverAPI->getItems() #2 /volume2/web/tinyrss/plugins.local/fever/index.php(70): FeverAPI->index() #3 {main} thrown

E_WARNING (2) | include/functions.php:2543 | str_repeat(): Second argument has to be greater than or equal to 01. include/functions.php(2543): str_repeat(?,, -1)2. plugins.local/fever/fever_api.php(535): arr_qmarks(Array)3. plugins.local/fever/fever_api.php(893): getItems()4. plugins.local/fever/index.php(70): index()

@corneliuskopp
Copy link

I run into the same problem, here are some details:

Incoming requests by press

I run TT-RSS in a docker container, behind an nginx reverse proxy; there are entries from nginx' access log:

"POST /tt-rss/plugins.local/fever/?api&groups HTTP/1.1" 200
"POST /tt-rss/plugins.local/fever/?api&feeds HTTP/1.1" 200
"POST /tt-rss/plugins.local/fever/?api&unread_item_ids HTTP/1.1" 200
"POST /tt-rss/plugins.local/fever/?api&items&since_id=101 HTTP/1.1" 200
"POST /tt-rss/plugins.local/fever/?api&items&since_id=151 HTTP/1.1" 200
"POST /tt-rss/plugins.local/fever/?api&items&since_id=201 HTTP/1.1" 200
"POST /tt-rss/plugins.local/fever/?api&items&since_id=251 HTTP/1.1" 200
"POST /tt-rss/plugins.local/fever/?api&unread_item_ids HTTP/1.1" 200
"POST /tt-rss/plugins.local/fever/?api&saved_item_ids HTTP/1.1" 200
"POST /tt-rss/plugins.local/fever/?api&items&with_ids= HTTP/1.1" 200

In previous incarnations I've seen the latter returning 500.

After enabling PHP error logging and cURLing the last one locally, I get the same errors that garry sees; dumping the WHERE clause and the injected arguments yields:

WHERE: owner_uid = ? AND ref_id = id AND id IN (?) LIMIT 50
ARGS: 2

I'm not sure if Press is following convention or spec with this kind of request, or if Press needs to be updated. Having said that, some searching around the internet suggests that Press updates at a somewhat glacial pace, and I can't even find it on the play store at the moment.

I've installed "Readably" instead, and it could sync my articles instantly.

@objp4th
Copy link
Contributor

objp4th commented Apr 24, 2019

When updating my TTRSS instance and Fever plugin I ran into the same problem. Press no longer worked.

Adding the exception handling for the PDO call fixes the problem and makes Press happy as the HTTP return code then remains 200 and no longer bails out as before (500).

The solution objp4th@488530e is straight forward, pull request submitted.

@subvillion
Copy link

subvillion commented Aug 6, 2019

Problem NOT with press app, problem with broken fever api plugin, ex: #13, #7
I'm used https://miniflux.app/ with fever api enabled and Press, works like a charm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants