Repository navigation
Conversation
- output_paths points to job.policy_error when a policy refused the call, and says when the output policy held the outputs back - a blocking api call prints why it ended (_print_call_result) - the api table has a Policies column - ApiResult shows the api's args and when set_policies cleared its state; print(result) shows the same text as repr - the job view shows code/params.json in a Parameters section Messages and displays only; no behaviour changes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This branch has not been deployed
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
Found while testing #9566 end to end in Colab: when a policy refuses or holds back a call, the evaluator gets messages that point to the wrong place, and the DO doesn't see an api's arguments or a job's parameters. This only changes messages and displays; no behaviour changes.
Changes
job.output_paths: a call refused by a policy prints the reason and points tojob.policy_error, not tojob.stderr(which the evaluator doesn't get). Other failures still point tojob.stderr.job.output_paths: a done job whose outputs the output policy held back says so, and that the data owner can still share them, instead of blaming the script._print_call_resulthelper.input, output,input,outputor-), and the text view shows the same.ApiResultlists the api's arguments and says whenset_policiescleared the state;print(result)now shows the same text asrepr(result).code/params.jsonin a Parameters section, pretty-printed and escaped.Testing
uv sync --all-packages,just test-unit-job(157 passed),just test-unit-rds(155 passed),uv run pytest tests/unit/syft_bg(174 passed) andpre-commit run --all-files(passes).syft-rds/tests/test_api_policies.py;tests/unit/syft_bg/test_api_result.pyfor the args and the cleared state; a Parameters test insyft-job/tests/test_policies.py. The new tests fail on dev.tests/integration/syft_bg/test_cli.pygives 24 passed and 2 failed; the 2 remove-peer failures happen the same way on dev without this change (the test sets up an api without run.sh), so I left them alone.Asana task
🤖 Generated with Claude Code