Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 13 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,19 @@

All notable changes to this project will be documented in this file.

## [Unreleased]

### Removed

- Legacy config forms below no longer emit deprecation warnings and now fail with explicit config errors:
- `raw.source`
- `raw.sources[].plugin`
- `raw.sources[].id`
- scalar `clean.read`
- `clean.read.csv.*`
- `clean.sql_path`
- `mart.sql_dir`

## [1.0.0] - 2026-02-28

### Added
Expand Down Expand Up @@ -41,6 +54,4 @@ All notable changes to this project will be documented in this file.
- `raw.sources[].id` in favor of `raw.sources[].name`
- scalar `clean.read` in favor of `clean.read.source`
- `clean.read.csv.*` in favor of `clean.read.*`
- `clean.sql_path`
- `mart.sql_dir`
- `bq`
2 changes: 0 additions & 2 deletions docs/advanced-workflows.md
Original file line number Diff line number Diff line change
Expand Up @@ -95,8 +95,6 @@ Regola pratica:

## Compat legacy

Il toolkit mantiene compatibilita` con alcune forme legacy del config per facilitare la migrazione.

Per i repo nuovi:

- usa la shape canonica documentata in [config-schema.md](./config-schema.md)
Expand Down
23 changes: 15 additions & 8 deletions docs/config-schema.md
Original file line number Diff line number Diff line change
Expand Up @@ -222,16 +222,23 @@ Con `config.strict: true` o `--strict-config`, gli stessi casi diventano errori.

| Code | Legacy | Replacement | Status |
|---|---|---|---|
| `DCL001` | `raw.source` | `raw.sources` | deprecated |
| `DCL002` | `raw.sources[].plugin` | `raw.sources[].type` | deprecated |
| `DCL003` | `raw.sources[].id` | `raw.sources[].name` | deprecated |
| `DCL004` | `clean.read: "auto"` | `clean.read.source: auto` | deprecated |
| `DCL005` | `clean.read.csv.*` | `clean.read.*` | deprecated |
| `DCL006` | `clean.sql_path` | `clean.sql` | ignored |
| `DCL007` | `mart.sql_dir` | `mart.tables[].sql` | ignored |
| `DCL008` | `bq` | rimuovere il campo | ignored |
| `DCL013` | `cross_year.* unknown keys` | rimuovere il campo | ignored |

## Legacy rimosso

Le forme seguenti non sono piu supportate. Non generano warning legacy: falliscono subito con errore di config e va usata la shape canonica.

| Legacy rimosso | Usa invece |
|---|---|
| `raw.source` | `raw.sources` |
| `raw.sources[].plugin` | `raw.sources[].type` |
| `raw.sources[].id` | `raw.sources[].name` |
| `clean.read: "auto"` | `clean.read.source: auto` |
| `clean.read.csv.*` | `clean.read.*` |
| `clean.sql_path` | `clean.sql` |
| `mart.sql_dir` | `mart.tables[].sql` |

## Esempi minimi

### RAW only
Expand Down Expand Up @@ -312,7 +319,7 @@ Esempi tipici:
- `Config validation failed: output.unknown_flag: Extra inputs are not permitted`
- `Config validation failed: raw.sources: Input should be a valid list`
- `Config validation failed: clean.validate.primary_key: clean.validate.primary_key must be a string or a list of strings`
- `DCL001 raw.source is deprecated, usare raw.sources`
- `Config validation failed: raw.sources: Input should be a valid list`

Regola pratica:

Expand Down
18 changes: 8 additions & 10 deletions tests/test_clean_csv_columns.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,16 +33,14 @@ def test_run_clean_csv_columns_reads_trailing_delimiter_csv(tmp_path: Path):
"sql": str(sql_path),
"read": {
"mode": "latest",
"csv": {
"delim": ";",
"header": True,
"ignore_errors": True,
"null_padding": True,
"trim_whitespace": True,
"columns": {
"a": "VARCHAR",
"b": "VARCHAR",
},
"delim": ";",
"header": True,
"ignore_errors": True,
"null_padding": True,
"trim_whitespace": True,
"columns": {
"a": "VARCHAR",
"b": "VARCHAR",
},
},
},
Expand Down
2 changes: 1 addition & 1 deletion tests/test_clean_duckdb_read.py
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,7 @@ def test_resolve_clean_read_cfg_config_only_ignores_suggested(tmp_path: Path):

_, relation_cfg, params_source = duckdb_read.resolve_clean_read_cfg(
raw_dir,
{"read": "config_only"},
{"read": {"source": "config_only"}},
logging.getLogger("tests.clean.duckdb_read.config_only"),
)

Expand Down
Loading