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

Fix diff not starting from last viewed snapshot (#2744) #2856

Merged
merged 2 commits into from
Dec 27, 2024

Conversation

MoshiMoshi0
Copy link
Contributor

Fixes #2744 so that get_from_version_based_on_last_viewed returns snapshot before last viewed date instead of after.

Comment on lines +56 to +59
watch.save_history_text(contents="hello world", timestamp=100, snapshot_id=str(uuid_builder.uuid4()))
p = watch.get_from_version_based_on_last_viewed
assert p == "100", "Correct with only one history snapshot"

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This could also return None

@dgtlmoon
Copy link
Owner

Hey super nice PR, thanks for this!

@dgtlmoon dgtlmoon merged commit 05f54f0 into dgtlmoon:master Dec 27, 2024
5 checks passed
@MoshiMoshi0 MoshiMoshi0 deleted the 2744-wrong-from-version branch January 7, 2025 14:24
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.

Watch history compare "from" date is not set to last viewed date
2 participants