fix(examples): indonesia_compliance reads AXONFLOW_USER_TOKEN [skip-runtime-e2e]#215
Open
saurabhjain1592 wants to merge 1 commit into
Open
fix(examples): indonesia_compliance reads AXONFLOW_USER_TOKEN [skip-runtime-e2e]#215saurabhjain1592 wants to merge 1 commit into
saurabhjain1592 wants to merge 1 commit into
Conversation
…untime-e2e] The example hardcoded user_token="" — on enterprise stacks (DEPLOYMENT_MODE=enterprise) every governed call 401'd and the generic AxonFlowError catch printed the auth failure as 'expected if no LLM configured' with exit 0 (the swallowed-auth-error class from the #2861 sweep; this file was missed by #213's example fixes). It now reads AXONFLOW_USER_TOKEN like the other examples and re-raises AuthenticationError so a credentials problem fails loudly. Signed-off-by: Saurabh Jain <saurabh.jain@getaxonflow.com>
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
examples/indonesia_compliance.pyhardcodeduser_token=""— on enterprise stacks (DEPLOYMENT_MODE=enterprise) the governed NIK call 401'd and the genericAxonFlowErrorcatch printed the auth failure as "expected if no LLM configured" with exit 0. This is the swallowed-auth-error class from the #2861 sweep; this file was missed by #213's example fixes.Changes
examples/indonesia_compliance.py: readAXONFLOW_USER_TOKEN(matches every other example post-fix: interceptor sync bridge + async detection, example fixes #213); re-raiseAuthenticationErrorso a credentials problem fails loudly instead of masquerading as a missing-LLM situation.Testing (live enterprise stack, axonflow-enterprise main @ 5222c70f0, local editable SDK 8.5.1)
Response blocked: False), audit-search + PII-Indonesia policy list legs green.AuthenticationError: Invalid credentials, exit 1 (previously exit 0 with a success-shaped message).Skip-runtime-e2e justification
One-hunk example-script fix (env-var read + loud auth failure); no library surface changed. The governed-call path this example exercises is already covered by the repo's runtime-e2e suite; the fix itself was verified end-to-end against a live enterprise stack in both directions (evidence above). Adding a dedicated runtime-e2e harness for a demo script would duplicate existing coverage.
Refs getaxonflow/axonflow-enterprise#2861.