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

WIP: Major refactor #57

Merged
merged 39 commits into from
Oct 6, 2024
Merged

WIP: Major refactor #57

merged 39 commits into from
Oct 6, 2024

Conversation

mielverkerken
Copy link
Member

No description provided.

Copy link
Collaborator

@matissecallewaert matissecallewaert left a comment

Choose a reason for hiding this comment

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

Looks good already! The only thing is testing this I assume?

fn update_active_idle_time(&mut self, timestamp: &DateTime<Utc>, threshold: f64) {
if timestamp.signed_duration_since(self.end_active).num_microseconds().unwrap() as f64 > threshold {
let duration = self.end_active.signed_duration_since(self.start_active);
if !duration.is_zero() {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Don't know if this would ever occur, but what if the duration is smaller then zero?

Copy link
Member Author

Choose a reason for hiding this comment

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

signed_duration_since: Subtracts another DateTime from the current date and time. This does not overflow or underflow at all.

I expect no problems

matissecallewaert and others added 25 commits October 2, 2024 10:29
Instead of the git repo to pull the latest version from, I changed it to an actual version. This gives us more control over the versioning as I experienced problems on different machines. This makes also sure that we don't suddenly have a broken program when Aya creates a release with breaking changes
@mielverkerken mielverkerken marked this pull request as ready for review October 6, 2024 19:42
Copy link
Collaborator

@matissecallewaert matissecallewaert left a comment

Choose a reason for hiding this comment

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

Lets rock and roll 🚀

@mielverkerken mielverkerken merged commit 0798f7b into main Oct 6, 2024
3 checks passed
@mielverkerken mielverkerken deleted the major-refactor branch October 6, 2024 20:33
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