Skip to content

feat(catalog): catalog-update-pr + catalog-reusable — CI per source catalog per-repo - #38

Merged
Gabrymi93 merged 2 commits into
mainfrom
feat/catalog-ci
Oct 13, 2026
Merged

Gabrymi93 merged 2 commits into
mainfrom
feat/catalog-ci

Conversation

@Gabrymi93

Copy link
Copy Markdown
Member

Sintesi

Due componenti org per il catalog engine decentralizzato (source-observatory#421): ogni repo dati può generare/aggiornare il proprio registry/catalog.json in CI con draft PR.

Contesto collegato

Decentralizzazione SO: engine per-repo con so-catalog, config [tool.observatory] nel pyproject. Questi componenti sbloccano l'adozione automatica sui repo con la config.

Cosa cambia

  • Nuovo actions/catalog-update-pr/ — composite: so-catalog → diff → draft PR
  • Nuovo workflows/catalog-reusable.yml — workflow_call con repo-slug, catalog-args, dry-run

Come funziona

repo catalog.yml (cron/dispatch)
  └─ catalog-reusable.yml (org)
       ├─ checkout + python-setup[dev,observatory]
       ├─ dry-run: so-catalog --dry-run (PR-check su pyproject)
       └─ full: catalog-update-pr → draft PR branch post-catalog/*
  • Zero secrets: niente GCS/WIF — il catalog è solo JSON in git
  • Nessun run pregresso: probe + inventario live, continuità streak dal catalog committato
  • Dry-run: su PR che toccano pyproject.toml, valida la build senza creare PR

Caller di esempio (non incluso — vive nei repo dati)

jobs:
  catalog:
    permissions:
      contents: write
      pull-requests: write
    uses: dataciviclab/.github/.github/workflows/catalog-reusable.yml@main
    with:
      repo-slug: eurostat
      catalog-args: "--workers 4"
      dry-run: ${{ github.event_name == 'pull_request' }}

Verifica

  • actionlint verde
  • Coerente con gli entry point attuali di SO (so-catalog)

…atalog per-repo

Componenti org per il catalog engine decentralizzato (source-observatory#421):

- actions/catalog-update-pr: composite che gira so-catalog nello stesso
  job (stessa versione engine, come registry-update-pr), fa diff su
  registry/ e apre draft PR branch post-catalog/* con label e sintesi
  verdict nel body. Zero secrets GCS: il catalog e' solo JSON in git.
- workflows/catalog-reusable.yml: workflow_call con repo-slug,
  catalog-args e dry-run (per PR-check quando cambia [tool.observatory]).
  A differenza di pipeline-reusable non ha bisegno di run pregresso ne
  WIF: probe + inventario live, continuita' streak dal catalog committato.

Caller di esempio (eurostat) non incluso — vive nel repo dati.
Review findings su PR #38:
- catalog-reusable.yml spostato da workflows/ (root) a .github/workflows/
  — path coerente con pipeline-reusable e gli altri; il body dichiarava
  .github/workflows/ ma il file era al root
- BODY con $'...' invece di "...\n..." — i newline erano letterali
  nel body della PR draft
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant