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

bsky.rss version 2 #25

Merged
merged 111 commits into from
Feb 11, 2024
Merged

bsky.rss version 2 #25

merged 111 commits into from
Feb 11, 2024

Conversation

milanmdev
Copy link
Owner

@milanmdev milanmdev commented Aug 4, 2023

This PR introduces v2 of bsky.rss.

Testing and feedback are greatly appreciated.

  • Makes a system for queuing posts so rate limits are less likely to occur.
  • Allows for custom date & image fields to be provided
  • Allows for a custom user agent to be provided for Open Graph fetching
  • Enables ability to filter out HTML from descriptions

Closes #14, #29, #27, #33, #51

If you think other features should be included with this PR, please leave a comment.

@milanmdev milanmdev added the enhancement New feature or request label Aug 4, 2023
@milanmdev milanmdev self-assigned this Aug 4, 2023
@rmdes
Copy link

rmdes commented Aug 5, 2023

So I ran docker build -t bsky-queue .
than replaced the image: with my local image
then added "UseQueue": True to config.json
then I docker-compose up

and this is the tracelog :

TSError: ⨯ Unable to compile TypeScript: │
│ app/utils/queueHandler.ts(5,5): error TS6133: 'queueRunning' is declared but its value is never read. │
│ at createTSError (/build/node_modules/ts-node/src/index.ts:859:12) │
│ at reportTSError (/build/node_modules/ts-node/src/index.ts:863:19) │
│ at getOutput (/build/node_modules/ts-node/src/index.ts:1077:36) │
│ at Object.compile (/build/node_modules/ts-node/src/index.ts:1433:41) │
│ at Module.m._compile (/build/node_modules/ts-node/src/index.ts:1617:30) │
│ at Module._extensions..js (node:internal/modules/cjs/loader:1310:10) │
│ at Object.require.extensions. [as .ts] (/build/node_modules/ts-node/src/index.ts:1621:12) │
│ at Module.load (node:internal/modules/cjs/loader:1119:32) │
│ at Function.Module._load (node:internal/modules/cjs/loader:960:12) │
│ at Module.require (node:internal/modules/cjs/loader:1143:19) { │
│ diagnosticCodes: [ 6133 ] │
│ } │
│ error Command failed with exit code 1. │
│ info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command. │
│ yarn run v1.22.19 │
│ $ ts-node ./app/index.ts │
│ /build/node_modules/ts-node/src/index.ts:859 │
│ return new TSError(diagnosticText, diagnosticCodes, diagnostics); │
│ ^ │
│ TSError: ⨯ Unable to compile TypeScript:

@rmdes
Copy link

rmdes commented Aug 5, 2023

Suggestion based on my extensive usage of newsbots over the years on twitter mostly, but also mastodon.

User experience is at its best when, along with when queue management and post spacing can be defined, that's the base
but then, to improve user experience, I would suggest some kind of randomness so that posts are not just delivered every 5 minutes, night & day, instead, the idea is, taking into account the queue, the space in between posts (when was the last post in time) and then adding to that a time randomness variable that basically push the next post in a range of delay so that it's never just 00:00, 05, 10, 15, 20 etc...the idea is not to hide that it's a bot (mastodon has a feature to openly declare it and I hope bluesky will also have this in some way) but the idea is more to remove the expectations that the newsbot will post mathematically every 5 minutes.

Maybe it's too complicated to implement, but I think that a formula could be figured that takes into account the size of the queue, the recommended space in between posts and then do some random math to make the time of posting more fuzzy, less predictable. so if the queue is very small add more space in between posts, but if the queue is big, post more regularly?

Maybe i'm completely over the board here with this suggestion, just say No and I won't insist 😄

@rmdes
Copy link

rmdes commented Aug 5, 2023

So I ran docker build -t bsky-queue . than replaced the image: with my local image then I docker-compose up

and this is the tracelog :

TSError: ⨯ Unable to compile TypeScript: │ │ app/utils/queueHandler.ts(5,5): error TS6133: 'queueRunning' is declared but its value is never read. │ │ at createTSError (/build/node_modules/ts-node/src/index.ts:859:12) │ │ at reportTSError (/build/node_modules/ts-node/src/index.ts:863:19) │ │ at getOutput (/build/node_modules/ts-node/src/index.ts:1077:36) │ │ at Object.compile (/build/node_modules/ts-node/src/index.ts:1433:41) │ │ at Module.m._compile (/build/node_modules/ts-node/src/index.ts:1617:30) │ │ at Module._extensions..js (node:internal/modules/cjs/loader:1310:10) │ │ at Object.require.extensions. [as .ts] (/build/node_modules/ts-node/src/index.ts:1621:12) │ │ at Module.load (node:internal/modules/cjs/loader:1119:32) │ │ at Function.Module._load (node:internal/modules/cjs/loader:960:12) │ │ at Module.require (node:internal/modules/cjs/loader:1143:19) { │ │ diagnosticCodes: [ 6133 ] │ │ } │ │ error Command failed with exit code 1. │ │ info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command. │ │ yarn run v1.22.19 │ │ $ ts-node ./app/index.ts │ │ /build/node_modules/ts-node/src/index.ts:859 │ │ return new TSError(diagnosticText, diagnosticCodes, diagnostics); │ │ ^ │ │ TSError: ⨯ Unable to compile TypeScript:

after some debugging :

Adjust your TypeScript configuration: If you want to allow unused variables in your code without the compiler throwing an error, you can adjust your tsconfig.json file. Look for the noUnusedLocals option and set it to false. However, keep in mind that this will apply to your entire project, and having unused variables can sometimes be a sign of a bug or unnecessary code.

@rmdes
Copy link

rmdes commented Aug 5, 2023

so when noUnusedLocals in tsconfig.json option and set it to false the container run without screaming at this variable

things apparently get queued :

bsky-queue.rss  | [Sat, 05 Aug 2023 11:09:51 GMT] - [bsky.rss] Queuing item (CVE-2023-4159)
bsky-queue.rss  | [Sat, 05 Aug 2023 11:09:51 GMT] - [bsky.rss] Queuing item (CVE-2023-38700)

but then something is undefined ? (the space in between posts?)

bsky-queue.rss  | [Sat, 05 Aug 2023 11:10:51 GMT] - [bsky.rss] Posting new item (CVE-2023-4159)
bsky-queue.rss  | undefined
bsky-queue.rss  | [Sat, 05 Aug 2023 11:10:51 GMT] - [bsky.rss] Posting new item (CVE-2023-38700)
bsky-queue.rss  | undefined

This is an extract, I tweaked the last.txt (went back on time) to create a situation where last fetch was an hour ago and it flooded the timeline with some 10+ posts at once, but it did not went over rate limits

@rmdes
Copy link

rmdes commented Aug 5, 2023

I'm not a typescript/JS dev but with some code-interpreter AI help this is what I got :

Assuming you have a function that processes the queue, you could add a delay that depends on the size of the queue. Here's a simple example:

async function processQueue() {
  while (queue.length > 0) {
    const post = queue.shift(); // Get the next post from the queue
    await postFunction(post); // Post it

    // Calculate delay
    const minDelay = 5 * 60 * 1000; // Minimum delay of 5 minutes
    const maxDelay = minDelay + queue.length * 1000; // Add 1 second for each remaining post in the queue
    const delay = Math.random() * (maxDelay - minDelay) + minDelay; // Random delay between minDelay and maxDelay

    // Wait for the delay before continuing with the next post
    await new Promise(resolve => setTimeout(resolve, delay));
  }
}

In this example, queue is an array that contains the posts to be posted, and postFunction is a function that posts a single post. The delay between posts is at least 5 minutes, and increases by 1 second for each remaining post in the queue. The actual delay is a random value between this minimum and maximum delay.

You probably had something equal or similar to this in mind already

@milanmdev
Copy link
Owner Author

Will look into the randomness of posting from queue. As for the error when compiling, I must have left something in the code that I didn't use, I'll remove that. As for the undefined, I believe I left a console.log block in there, so I'll fix that too.

@rmdes
Copy link

rmdes commented Aug 5, 2023

feedback : Maybe I could be wrong, but the current queue system does not seem to return back to fetching new posts when it's done, the cve bot has not posted anything since 11h CET

  • I looked at the original source feed and noticed they were new CVE's
  • did docker-compose down, removed my inoreader CVE feed and went to the original
  • did docker-compose up
  • got this output a thousand time : bsky-queue.rss | No date provided by RSS reader for post.
  • the bot is still not updating

@milanmdev
Copy link
Owner Author

milanmdev commented Aug 5, 2023

What's the URL of your feed? I'm working on a feature to allow more field compatibility.

@rmdes
Copy link

rmdes commented Aug 5, 2023

I just checked at the branch without the queue system and the "no date provided" issue remains, it's not your code, it's the actual NIST feed being a weird RSS https://nvd.nist.gov/feeds/xml/cve/misc/nvd-rss.xml

@rmdes
Copy link

rmdes commented Aug 5, 2023

when I wrap the NIST feed via Inoreader, then I have a date field : https://www.inoreader.com/stream/user/1005324229/tag/CVE
JSON view of this feed : https://www.inoreader.com/stream/user/1005324229/tag/CVE/view/json

@benborges
Copy link

benborges commented Aug 5, 2023

I'm testing this branch and I confirm something is strange, it's queuing but it's not posting ?
edit: my bad, it is posting, but not sure how the space in between posts is configured, 30 sec?
it just does not output that it is posting when it does

my rss feed is : https://ukraine.osintukraine.com/index.xml

this is a good feed to do testing because it updates often and can easy have 50+ updates at a time

https://bsky.app/profile/ukrainetg.bsky.social
image

@milanmdev
Copy link
Owner Author

milanmdev commented Aug 5, 2023

It should log a message when it posts. I believe that the queue runs every 60 seconds, and when a rate limit occurs, it waits 30 seconds before re-trying.

image

@benborges
Copy link

benborges commented Aug 5, 2023

something is still strange here, not sure what :

the last post is : @AmplifyUkraine on 2023-08-05 15:41:59 (#514181) 20 min ago
image

but screenshot shows all the subsequent queued posts, but they are not getting posted, while they are being queued ?

Something is clear : it's not hitting the rate limit, so the queue is actually working, it's just not clear how much time it waits, and the output isn't telling anymore when it posts, or when is due the next post round

@benborges
Copy link

It should log a message when it posts. I believe that the queue runs every 60 seconds, and when a rate limit occurs, it waits 30 seconds before re-trying.
image

I'm not seeing the usual 'posting new item' but it's definitely posting and taking into account the queue
i'm at #514210 now (ref to the image above)

@milanmdev
Copy link
Owner Author

useQueue is no longer needed and runInterval now is. runInterval is the config field that lets you define how often the queue runs (in seconds).

@rmdes
Copy link

rmdes commented Aug 5, 2023

Alright, adapted and rebuilt container in local to run with these changes.
but in the case of the nist CVE rss feed, I cannot get it to run : https://nvd.nist.gov/download/nvd-rss.xml

I have this error :

yarn run v1.22.19
$ ts-node ./app/index.ts
/build/node_modules/ts-node/src/index.ts:859
    return new TSError(diagnosticText, diagnosticCodes, diagnostics);
           ^
TSError: ⨯ Unable to compile TypeScript:
app/utils/rssHandler.ts(10,13): error TS2304: Cannot find name 'Config'.
app/utils/rssHandler.ts(22,34): error TS2304: Cannot find name 'Item'.
app/utils/rssHandler.ts(36,16): error TS2304: Cannot find name 'Embed'.
app/utils/rssHandler.ts(137,44): error TS2304: Cannot find name 'Item'.
app/utils/rssHandler.ts(138,15): error TS2304: Cannot find name 'ParseResult'.
    at createTSError (/build/node_modules/ts-node/src/index.ts:859:12)
    at reportTSError (/build/node_modules/ts-node/src/index.ts:863:19)
    at getOutput (/build/node_modules/ts-node/src/index.ts:1077:36)
    at Object.compile (/build/node_modules/ts-node/src/index.ts:1433:41)
    at Module.m._compile (/build/node_modules/ts-node/src/index.ts:1617:30)
    at Module._extensions..js (node:internal/modules/cjs/loader:1310:10)
    at Object.require.extensions.<computed> [as .ts] (/build/node_modules/ts-node/src/index.ts:1621:12)
    at Module.load (node:internal/modules/cjs/loader:1119:32)
    at Function.Module._load (node:internal/modules/cjs/loader:960:12)
    at Module.require (node:internal/modules/cjs/loader:1143:19) {
  diagnosticCodes: [ 2304, 2304, 2304, 2304, 2304 ]
}
error Command failed with exit code 1

so I'm not sure what's causing this
I'm on branch queue and did a docker build -t bsky-queue .
and adapted the compose file to run this local image.

DevCaptainOne and others added 2 commits January 8, 2024 10:03
- Remove duplicates by storing the URL of the RSS articles and prevent publishing the same article twice.
- Remote HTML tags and entities from the title.
@milanmdev
Copy link
Owner Author

@rmdes Is that issue still happening or has that been resolved? I can't reproduce these issues so I wonder if it's something on Bluesky's end relating to your IP?

@rmdes
Copy link

rmdes commented Jan 16, 2024

@rmdes Is that issue still happening or has that been resolved? I can't reproduce these issues so I wonder if it's something on Bluesky's end relating to your IP?

much rarely lately, sometimes 1 over 20+ bots get into that state but then a docker compose restart and it's all going fine,
maybe I should simply have another script fetch log of these containers and when this kind of error happen, wait some time before restarting the container, dirty fix, but it would serve me well.

Other than that, it's all operating really well :)

@milanmdev
Copy link
Owner Author

Still really odd that that's happening. I don't know an easy way to implement a restart if that happens. If you could give me a bullet point list of the scenario where that error occurs (ways to identify that specific error, e.g. large queue buildup + rate limiting), I can try and make a configurable function that can restart the service when that error happens.

@milanmdev
Copy link
Owner Author

@rmdes, I think I'm going to get this merged into the main branch soon. As for your issue, if you could still send me that bullet list of the factors that contribute to the large queue build-up, I'll open another PR addressing that. If you don't think this is stable enough for your case at the moment, you can stick to v1 while I get that issue sorted out. I still haven't been able to reproduce it anywhere else.

@rmdes
Copy link

rmdes commented Feb 10, 2024

Still really odd that that's happening. I don't know an easy way to implement a restart if that happens. If you could give me a bullet point list of the scenario where that error occurs (ways to identify that specific error, e.g. large queue buildup + rate limiting), I can try and make a configurable function that can restart the service when that error happens.

I'm not even sure myself why this happens, maybe it's related that my VPS host a few bots and that combined they manage to hit the limits ?
yes it does happen on more active bots than others but the bots can runs for days without it ever happening and suddenly it happens, so I'm myself pretty much lost on what I can give you beside the RSS feeds themselves to try to reproduce this.

@rmdes
Copy link

rmdes commented Feb 10, 2024

@rmdes, I think I'm going to get this merged into the main branch soon. As for your issue, if you could still send me that bullet list of the factors that contribute to the large queue build-up, I'll open another PR addressing that. If you don't think this is stable enough for your case at the moment, you can stick to v1 while I get that issue sorted out. I still haven't been able to reproduce it anywhere else.

I'm following you on this, I'll update by bots to run on the main branch v2

@rmdes
Copy link

rmdes commented Feb 10, 2024

I'm posting this here, because bots where this happens are still running on the queue branch
I have a hunch this might be related to something that changed on the bluesky side ?

but some bots now do this kind of error output :

Sat, 10 Feb 2024 12:08:09 GMT] - [bsky.rss QUEUE] Running queue with 0 items node:internal/errors:563 ErrorCaptureStackTrace(err); ^ Error: listen EADDRINUSE: address already in use /tmp/tsx-0/46.pipe at Server.setupListenHandle [as _listen2] (node:net:1855:21) at listenInCluster (node:net:1920:12) at Server.listen (node:net:2025:5) at file:///build/node_modules/tsx/dist/cli.mjs:53:31317 at new Promise (<anonymous>) at yn (file:///build/node_modules/tsx/dist/cli.mjs:53:31295) at async file:///build/node_modules/tsx/dist/cli.mjs:55:459 { code: 'EADDRINUSE', errno: -98, syscall: 'listen', address: '/tmp/tsx-0/46.pipe', port: -1 } Node.js v20.11.0 node:internal/errors:563 ErrorCaptureStackTrace(err); ^ Error: listen EADDRINUSE: address already in use /tmp/tsx-0/46.pipe at Server.setupListenHandle [as _listen2] (node:net:1855:21) at listenInCluster (node:net:1920:12) at Server.listen (node:net:2025:5) at file:///build/node_modules/tsx/dist/cli.mjs:53:31317 at new Promise (<anonymous>) at yn (file:///build/node_modules/tsx/dist/cli.mjs:53:31295) at async file:///build/node_modules/tsx/dist/cli.mjs:55:459 { code: 'EADDRINUSE', errno: -98, syscall: 'listen', address: '/tmp/tsx-0/46.pipe', port: -1 } Node.js v20.11.0 node:internal/errors:563 ErrorCaptureStackTrace(err); ^ Error: listen EADDRINUSE: address already in use /tmp/tsx-0/43.pipe at Server.setupListenHandle [as _listen2] (node:net:1855:21) at listenInCluster (node:net:1920:12) at Server.listen (node:net:2025:5) at file:///build/node_modules/tsx/dist/cli.mjs:53:31317 at new Promise (<anonymous>) at yn (file:///build/node_modules/tsx/dist/cli.mjs:53:31295) at async file:///build/node_modules/tsx/dist/cli.mjs:55:459 { code: 'EADDRINUSE', errno: -98, syscall: 'listen', address: '/tmp/tsx-0/43.pipe', port: -1 } Node.js v20.11.0 node:internal/errors:563 ErrorCaptureStackTrace(err); ^ Error: listen EADDRINUSE: address already in use /tmp/tsx-0/46.pipe at Server.setupListenHandle [as _listen2] (node:net:1855:21) at listenInCluster (node:net:1920:12) at Server.listen (node:net:2025:5) at file:///build/node_modules/tsx/dist/cli.mjs:53:31317 at new Promise (<anonymous>) at yn (file:///build/node_modules/tsx/dist/cli.mjs:53:31295) at async file:///build/node_modules/tsx/dist/cli.mjs:55:459 { code: 'EADDRINUSE', errno: -98, syscall: 'listen', address: '/tmp/tsx-0/46.pipe', port: -1 } Node.js v20.11.0 node:internal/errors:563 ErrorCaptureStackTrace(err); ^ Error: listen EADDRINUSE: address already in use /tmp/tsx-0/43.pipe at Server.setupListenHandle [as _listen2] (node:net:1855:21) at listenInCluster (node:net:1920:12) at Server.listen (node:net:2025:5) at file:///build/node_modules/tsx/dist/cli.mjs:53:31317 at new Promise (<anonymous>) at yn (file:///build/node_modules/tsx/dist/cli.mjs:53:31295) at async file:///build/node_modules/tsx/dist/cli.mjs:55:459 { code: 'EADDRINUSE', errno: -98, syscall: 'listen', address: '/tmp/tsx-0/43.pipe', port: -1 } Node.js v20.11.0 node:internal/errors:563 ErrorCaptureStackTrace(err); ^ Error: listen EADDRINUSE: address already in use /tmp/tsx-0/44.pipe at Server.setupListenHandle [as _listen2] (node:net:1855:21) at listenInCluster (node:net:1920:12) at Server.listen (node:net:2025:5) at file:///build/node_modules/tsx/dist/cli.mjs:53:31317 at new Promise (<anonymous>) at yn (file:///build/node_modules/tsx/dist/cli.mjs:53:31295) at async file:///build/node_modules/tsx/dist/cli.mjs:55:459 { code: 'EADDRINUSE', errno: -98, syscall: 'listen', address: '/tmp/tsx-0/44.pipe', port: -1 } Node.js v20.11.0 node:internal/errors:563 ErrorCaptureStackTrace(err); ^ Error: listen EADDRINUSE: address already in use /tmp/tsx-0/44.pipe at Server.setupListenHandle [as _listen2] (node:net:1855:21) at listenInCluster (node:net:1920:12) at Server.listen (node:net:2025:5) at file:///build/node_modules/tsx/dist/cli.mjs:53:31317 at new Promise (<anonymous>) at yn (file:///build/node_modules/tsx/dist/cli.mjs:53:31295) at async file:///build/node_modules/tsx/dist/cli.mjs:55:459 { code: 'EADDRINUSE', errno: -98, syscall: 'listen', address: '/tmp/tsx-0/44.pipe', port: -1 } Node.js v20.11.0 node:internal/errors:563 ErrorCaptureStackTrace(err); ^ Error: listen EADDRINUSE: address already in use /tmp/tsx-0/44.pipe at Server.setupListenHandle [as _listen2] (node:net:1855:21) at listenInCluster (node:net:1920:12) at Server.listen (node:net:2025:5) at file:///build/node_modules/tsx/dist/cli.mjs:53:31317 at new Promise (<anonymous>) at yn (file:///build/node_modules/tsx/dist/cli.mjs:53:31295) at async file:///build/node_modules/tsx/dist/cli.mjs:55:459 { code: 'EADDRINUSE', errno: -98, syscall: 'listen', address: '/tmp/tsx-0/44.pipe', port: -1 } Node.js v20.11.0

@milanmdev
Copy link
Owner Author

That error seems like it's something to do with the tsx runner. I don't know why that would be happening. Which docker image are you using?

@rmdes
Copy link

rmdes commented Feb 10, 2024

I'm using build 165829101 from the queue branch, package provided by you, not locally build, from last month.

This is really new, haven't seen this before last week but only got time to report now.. also it's only happening on 1 or 2 bots and I'm not sure why since nothing changed on my side.

@milanmdev
Copy link
Owner Author

Can you try queue-1d447f8? I updated the version of tsx which may fix the issue(?)

@rmdes
Copy link

rmdes commented Feb 10, 2024

Trying now..will report back about the tsx issue

@rmdes
Copy link

rmdes commented Feb 10, 2024

Can you try queue-1d447f8? I updated the version of tsx which may fix the issue(?)

I think it's good now, no more tsx issues

@milanmdev
Copy link
Owner Author

Good to hear, thanks for the update.

@milanmdev milanmdev linked an issue Feb 10, 2024 that may be closed by this pull request
@milanmdev
Copy link
Owner Author

Going to test this on one of my public bots for ~24 hours and then if all goes well, I should be able to merge this in. Thanks for everyone's contributions!

@milanmdev milanmdev merged commit fd3cb0b into main Feb 11, 2024
@rmdes
Copy link

rmdes commented Feb 17, 2024

Keep having the now infamous and hard to track Post rate limit exceeded

bsky.rss POST] Post rate limit exceeded - process will resume after 30 seconds │
│ [Sat, 17 Feb 2024 15:29:39 GMT] - [bsky.rss QUEUE] Running queue with 20 items │
│ [Sat, 17 Feb 2024 15:29:39 GMT] - [bsky.rss POST] Post rate limit exceeded - process will resume after 30 seconds │
│ [Sat, 17 Feb 2024 15:30:39 GMT] - [bsky.rss QUEUE] Running queue with 20 items │
│ [Sat, 17 Feb 2024 15:30:39 GMT] - [bsky.rss POST] Post rate limit exceeded - process will resume after 30 seconds │
│ [Sat, 17 Feb 2024 15:31:39 GMT] - [bsky.rss QUEUE] Running queue with 20 items │
│ [Sat, 17 Feb 2024 15:31:39 GMT] - [bsky.rss POST] Post rate limit exceeded - process will resume after 30 seconds │
│ [Sat, 17 Feb 2024 15:32:39 GMT] - [bsky.rss QUEUE] Running queue with 20 items │
│ [Sat, 17 Feb 2024 15:32:39 GMT] - [bsky.rss QUEUE] Queuing item (Morto Giovanni Bagassi, l’ex bimbo dai riccioli rossi che recitò con Renato Pozzetto e Terence Hill: aveva 50 anni) │
│ [Sat, 17 Feb 2024 15:32:39 GMT] - [bsky.rss POST] Post rate limit exceeded - process will resume after 30 seconds │
│ [Sat, 17 Feb 2024 15:32:40 GMT] - [bsky.rss QUEUE] Queuing item (Il mistero sulla “scomparsa” della fiction Rai su don Andrea Gallo. Il braccio destro del prete: “A novembre 2022 pareva tutto pronto”) │
│ [Sat, 17 Feb 2024 15:32:40 GMT] - [bsky.rss QUEUE] Queuing item (Cade nel camino acceso: 72enne muore in provincia di Nuoro. Aperta un’inchiesta e disposta l’autopsia)

image

The RSS feed for this source is here

Granted, this is a particularly busy feed, because it merge a few rss feeds into one (from the main italian media) and then output the mix as a single rss feed, which is then used to feed the bot.

It's happening rarely now but it keeps coming up, I do not know if we have enough log coming from blueksy to know more about this, usually a restart would do the trick but now, it keeps piling up items without ever flushing it

image

@milanmdev
Copy link
Owner Author

Sorry, I somehow missed this. Would it suffice to add a watch feature where it will check if the queue exceeds a certain amount of items, and if it does, it can restart itself?

@rmdes
Copy link

rmdes commented May 21, 2024

no worries, I think that provided we could set a threshold number in the config for this restart to trigger, I think this could work ☺️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
5 participants