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

Retransmit CTS info messages #7

Open
PopFlamingo opened this issue Sep 5, 2021 · 1 comment
Open

Retransmit CTS info messages #7

PopFlamingo opened this issue Sep 5, 2021 · 1 comment
Labels
enhancement New feature or request

Comments

@PopFlamingo
Copy link
Owner

The bot could optionally post CTS information messages (SIRI's general-message endpoint) to a selected Discord room. This way students can be informed of live events occurring on the lanes around the university.

@PopFlamingo PopFlamingo added the enhancement New feature or request label Sep 5, 2021
@PopFlamingo
Copy link
Owner Author

Here are some mandatory constraints to respect before shipping this feature:

  • Make CTS API response parsing more resilient than usual to missing fields: if a field is missing but some useful information can still be delivered to users, make sure to do so.
  • Add retry strategies for when a message couldn't be delivered: this includes trying to send the message again (maybe at increasing time intervals, for instance starting at 15s, then 1 minute, then 10 minutes etc...) but also includes longer term retry strategies across bot/system reboots, this has two main advantages:
    • If a reboot occurs at the wrong moment, message retries won't be lost
    • If a message couldn't be delivered due to some bot-side bug, the message can still be delivered once the bug is fixed
  • As a direct result of the previous constraint, it is necessary to keep track (in the database) of which messages were/weren't delivered to which user or guild.
  • Log all failures to a dedicated file for them to be thoroughly analyzed. This includes all types of failures both on the side of the bot and on the CTS API side.
  • Find the most appropriate CTS API fetch interval. This should be respectful of the CTS servers while still providing the most up to date info to users.
  • Update the /sources command to indicate when the info messages were last updated and how often they are updated.
  • Scan CTS messages in order to attempt detecting urgent messages that should be delivered more prominently (eg: by sending an @everyone, sending a direct message to subscribed users or even reading the message using TTS).

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
Development

No branches or pull requests

1 participant