Skip to content

Add observability scaffolding and telemetry propagation to the simulation gateway#437

Merged
anth-volk merged 6 commits intomainfrom
pr/observability-contracts-and-telemetry-v2
Apr 13, 2026
Merged

Add observability scaffolding and telemetry propagation to the simulation gateway#437
anth-volk merged 6 commits intomainfrom
pr/observability-contracts-and-telemetry-v2

Conversation

@anth-volk
Copy link
Copy Markdown
Contributor

Fixes #436

Summary

  • add the shared observability scaffolding, contracts, and no-op provider surface in policyengine-fastapi
  • expose the initial observability settings in the simulation API project without enabling runtime emission yet
  • accept, normalize, and forward the internal _telemetry envelope through the Modal gateway and into the worker
  • strip _telemetry before SimulationOptions validation while preserving correlated worker logging and tests

Validation

  • uv run ruff check projects/policyengine-api-simulation/src/modal/gateway/models.py projects/policyengine-api-simulation/src/modal/gateway/endpoints.py projects/policyengine-api-simulation/src/modal/gateway/generate_openapi.py projects/policyengine-api-simulation/src/modal/simulation.py projects/policyengine-api-simulation/src/modal/telemetry.py projects/policyengine-api-simulation/tests/gateway/test_models.py projects/policyengine-api-simulation/tests/gateway/test_endpoints.py projects/policyengine-api-simulation/tests/test_modal_telemetry.py
  • cd projects/policyengine-api-simulation && uv run pytest tests/test_modal_telemetry.py tests/gateway/test_models.py tests/gateway/test_endpoints.py

@anth-volk anth-volk marked this pull request as ready for review April 13, 2026 20:54
@anth-volk anth-volk merged commit 198bb99 into main Apr 13, 2026
4 checks passed
@anth-volk anth-volk deleted the pr/observability-contracts-and-telemetry-v2 branch April 13, 2026 20:54
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.

Add observability scaffolding and telemetry propagation for the simulation gateway

1 participant