Skip to content

dataset-names adopts the source toolkit (spec 004) #5

Closed

Description

@matbrgz

Follow-up of spec 004 (#4): dataset-names replaces its own copies of the generic source code with the benchcommons-tools-dataset package. The dataset-names side (spec, plan, code) is written in dataset-names; this issue tracks it from tools-dataset.

Contract to adopt: docs/specs/004-source-toolkit/spec.md in this repo, at tag v0.1.0.

  • Tag v0.1.0 of tools-dataset exists (created after spec 004 merges)

  • dataset-names spec for the adoption, linking to spec 004 here instead of redefining it

  • Dependency declared as in ADR 0004 of this repo ([tool.uv.sources] git source pinned to the tag)

  • src/namescommons/cache.py replaced by datasettool.sources.cache (User-Agent of dataset-names passed explicitly)

  • src/namescommons/spreadsheet.py replaced by datasettool.sources.spreadsheet

  • Generic part of src/namescommons/adapters/__init__.py replaced by datasettool.sources.adapters; RawRecord and RawLink stay in dataset-names; check_adapter called with optional=("links",)

  • src/namescommons/sources.py rebuilt on datasettool.sources.registry with its own fields (country, count_type, primary, suppression, uniform_case), its accepted licences (ADR 0001 and 0004 of dataset-names) and the one-primary check

  • src/namescommons/manifest.py uses datasettool.files for checksums and CSV row counts

  • Ported tests removed from dataset-names only after the equivalents pass here (list them before deleting)

  • Do not assert on the order of lines inside a multi-error registry message: the toolkit checks retrieved and adapter before the dataset fields (country, count_type, primary, suppression, uniform_case), while dataset-names checked them in between (plan 2.4 of spec 004); the set of messages is the same

  • The cache now refuses source ids outside [a-z0-9]+(-[a-z0-9]+)* and unsafe file names (ValueError), as dataset-names' registry already does

Done in BenchCommons/dataset-names#41 (spec 007, ADR 0013): every item above is implemented and verified there (identical outputs on the fixtures and on the full real cache). Follow-ups: #9 (the cache refuses symlinked entries, found during the adoption) and BenchCommons/dataset-names#40 (message language).

Activity

  1. matbrgz commented on Oct 12, 2026

    @matbrgz
    ContributorAuthor

    All checklist items are implemented in BenchCommons/dataset-names#41 (spec 007). Closing as instructed; reopen if that PR is not merged as is.

  2. matbrgz commented on Oct 12, 2026

    @matbrgz
    ContributorAuthor

    Reaberta até o merge de BenchCommons/dataset-names#41, que faz a adoção.

  3. matbrgz commented on Oct 12, 2026

    @matbrgz
    ContributorAuthor

    Adoção concluída em BenchCommons/dataset-names#41.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions