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

Restart sync/set max time #51

Merged
merged 4 commits into from
Aug 28, 2024
Merged

Restart sync/set max time #51

merged 4 commits into from
Aug 28, 2024

Conversation

clockwinder
Copy link
Owner

Start sync removed from play command, moved to postCurrentlyListening via new function checkSyncThreadIsAlive()/ This checks the thread every refresh in case it ended for some reason.

generateProgressBar() now checks to make sure the song has not played longer than the maximum value of .length and replaces it with the max value if violated. Also reduces .seconds. variable time conversion by one instance.

@clockwinder clockwinder requested a review from adamdiel August 27, 2024 17:01
rainwavebot.py Outdated
traceback.print_exc()
#print(f"checkSyncThreadIsAlive error: {returnedException}") #NOTE Not required here, but I want to keep it noted as an example.
#traceback.print_exc() #NOTE Not required here, but I want to keep it noted as an example.
threadIsAlive = False
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure I'm understanding the intent of lines 55/56. I think they will always get run?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess what are we doing with threadIsAlive at all? Not sure we need to set a var at all?

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yup. :)

@clockwinder clockwinder merged commit 5c58d17 into main Aug 28, 2024
@clockwinder clockwinder deleted the restart-sync/set-max-time branch August 28, 2024 00:39
@clockwinder
Copy link
Owner Author

Closes #42 #49

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants