feat(telemetry): warn at startup when required env vars are missing#224
Closed
jeanscherf wants to merge 1 commit into
Closed
feat(telemetry): warn at startup when required env vars are missing#224jeanscherf wants to merge 1 commit into
jeanscherf wants to merge 1 commit into
Conversation
ad1991d to
7f6b2ce
Compare
Emit logger.warning() when APPFND_CONHOS_SYSTEM_ROLE or ORD_DOCUMENT_ID are unset so developers get immediate feedback at runtime rather than silently producing malformed telemetry or incomplete metering data.
7f6b2ce to
7de5301
Compare
LucasAlvesSoares
approved these changes
Jul 14, 2026
gpretto
reviewed
Jul 14, 2026
| value = os.getenv(ENV_SYSTEM_ROLE) | ||
| if not value: | ||
| logger.warning( | ||
| "APPFND_CONHOS_SYSTEM_ROLE is not set. " |
There was a problem hiding this comment.
APPFND_CONHOS_SYSTEM_ROLE still the name? I thought, we suposed to remove the "conhos" from naming.
Should we add something like: "review app.yaml env object" or something like it?
Member
Author
|
Closing — system role will be injected automatically from the blueprint onboarding file in CI. SDK-level warnings are not needed. |
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.
Summary
_get_system_role(): emitslogger.warning()whenAPPFND_CONHOS_SYSTEM_ROLEis unset, instead of silently defaulting tounknown_get_ord_id(): emitslogger.warning()whenORD_DOCUMENT_IDis unset, instead of silently omittingsap.ord.idfrom the OTel resourcelogging.getLogger(__name__)convention used throughout the telemetry moduleTest plan
tests/core/unit/telemetry/test_config.pypass unchanged