Skip to content

L1: SupportsIncrementalLoad protocol + LoadMarker/IncrementalChunk (cellpy-hosted) #779

Description

@jepegit

Epic L (live/incremental) of cellpy 2.2 (Stage 5). Design: live-incremental §3.

Add the optional loader capability in cellpy (not cellpycore — the contract is only between loaders and CellpyCell.update(); core's update_data never sees it):

  • @runtime_checkable class SupportsIncrementalLoad(Protocol): load_since(source, marker) -> IncrementalChunk
  • LoadMarker (last source_datapoint_num / byte_offset / row_count) and IncrementalChunk (new_raw, marker, complete)

Marker semantics match core update_data (new_raw may overlap the tail; overlap trimmed on source_datapoint_num). Loaders that can't do cheap partial reads simply don't implement it → update() falls back to full reload.

Metadata

Metadata

Assignees

No one assigned

    Labels

    cellpy2-stage5cellpy 2.2 (Stage 5): live/incremental, step/summary science, loaders/IO, remote/discoveryenhancementv2cellpy v2 work - PRs should target the master branch

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions