Skip to content
This repository was archived by the owner on Aug 20, 2025. It is now read-only.

Cache metadata all avoid caching draft#66

Merged
DanielElisenberg merged 3 commits intocache-metadata-allfrom
cache-metadata-all-avoid-caching-draft
Jun 3, 2025
Merged

Cache metadata all avoid caching draft#66
DanielElisenberg merged 3 commits intocache-metadata-allfrom
cache-metadata-all-avoid-caching-draft

Conversation

@DanielElisenberg
Copy link
Contributor

@DanielElisenberg DanielElisenberg commented Jun 3, 2025

  • Fix so we don't cache draft versions
  • Lru cache only works with hashable objects. Dataclass is not hashable if init is implemented or it is mutable. Made Version immutable and made a generate_from_string function to get around this so cache works. If we pass Version without these changes the app would crash

@DanielElisenberg DanielElisenberg requested a review from a team as a code owner June 3, 2025 13:34
@sonarqubecloud
Copy link

sonarqubecloud bot commented Jun 3, 2025

Copy link
Contributor

@haraldsvik haraldsvik left a comment

Choose a reason for hiding this comment

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

Lets test it!

@DanielElisenberg DanielElisenberg merged commit 84d607d into cache-metadata-all Jun 3, 2025
4 checks passed
@DanielElisenberg DanielElisenberg deleted the cache-metadata-all-avoid-caching-draft branch June 3, 2025 14:01
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants