Build the dataset catalog record — datasets.json
Source: R/catalog_datasets.R
build_dataset_catalog.RdOne record per dataset_key (plan § D-1, Appendix A), joined from the
release sidecars, the registries and the measured endpoints:
Usage
build_dataset_catalog(
meta,
coverage,
catalog,
registries,
version = NULL,
erddap = NULL,
netcdf = NULL,
since = NULL,
source_accessed = NULL,
spatial_layers = NULL,
bathymetry = NULL,
workflows_base = "https://calcofi.io/workflows/",
release_prefix = "ducklake/releases",
stac_base = sprintf("https://storage.googleapis.com/calcofi-db/%s", if
(grepl("staging", release_prefix)) "stac-staging" else "stac")
)Arguments
- meta
the release
metadata.json(path or parsed list)- coverage
the release
coverage.json- catalog
the release
catalog.json- registries
- version
the release version (default: the catalog's)
- erddap
the table from
fetch_erddap_datasets()(NULL: no ERDDAP rows)- netcdf
the list from
fetch_netcdf_manifests()- since
a named character vector
dataset_key -> first version(dataset_since_versions())- source_accessed
a named character vector
dataset_key -> YYYY-MM-DD(the releasedatasettable's measured column)- spatial_layers
the release
spatial_layers.json(forreference[])- bathymetry
the
bathymetry/gebco_2025.jsonmanifest (forreference[])- workflows_base
the URL prefix of the rendered notebooks
- release_prefix
the bucket-relative releases prefix the run writes to
- stac_base
the STAC root this release writes (
release_database.qmdderives it from the prefix the same way); every public dataset gets aformat: stacdistribution under it (ducklake/releases, or the staging prefix) —release.urlfollows it
Value
A list ready for write_dataset_catalog() / jsonlite::write_json(auto_unbox = TRUE).
Details
identity, description, attribution, links and
tables[]from themetadata.jsondataset block, withproviderandcategoryexpanded from their registries and the descriptive sidecar'skeywords,creators[],fundingandvisibility;coveragerolled up fromcoverage.json:years[](the sparkline),n_stations,n_variables,n_taxa, the depth span,variables[],life_stages[](when the coverage carries them) andcontributes_to[](env-realm variables homed in another category);objects[]fromcatalog.json: the dataset'sdataset_key=partitions and the whole tables attributed to it, each withbytes,sha256,sinceand an absolute URL;since_versionfromsince;distributions[](dataset_distributions()): parquet, netCDF, the ERDDAP ids that exist now, the notebook, the calcofi.org page, the source and the curateddistribution.csvrows;registrations[]fromdataset_status.csv'spublish_*columns — with ERDDAP and OBIS measured (a served id / a curated OBIS row wins over the registry cell) and Zenodo from the release DOI;statusfromdataset_status.csvplus the open/proposed questions.
holdings[] are the sidecars with status: planned | external | archived
(a dataset without a release, § D-11), and reference[] the cruise, ship,
grid and spatial tables, the boundary layers and the bathymetry (Decision
20). Deterministic: no wall clock, sorted by key.