You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Did you check to see if this issue already exists?
Is this only a single bug? Do not put multiple bugs in one issue.
Is this a backend issue? Use the lemmy-ui repo for UI / frontend issues.
Summary
There's some posts that have a date in the future (e.g.
)
this causes the hot_rank function to throw. i don't know if this error actually happens in the wild, but it would cause hot rank updates to stop working mostly completely for all new posts.
i've managed to reproduce it synthetically which was maybe a bad idea:
"message": "a negative number raised to a non-integer power yields a complex result",
"context": "PL/pgSQL function hot_rank(numeric,timestamp without time zone) line 4 at RETURN",
"statement": "WITH batch AS (SELECT a.id\n FROM post_aggregates a\n WHERE a.published > $1\n ORDER BY a.published\n LIMIT $2\n FOR UPDATE SKIP LOCKED)\n UPDATE post_aggregates a SET hot_rank = hot_rank(a.score, a.published),\n hot_rank_active = hot_rank(a.score, a.newest_comment_time_necro)\n FROM batch WHERE a.id = batch.id RETURNING a.published;\n",
Steps to Reproduce
receive a post with time in the future via federation
check published column
hot_rank(score, published) will throw the above error
Technical Details
..
Version
0.18.1-rc
Lemmy Instance URL
No response
The text was updated successfully, but these errors were encountered:
Requirements
Summary
There's some posts that have a date in the future (e.g.
)
this causes the hot_rank function to throw. i don't know if this error actually happens in the wild, but it would cause hot rank updates to stop working mostly completely for all new posts.
i've managed to reproduce it synthetically which was maybe a bad idea:
Steps to Reproduce
Technical Details
..
Version
0.18.1-rc
Lemmy Instance URL
No response
The text was updated successfully, but these errors were encountered: