feat(contracts): espandi API pubblica — CLEAN_PARQUET_SUFFIX, resolve_root, __all__#293
Open
Gabrymi93 wants to merge 1 commit into
Open
feat(contracts): espandi API pubblica — CLEAN_PARQUET_SUFFIX, resolve_root, __all__#293Gabrymi93 wants to merge 1 commit into
Gabrymi93 wants to merge 1 commit into
Conversation
…lve_root
Aggiunto:
- CLEAN_PARQUET_SUFFIX costante pubblica ('_clean.parquet')
- resolve_root esportato pubblicamente (utile per consumer)
- clean_parquet_path ora usa CLEAN_PARQUET_SUFFIX internamente
- __all__ completo e verificato dal test
- Docstring con esempi concreti
Test: 3 test aggiunti (suffix, resolve_root, __all__ match)
CI: 758 test passano, Ruff OK, marker audit OK
Ref: #244
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Cosa
Espande
toolkit.contractscome API pubblica stabile per path contract, come richiesto in #244.Aggiunte
CLEAN_PARQUET_SUFFIX("_clean.parquet") — costante pubblica per filtrare/globbare file CLEAN. Sostituisce gli hardcode tipofile.endswith("_clean.parquet")sparsi in dataset-incubatorresolve_root— esportato pubblicamente (era importato come_resolve_rootprivato). Utile per consumer che devono risolvere la root directory__all__completo — verificato dal testtest_contracts_all_exports_match()per garantire che ogni nome in__all__sia effettivamente esportatoTest
__all__matchPerché
Consumer come dataset-incubator hardcodano ancora pattern di path (es.
"{slug}_{year}_clean.parquet","_clean.parquet"). Con queste costanti pubbliche possono importare datoolkit.contractsinvece di duplicare i contratti.Closes #244