Repository navigation
feat(manifest): record the release the catalog resolved to as catalog_release - #65
Merged
Merged
Conversation
Documentation build overview
6 files changed ·
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #65 +/- ##
==========================================
+ Coverage 94.64% 94.67% +0.03%
==========================================
Files 22 22
Lines 2278 2291 +13
==========================================
+ Hits 2156 2169 +13
Misses 122 122 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary: A
manifest.jsonand a frozen cohort now record the dated catalog release that the data came from, including when the catalog was opened withCatalog()and noversion.catalog_versionkeeps its current meaning as the opt-in pin that later downloads check, so rerunning a download of the latest catalog into the same folder still works after a new release. sddb-lead chose this over reusingcatalog_version(option A).Changes:
Catalog.release:versionwhen set. For the defaultcatalog-latestURL, it's the date in the parquet'ssddb_generated_at, which matches the release tag for 2026-10-16, 2026-10-28 and 2026-11-01, and the 2026-11-01 file is byte-identical tocatalog-latest. For any other URL it's None.Source.releasecarries it to cohorts and, through a new optionalsourceargument, toDataset. SoCatalog().dataset(uid).to_sdata(elements=..., dest=...)records it too.Manifest.catalog_releaseis written bydownload(), by partial copies and byrefetch(). Old manifests read with None.sourcegetsrelease. For a cohort frozen fromcatalog-latestwith a recorded release,verify()checks the sha256 against that dated release, so a changed catalog file raisesCatalogChangedErroras it would for a pinned release. Before, it only warned because latest moves.version=alone never recorded the release, and onlypin_versions=Truedid.Checks:
pytest: 456 passed, 4 skipped. The new testtest_unpinned_download_records_the_release_without_pinningchecks that an unpinned download writescatalog_release, keepscatalog_versionnull, and doesn't raise when it's rerun after a new release.Catalog().releaseis "2026-11-01".download()both record it.release.verify()passes.Catalog(version="2026-10-28").releaseis "2026-10-28".ruff checkandruff formatare clean on the touched files.