Skip to content

feat: SDMX source plugin v1#74

Merged
Gabrymi93 merged 8 commits intomainfrom
feat/sdmx-source-v1
Mar 31, 2026
Merged

feat: SDMX source plugin v1#74
Gabrymi93 merged 8 commits intomainfrom
feat/sdmx-source-v1

Conversation

@Gabrymi93
Copy link
Copy Markdown
Member

@Gabrymi93 Gabrymi93 commented Mar 29, 2026

Cosa fa

Aggiunge il source type sdmx per acquisire dati ISTAT (e altri provider SDMX) direttamente in CSV normalizzato.

Perimetro v1

  • version obbligatoria e strict: il plugin verifica che la versione richiesta corrisponda a quella esposta dal dataflow live; nessun fallback silenzioso a latest
  • filters su dimensioni di serie (non TIME_PERIOD)
  • output RAW in CSV normalizzato con colonne DIM, DIM_label, value
  • agency opzionale, default IT1

Componenti

  • toolkit/plugins/sdmx.pySdmxSource con fetch(agency, flow, version, filters)
  • toolkit/core/registry.py — entry sdmx nei built-in plugin
  • toolkit/raw/run.py — integrazione _fetch_payload e _infer_ext (.csv fisso per sdmx)
  • tests/test_sdmx_plugin.py — CSV normalizzato, version mismatch, filter dimension sconosciuta
  • docs/config-schema.md — esempio e note pratiche per sdmx
  • smoke/istat_sdmx_22_289/ — smoke reale su 22_289 (popolazione residente ISTAT)

Verifiche

  • 81 test passati (mirati + regressione larga)
  • smoke raw, clean, mart su 22_289: ok

Caveat noto

WinError 5 su run all su Windows è preesistente e non specifico di questo branch.

Note

Il retry loop usa range(max(1, self.retries)): con retries=2 fa 2 tentativi, coerente con CkanSource. Da tenere a mente per chi si aspetta retries+1 tentativi.

Nota

Questo connettore e' complementare a ondata/istat_mcp_server di @aborruso: il suo MCP serve all'esplorazione interattiva dei dataflow ISTAT, questo plugin serve all'ingestion automatica in pipeline. I due layer si parlano bene - chi usa il suo MCP per trovare il dataflow giusto e i filtri corretti puo' poi usare questo connettore per scaricare i dati in modo riproducibile.

Closes #71

Co-Authored-By: Claude Sonnet 4.6 noreply@anthropic.com

@Gabrymi93
Copy link
Copy Markdown
Member Author

@codex review

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 0a402c10a2

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@Gabrymi93 Gabrymi93 merged commit cebdbc5 into main Mar 31, 2026
5 checks passed
@Gabrymi93 Gabrymi93 deleted the feat/sdmx-source-v1 branch March 31, 2026 14:51
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.

feat: add SDMX source v1 for stable sliced ingestion

1 participant