fix/movie_names_and_background_task #46

Merged
kenobi merged 5 commits from fix/movie_names_and_background_task into master 2023-06-19 11:29:04 +02:00
Collaborator

Sieht nach viel aus, ist beim closepoll aber hauptsächlich durch die Gegend schieben

Sieht nach viel aus, ist beim closepoll aber hauptsächlich durch die Gegend schieben
magnetotail added 2 commits 2023-06-17 12:07:48 +02:00
improve movie name resolving
All checks were successful
Build a docker image for node-jellyfin-role-bot / build-docker-image (push) Successful in 1m55s
d6300e8bec
When creating the poll the bot will now only request movie names instead of movies
This improves the errorhandling because the movie names cannot be null
Also the movieName function filters empty movienames and will guarantee the requested number of names
move scheduling of pollclose task to startup
All checks were successful
Build a docker image for node-jellyfin-role-bot / build-docker-image (push) Successful in 1m37s
07849d331a
Also moved check function to closepoll.ts
Author
Collaborator

closes #24
closes #36

closes #24 closes #36
magnetotail requested review from kenobi 2023-06-17 12:39:58 +02:00
kenobi reviewed 2023-06-17 12:47:06 +02:00
@ -148,0 +167,4 @@
const eventDate: Date = toDate(updatedEvent.scheduledStartTimestamp)
const closePollDate: Date = addDays(eventDate, -2)
if (isAfter(Date.now(), closePollDate)) {
Owner

This would also meant that it is not possible to start an impromptu poll for a Watchparty 'tonight'.
Maybe it's possible to also check if the post is older than 24 hours?

This would also meant that it is not possible to start an impromptu poll for a Watchparty 'tonight'. Maybe it's possible to also check if the post is older than 24 hours?
Author
Collaborator

I think this would better be solved by !noautoclose or something when making the !nextwp? Could be carried to the voting offen event or the message to parse for that?

I think this would better be solved by !noautoclose or something when making the !nextwp? Could be carried to the voting offen event or the message to parse for that?
Owner

This would increase 'friction' I feel.
An easy thing for users to forget to do and be surprised by how the bot acts.
I would propose that we could do both.
If the distance between poll post date and event date is less than 2 days it does not auto close, but the poll creation would need to be adjusted to contain guidance on how to close the poll manually for the creator of the event.
'Normal' poll posts would be made a week in advance to a watch party so the 2-day auto close would be fine.

This would increase 'friction' I feel. An easy thing for users to forget to do and be surprised by how the bot acts. I would propose that we could do both. If the distance between poll post date and event date is less than 2 days it does not auto close, but the poll creation would need to be adjusted to contain guidance on how to close the poll manually for the creator of the event. 'Normal' poll posts would be made a week in advance to a watch party so the 2-day auto close would be fine.
Author
Collaborator

Implemented check to see if less than or equal to two days between start and create date of event

Implemented check to see if less than or equal to two days between start and create date of event
kenobi marked this conversation as resolved
@ -170,2 +173,4 @@
task.stop()
}
private async startPollCloceBackgroundTasks() {
Owner

startPollCloseBackgroundTask

startPollClo**s**eBackgroundTask
Author
Collaborator

fixed

fixed
kenobi marked this conversation as resolved
magnetotail added 1 commit 2023-06-17 13:03:56 +02:00
prevent poll close if event is less than 24h old
All checks were successful
Build a docker image for node-jellyfin-role-bot / build-docker-image (push) Successful in 1m15s
4cc332820f
magnetotail added 1 commit 2023-06-17 13:19:41 +02:00
Check if less than 2 days between create and start for deciding if to close
All checks were successful
Build a docker image for node-jellyfin-role-bot / build-docker-image (push) Successful in 1m9s
670a64af22
Owner

looks good to me

looks good to me
kenobi added 1 commit 2023-06-19 11:19:20 +02:00
Merge branch 'master' into fix/movie_names_and_background_task
All checks were successful
Compile the repository / compile (push) Successful in 1m31s
59f5b34e5a
kenobi merged commit 6d5725be90 into master 2023-06-19 11:29:04 +02:00
Sign in to join this conversation.
No reviewers
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: kenobi/jellyfin-discord-bot#46
No description provided.