feat(providers): support profile updates#1914
Conversation
|
🌿 Preview your docs: https://nvidia-preview-pr-1914.docs.buildwithfern.com/openshell |
PR Review StatusValidation: Project-valid. PR #1914 implements approved provider profile update work from #1881, is authored by a repo admin, is non-draft, and DCO/branch checks are passing. Review findings:
Docs: Fern docs were updated in existing provider pages; no navigation change is needed. Next state: |
Re-check After Author UpdateI re-evaluated latest head Disposition: partially resolved. Resolved items:
Remaining items:
Docs: Fern docs are updated in the existing provider pages; no navigation change appears needed. E2E: pending. This PR touches provider credential/policy behavior, so Next state: |
Re-check After Author UpdateI re-evaluated latest head Disposition: partially resolved. Resolved items:
Remaining items:
Docs: Fern docs are updated in the existing provider pages; no navigation change appears needed. E2E: still pending. This PR touches provider credential/policy behavior, so Next state: |
PR Review StatusValidation: Project-valid. PR #1914 implements the validated provider profile update work from #1881 and remains non-draft. Review findings:
Docs: Fern docs are updated in the existing provider pages; no navigation change appears needed. E2E: pending. This PR touches provider credential/policy behavior, so Next state: |
Signed-off-by: John Myers <9696606+johntmyers@users.noreply.github.com>
Signed-off-by: John Myers <9696606+johntmyers@users.noreply.github.com>
Signed-off-by: John Myers <9696606+johntmyers@users.noreply.github.com>
f0209f9 to
8ee094b
Compare
Re-check After Author UpdateI re-evaluated latest head Disposition: partially resolved. Resolved items:
Remaining items:
Docs: Fern docs are updated in the existing provider pages; no navigation change appears needed. E2E: still pending. This PR touches provider credential/policy behavior, so Independent reviewer result: confirmed the serialization issue as blocking; CAS/export/docs/test coverage otherwise looks satisfactory. Next state: |
Signed-off-by: John Myers <9696606+johntmyers@users.noreply.github.com>
|
Addressed the latest provider profile concurrency feedback in commit 3e0fe13. Profile imports now hold the shared sandbox/provider invariant guard from conflict validation through persistence, and sandbox creation with initial providers holds the same guard across provider existence/env-key validation through create. Added regression coverage for both guarded paths.\n\nVerification:\n- |
Re-check After Author UpdateI re-evaluated latest head Disposition: partially resolved. Resolved items:
Remaining items:
Checks: required non-E2E checks are still running for this head ( Next state: |
PR Review StatusValidation: Project-valid. PR #1914 implements the validated provider profile update work from #1881 and remains non-draft. Review findings:
Docs: Fern docs are updated in existing provider pages; no navigation change appears needed. Checks: required non-E2E checks are green. E2E is still not applied; this PR should get Next state: |
Signed-off-by: John Myers <9696606+johntmyers@users.noreply.github.com>
|
Addressed both follow-up review items in commit Changes:
Verification:
|
|
Label |
Re-check After Author UpdateI re-evaluated latest head Disposition: resolved. Remaining items:
Review status:
Docs: Fern docs are updated in the existing provider pages; no navigation change appears needed. Checks: Next state: |
Pipeline Follow-Up NeededHead SHA:
The failing test is I did not find an existing open issue or PR documenting this exact test failure. Because this PR touches provider, policy, and sandbox behavior, and the failure is in a required E2E policy/proxy path, this needs author follow-up before maintainer handoff. Next action: @johntmyers, please investigate the rust-podman L7 allowed-request failure or point to evidence that it is an unrelated CI flake or infrastructure incident. Gator will continue watching after an update. Next state: |
Pipeline Re-checkHead SHA: The required Because the required E2E job is actively running again, gator is moving this PR back to pipeline watch and will re-evaluate the E2E result after the rerun completes. Next state: |
Pipeline Follow-Up NeededHead SHA: The rerun of the required The repeated failing test is Because this is a repeated failure in a required policy/proxy E2E path and this PR touches provider, policy, and sandbox behavior, this still needs author follow-up before maintainer handoff. Next action: @johntmyers, please investigate the rust-podman L7 allowed-request failure or point to evidence that it is unrelated to this PR. Next state: |
Pipeline Re-checkHead SHA: The required Because the required E2E job is active again, gator is moving this PR back to pipeline watch and will re-evaluate the E2E result after the rerun completes. Next state: |
Summary
Add safe custom provider profile updates through a new
UpdateProviderProfilesRPC andopenshell provider profile update. The update path validates profile batches before writing, preserves stored custom profile metadata, rejects built-in and missing profiles, and keeps provider-derived policy JIT-composed from current profiles.Related Issue
Closes #1881
Changes
proto/openshell.proto: AddedUpdateProviderProfilesRPC and request/response messages.crates/openshell-server/src/grpc/provider.rs: Added custom profile update handling with validation, metadata preservation, built-in/missing rejection, and attached-sandbox dynamic token grant ambiguity checks.crates/openshell-server/src/grpc/policy.rs: Added tests proving updated profile policy reaches sandbox effective config without rewriting provider instances or persisted sandbox source policy, and that profile changes affect provider env revision.crates/openshell-cli/src/main.rs,crates/openshell-cli/src/run.rs: Addedopenshell provider profile update -f|--from.docs/sandboxes/providers-v2.mdx,docs/sandboxes/manage-providers.mdx: Documented custom profile update semantics and rollout behavior.Deviations from Plan
The plan preferred all-or-none server-side batch updates if cleanly supported. The existing persistence API does not provide transactional multi-object CAS, so this implementation validates the full batch before writes and documents the remaining concurrent-write/storage-error retry behavior instead of adding a broad transaction layer.
Testing
cargo test -p openshell-server update_provider_profile -- --nocapturecargo test -p openshell-server sandbox_config_uses_updated_custom_provider_profile -- --nocapturecargo test -p openshell-server provider_env_revision_changes_when_custom_profile_token_grant_changes -- --nocapturecargo test -p openshell-cli provider_profile_commands_parse -- --nocapturecargo test -p openshell-cli provider_profile_cli_run_functions_support_custom_profiles -- --nocapturemise run pre-commite2e/files changedTests added:
Checklist