j6k4m8 / goosepaper

generate and deliver a daily newspaper to you or your remarkable tablet
Apache License 2.0
263 stars 21 forks source link

Limit doesn't appear to be honored #47

Closed sedennial closed 3 years ago

j6k4m8 commented 3 years ago

Can you elaborate? This is handled per-StoryProvider and they can (depending on internal behavior) do different things with this number.

sedennial commented 3 years ago

So for example I have the following config: "stories": [ { "provider": "rss", "config": { "rss_path": "https://krebsonsecurity.com/feed/", "limit": 1, "skip": true } } ]

Yet instead of pulling only one item, I get the feed limit of 10.

With this one I get 40+ pages of stories. Every time. :) "stories": [ { "provider": "rss", "config": { "rss_path": "https://www.schneier.com/feed/atom/", "limit": 10 } } ]

sedennial commented 3 years ago

Actually I just discovered that it's different behaviour depending on if I'm producing epub or pdf output. Epub give me 10. PDF seems to give me whatever the feed will serve up.

j6k4m8 commented 3 years ago

Hm that's super interesting. I'll investigate!

On Fri, May 14, 2021 at 7:10 PM sedennial @.***> wrote:

Actually I just discovered that it's different behaviour depending on if I'm producing epub or pdf output. Epub give me 10. PDF seems to give me whatever the feed will serve up.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/j6k4m8/goosepaper/issues/47#issuecomment-841544083, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAFJKB2HVE7CGWXQAWWPDYDTNWUXVANCNFSM445A5W7Q .

j6k4m8 commented 3 years ago

sho' 'nuf! we completely ignore the limit param in the rss story provider.

https://github.com/j6k4m8/goosepaper/blob/e26f6b1da7da2dc27d7aa8948bca73327e2659fd/goosepaper/rss.py#L22