Skip to content

Release 1.0: remove compatibility shims#387

Open
benjello wants to merge 13 commits intomasterfrom
release/1.0
Open

Release 1.0: remove compatibility shims#387
benjello wants to merge 13 commits intomasterfrom
release/1.0

Conversation

@benjello
Copy link
Copy Markdown
Member

@benjello benjello commented Mar 2, 2026

Summary

Draft PR for version 1.0 of OpenFisca Survey Manager. This branch removes the legacy compatibility shims (re-exports and DeprecationWarning wrappers) and applies the canonical import paths described in docs/MIGRATION_IMPORTS.md.

Dependencies / merge order

⚠️ This PR must be merged after the other refactor branches/PRs on the same path are merged:

  • The refactor/typing-core-io branch (and its PR) must be merged first.
  • The intermediate refactor/migration-phase2 branch/PR (io/core/processing refactors, logging, etc.) must also be merged before this one.

Until those branches are merged, this PR should stay in draft.

Notes

  • Intended as the 1.0 breaking-change step: removes re-export modules and finalizes the new module layout.
  • See docs/REFACTORING_PLAN.md and docs/MIGRATION_IMPORTS.md for the detailed migration path and mapping of old imports to new ones.

@benjello benjello force-pushed the release/1.0 branch 2 times, most recently from 0decf4a to fc62a0e Compare March 3, 2026 10:32
@benjello benjello force-pushed the refactor/migration-phase2 branch 2 times, most recently from 3e62b96 to 348c665 Compare March 3, 2026 15:04
Base automatically changed from refactor/migration-phase2 to master March 13, 2026 13:44
…gration doc (v6.4.0)

- io/hdf: extract write_table_to_hdf5 to io.hdf, writers re-exports
- processing/harmonization: harmonize_data_frame_columns, used in Survey.get_values
- core: add core.table, core.survey, core.dataset; tables/surveys/survey_collections re-export
- logging: add to configuration.models, google_colab, statshelpers; fix typo in core.table
- docs: MIGRATION_IMPORTS.md (import mapping when re-exports removed), REFACTORING_PLAN §3.4
- CHANGELOG + bump to 6.4.0

Made-with: Cursor
- Suppression de la fonction dans common.misc
- Retrait des exports dans common et utils
- Mise à jour MIGRATION_IMPORTS et REFACTORING_PLAN

Made-with: Cursor
…atshelpers/variables to policy

- input_dataframe_generator: moved to tests/ (used only by tests)
- coicop, matching, statshelpers, variables: moved to policy/
- update all imports accordingly
- coicop: paths -> configuration.paths

Made-with: Cursor
…precationWarnings

- calmar, calibration: processing/weights -> policy/
- processing/weights: re-export from policy + DeprecationWarning
- processing/__init__: lazy import for weights (avoid circular import)
- placeholders at root: coicop, input_dataframe_generator, matching,
  statshelpers, variables (with DeprecationWarnings)
- calmar, calibration placeholders: add DeprecationWarnings

Made-with: Cursor
…Warning

- scenarios/ -> policy/scenarios/ (abstract_scenario, reform_scenario)
- Placeholders at openfisca_survey_manager/scenarios/ with DeprecationWarning
- Remove common, processing/weights, root placeholders (coicop, matching, etc.)
- Update all imports to policy.scenarios
- Add missing Survey import in abstract_scenario

Made-with: Cursor
- Suppression des modules de compatibilité (config, paths, tables, surveys,
  survey_collections, read_sas, read_spss, read_dbf, calibration, calmar, utils)
- load_table déplacé dans core.dataset, imports migrés selon MIGRATION_IMPORTS.md
- Version 1.0.0, CHANGELOG et doc (REFACTORING_PLAN, RFC-001)

Made-with: Cursor
- Delete root simulations/simulation_builder/aggregates/utils modules in favor of policy.*
- Keep common.* as thin aliases to policy.legislation_asof (no DeprecationWarning)
- Update scenarios and tests to import from policy and core.dataset/core.survey
- Wire policy.simulations to SurveyCollection/load_table from core.dataset; tests still all pass

Made-with: Cursor
- policy/simulations: log.warn -> log.warning (3), groupby(..., observed=False)
- io/hdf: hdf5_safe_key() for PyTables NaturalNameWarning; to_hdf key= keyword
- core/survey: use hdf5_safe_key when reading HDF5, backward compat fallback
- tests: fix PytestReturnNotNoneWarning (assert instead of return)

Made-with: Cursor
@benjello benjello marked this pull request as ready for review March 20, 2026 21:05
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