phenotypic.sdk_.store_publication_token#

phenotypic.sdk_.store_publication_token(store: Path, *, root_dir_fd: int | None = None) str | None[source]#

Return the root-last token for a PhenoTypic-published store.

PhenoTypic promotes an immutable store by replacing zarr.json last. Its root bytes and file identity therefore identify the complete generation without touching every chunk on GPFS. Inode and ctime close the gap where a byte-identical replacement preserves the old mtime. A generic third-party store has no such publication contract and returns None so the caller uses the conservative recursive snapshot fallback.

Parameters:
  • store (Path) – Published store path. Used for ordinary path-based inspection.

  • root_dir_fd (int | None) – Optional held descriptor for the store root. When given, zarr.json is opened relative to that identity with O_NOFOLLOW so a route can keep validation and serving bound to one directory generation.

Returns:

The publication token, or None when the protocol is not declared.

Return type:

str | None