pyvider-cty 2025-11-23
Pristine release with Diataxis documentation, import modernization, and test expansion
322 files · 23,777+ · 7,129-

Import Modernization

2 files changed
  • __init__.py Converted all relative imports to absolute imports across the entire src/pyvider/cty/ package
  • codec.py Converted all relative imports to absolute imports across the entire src/pyvider/cty/ package
  • Converted all relative imports (from .types import ...) to absolute imports (from pyvider.cty.types import ...) across the entire src/pyvider/cty/ package instantiate internal
    59 files
    • README.md
    • __init__.py
    • _version.py
    • codec.py
    • __init__.py
    • defaults.py
    • runtime.py
    • __init__.py
    • validation_context.py
    • __init__.py
    • _cache.py
    • _utils.py
    • adapter.py
    • explicit.py
    • inference_cache.py
    • raw_to_cty.py
    • type_encoder.py
    • __init__.py
    • base.py
    • conversion.py
    • encoding.py
    • validation.py
    • __init__.py
    • bytes_functions.py
    • collection_functions.py
    • comparison_functions.py
    • conversion_functions.py
    • datetime_functions.py
    • encoding_functions.py
    • numeric_functions.py
    • string_functions.py
    • structural_functions.py
    • marks.py
    • parser.py
    • __init__.py
    • base.py
    • py.typed
    • __init__.py
    • base.py
    • capsule.py
    • capsule_types.py
    • __init__.py
    • list.py
    • map.py
    • set.py
    • __init__.py
    • bool.py
    • number.py
    • string.py
    • __init__.py
    • dynamic.py
    • object.py
    • tuple.py
    • validation.py
    • __init__.py
    • recursion.py
    • __init__.py
    • base.py
    • markers.py
  • Added from __future__ import annotations to all source modules for forward-reference support specify internal
    5 files
    • __init__.py
    • codec.py
    • base.py
    • base.py
    • __init__.py

SPDX License Headers

2 files changed
  • __init__.py Added SPDX license headers to all source and test files
  • codec.py Added SPDX license headers to all source and test files
  • Added standardized SPDX-FileCopyrightText and SPDX-License-Identifier: Apache-2.0 headers to all source and test files, replacing ad-hoc comment headers qualify internal
    5 files
    • __init__.py
    • codec.py
    • base.py
    • base.py
    • __init__.py

Dependency Migration

2 files changed
  • pyproject.toml Replaced pyvider-telemetry with provide-foundation; consolidated dev deps into provide-testkit
  • codec.py Integrated provide.foundation.errors.error_boundary for error handling
  • Replaced pyvider-telemetry dependency with provide-foundation baseline behavioral
    2 files
    • pyproject.toml
    • uv.lock
  • Integrated provide.foundation.errors.error_boundary for error handling in codec remediate internal
    1 file
    • codec.py
  • Adopted provide.foundation.utils.get_version for dynamic version resolution baseline internal
    2 files
    • _version.py
    • pyproject.toml
  • Dev dependencies consolidated into provide-testkit[standard,advanced-testing,typecheck,build] qualify internal
    1 file
    • pyproject.toml

Configuration Centralization (`config/defaults.py`)

2 files changed
  • defaults.py Modified
  • runtime.py Modified
  • New config/ package with defaults.py (357 lines) centralizing all magic numbers, error message templates, and protocol constants instantiate behavioral
    1 file
    • defaults.py
  • runtime.py added for runtime configuration management instantiate internal
    1 file
    • runtime.py
  • Codec module refactored to use named constants (MSGPACK_EXT_TYPE_CTY, REFINEMENT_STRING_PREFIX, etc.) instead of inline magic numbers decouple internal
    2 files
    • defaults.py
    • runtime.py

Codec Refactoring

1 file changed
  • codec.py Extracted helper functions, replaced if/elif with match/case, modernized annotations
  • Extracted helper functions: _decode_number_value(), _extract_refinements_from_payload(), _decode_refined_unknown_payload() decouple internal
    1 file
    • codec.py
  • Replaced nested if/elif chain with match/case statement in _ext_hook() decouple internal
    1 file
    • codec.py
  • Extracted _serialize_object_value(), _serialize_map_value() from monolithic serialization function decouple internal
    1 file
    • codec.py
  • Changed string-quoted type annotations to use from __future__ import annotations specify internal
    1 file
    • codec.py

Build Configuration

1 file changed
  • VERSION Modified

Documentation Overhaul

7 files changed
  • CHANGELOG.md Modified
  • CONTRIBUTING.md Modified
  • README.md Modified
  • ch18_go_cty_comparison.md Modified
  • ch01_welcome.md Modified
  • mkdocs.yml Modified
  • README.md Modified
  • Added mkdocs.yml (170 lines) for MkDocs Material documentation site instantiate internal
    1 file
    • mkdocs.yml
  • Restructured docs into Diataxis categories: getting-started, user-guide, how-to, reference, API specify architectural
    7 files
    • CHANGELOG.md
    • CONTRIBUTING.md
    • README.md
    • ch18_go_cty_comparison.md
    • ch01_welcome.md
    • mkdocs.yml
    • README.md
  • Removed old sequential chapter-based guide (docs/guide/ch01_welcome.md through ch18_go_cty_comparison.md) specify internal
    2 files
    • ch18_go_cty_comparison.md
    • ch01_welcome.md
  • Added comprehensive how-to guides: custom types, migration from go-cty, serialization, validation, Terraform interop instantiate internal
    7 files
    • CHANGELOG.md
    • CONTRIBUTING.md
    • README.md
    • ch18_go_cty_comparison.md
    • ch01_welcome.md
    • mkdocs.yml
    • README.md
  • Added reference docs: configuration, glossary, go-cty comparison, troubleshooting (756 lines), release notes specify internal
    7 files
    • CHANGELOG.md
    • CONTRIBUTING.md
    • README.md
    • ch18_go_cty_comparison.md
    • ch01_welcome.md
    • mkdocs.yml
    • README.md
  • Removed old benchmark files from docs/benchmarks/ deprecate internal
    5 files
    • benchmark-20250725-1329-after.txt
    • benchmark-20250725-1329-before.txt
    • benchmark-20250725-1336-after.txt
    • benchmark-20250725-1336-before.txt
    • benchmark-20250725-1421-before.txt
  • Removed src/pyvider/cty/README.md (151-line informal README) specify internal
    2 files
    • README.md
    • README.md
  • Added CHANGELOG.md (118 lines) and CONTRIBUTING.md (287 lines) specify internal
    2 files
    • CHANGELOG.md
    • CONTRIBUTING.md

Examples Restructuring

7 files changed
  • ch02_getting_started.py Modified
  • ch09_capsule_types.py Modified
  • functions.py Modified
  • marks.py Modified
  • quick-start.py Modified
  • serialization.py Modified
  • terraform-interop.py Modified
  • Reorganized examples from flat chapter-based files (ch02_getting_started.py, ch09_capsule_types.py, etc.) into categorized directories: getting-started/, types/, advanced/ decouple internal
    2 files
    • ch02_getting_started.py
    • ch09_capsule_types.py
  • Added new examples: quick-start.py, functions.py, marks.py, serialization.py, terraform-interop.py instantiate internal
    5 files
    • functions.py
    • marks.py
    • quick-start.py
    • serialization.py
    • terraform-interop.py

Test Suite Expansion

25 files changed
  • test_adversarial_fuzzing.py Modified
  • test_capsule_edge_cases.py Modified
  • test_codec_fuzzing.py Modified
  • test_collection_creation_functions.py Modified
  • test_collection_query_functions.py Modified
  • test_collection_transform_functions.py Modified
  • test_comparison_functions.py Modified
  • test_error_context_integration.py Modified
  • test_exception_coverage.py Modified
  • test_extreme_scale.py Modified
  • test_go_cty_compat.py Modified
  • test_map_validation.py Modified
  • test_marks_properties.py Modified
  • test_memory_pressure.py Modified
  • test_numeric_attacks.py Modified
  • test_numeric_functions.py Modified
  • test_object_unknown_fields.py Modified
  • test_spec_compliance.py Modified
  • test_special_value_attacks.py Modified
  • test_stdlib_parity.py Modified
  • test_string_advanced_functions.py Modified
  • test_string_basic_functions.py Modified
  • test_tofusoup_compat.py Modified
  • test_unification_properties.py Modified
  • test_value_edge_cases.py Modified
  • Added property-based tests: test_adversarial_fuzzing.py, test_codec_fuzzing.py, test_exception_coverage.py, test_extreme_scale.py, test_marks_properties.py, test_memory_pressure.py, test_numeric_attacks.py, test_spec_compliance.py, test_special_value_attacks.py, test_unification_properties.py qualify internal
    10 files
    • test_adversarial_fuzzing.py
    • test_codec_fuzzing.py
    • test_exception_coverage.py
    • test_extreme_scale.py
    • test_marks_properties.py
    • test_memory_pressure.py
    • test_numeric_attacks.py
    • test_spec_compliance.py
    • test_special_value_attacks.py
    • test_unification_properties.py
  • Split test_stdlib_parity.py (920 lines removed) into focused files: test_collection_creation_functions.py, test_collection_query_functions.py, test_collection_transform_functions.py, test_string_basic_functions.py, test_string_advanced_functions.py, test_numeric_functions.py, test_comparison_functions.py, and per-domain stdlib test files qualify internal
    8 files
    • test_collection_creation_functions.py
    • test_collection_query_functions.py
    • test_collection_transform_functions.py
    • test_comparison_functions.py
    • test_numeric_functions.py
    • test_stdlib_parity.py
    • test_string_advanced_functions.py
    • test_string_basic_functions.py
  • Added test_object_unknown_fields.py (151 lines), test_capsule_edge_cases.py (300 lines), test_map_validation.py (259 lines), test_value_edge_cases.py (233 lines), test_error_context_integration.py (263 lines) instantiate internal
    5 files
    • test_capsule_edge_cases.py
    • test_error_context_integration.py
    • test_map_validation.py
    • test_object_unknown_fields.py
    • test_value_edge_cases.py
  • Replaced go-cty compatibility tests with TofuSoup compatibility tests qualify internal
    25 files
    • test_adversarial_fuzzing.py
    • test_capsule_edge_cases.py
    • test_codec_fuzzing.py
    • test_collection_creation_functions.py
    • test_collection_query_functions.py
    • test_collection_transform_functions.py
    • test_comparison_functions.py
    • test_error_context_integration.py
    • test_exception_coverage.py
    • test_extreme_scale.py
    • test_go_cty_compat.py
    • test_map_validation.py
    • test_marks_properties.py
    • test_memory_pressure.py
    • test_numeric_attacks.py
    • test_numeric_functions.py
    • test_object_unknown_fields.py
    • test_spec_compliance.py
    • test_special_value_attacks.py
    • test_stdlib_parity.py
    • test_string_advanced_functions.py
    • test_string_basic_functions.py
    • test_tofusoup_compat.py
    • test_unification_properties.py
    • test_value_edge_cases.py
  • Added test_tofusoup_compat.py replacing test_go_cty_compat.py instantiate internal
    2 files
    • test_go_cty_compat.py
    • test_tofusoup_compat.py

Go Compatibility Removal

2 files changed
  • test_tofusoup_compat.py Changed
  • test_go_cty_compat.py Changed
  • Removed compatibility/go/ directory (Makefile, go.mod, go.sum, main.go - 569 lines) baseline internal
    4 files
    • Makefile
    • go.mod
    • go.sum
    • main.go
  • Updated Python compatibility generator decouple internal
    1 file
    • generator.py

Infrastructure

5 files changed
  • coverage.json Modified
  • env.sh Modified
  • run-coverage.sh Modified
  • py.typed Modified
  • wrknv.toml Modified
  • Removed env.sh (221 lines) environment script baseline internal
    1 file
    • env.sh
  • Added wrknv.toml (18 lines) workspace configuration baseline internal
    1 file
    • wrknv.toml
  • Added run-coverage.sh (36 lines) coverage script qualify internal
    1 file
    • run-coverage.sh
  • Added coverage.json for coverage tracking qualify internal
    1 file
    • coverage.json
  • Added py.typed marker for PEP 561 typed package support baseline internal
    1 file
    • py.typed
  • Added slow pytest marker for extreme scale tests qualify internal
    1 file
    • conftest.py

Source Module Updates

4 files changed
  • _cache.py Modified
  • inference_cache.py Modified
  • object.py Modified
  • base.py Modified
  • conversion/inference_cache.py: New file (111 lines) replacing old _cache.py (66 lines removed), with improved LRU cache and thread safety streamline internal
    2 files
    • _cache.py
    • inference_cache.py
  • exceptions/: Expanded all exception modules (base, conversion, encoding, validation) with richer error context and provide-foundation integration baseline internal
    8 files
    • __init__.py
    • base.py
    • conversion.py
    • encoding.py
    • validation.py
    • test_conversion_exceptions.py
    • test_encoding_exceptions.py
    • test_validation_exceptions.py
  • functions/: Enhanced collection_functions (+459 lines), numeric_functions (+514 lines), comparison_functions (+178 lines), string_functions (+181 lines) with additional operations and refined unknown handling decouple internal
    39 files
    • functions.md
    • ch11_functions.md
    • functions.md
    • functions.py
    • ch11_functions.py
    • __init__.py
    • bytes_functions.py
    • collection_functions.py
    • comparison_functions.py
    • conversion_functions.py
    • datetime_functions.py
    • encoding_functions.py
    • numeric_functions.py
    • string_functions.py
    • structural_functions.py
    • __init__.py
    • test_bytes_stdlib_functions.py
    • test_collection_creation_functions.py
    • test_collection_functions.py
    • test_collection_functions_extra.py
    • test_collection_query_functions.py
    • test_collection_stdlib_functions.py
    • test_collection_transform_functions.py
    • test_comparison_coverage_tdd.py
    • test_comparison_functions.py
    • test_comparison_refined_unknowns.py
    • test_conversion_functions.py
    • test_datetime_stdlib_functions.py
    • test_encoding_functions_coverage.py
    • test_encoding_stdlib_functions.py
    • test_numeric_functions.py
    • test_numeric_refined_unknowns.py
    • test_refined_unknowns_coverage_tdd.py
    • test_refined_unknowns_integration.py
    • test_refined_unknowns_propagation_tdd.py
    • test_stdlib_parity.py
    • test_string_advanced_functions.py
    • test_string_basic_functions.py
    • test_structural_stdlib_functions.py
  • types/structural/object.py: Major expansion (+170 lines) for optional attributes and unknown field handling decouple internal
    1 file
    • object.py
  • values/base.py: Expanded (+135 lines) with additional value operations and mark handling decouple internal
    1 file
    • base.py