Skip to content

fix: expire prompt tool diffs on provider change#13641

Merged
axiomofjoy merged 1 commit into
Arize-ai:mainfrom
he-yufeng:fix/prompt-tools-provider-stale-v2
Jun 12, 2026
Merged

fix: expire prompt tool diffs on provider change#13641
axiomofjoy merged 1 commit into
Arize-ai:mainfrom
he-yufeng:fix/prompt-tools-provider-stale-v2

Conversation

@he-yufeng

Copy link
Copy Markdown
Contributor

Summary

  • store the provider used to render a pending write_prompt_tools approval diff
  • reject accept when the playground provider has changed before the user approves the diff
  • add regression coverage for provider drift between proposal and accept

Fixes #13626.

To verify

  • git diff --check
  • Select-String -Path app/src/agent/tools/playgroundPromptTools/*.ts,app/src/agent/tools/playgroundPromptTools/tests/playgroundPromptTools.test.ts -Pattern 'sk-[A-Za-z0-9_-]+'

Not run

  • pnpm exec vitest run src/agent/tools/playgroundPromptTools/__tests__/playgroundPromptTools.test.ts --runInBand
  • pnpm exec oxlint ...

The local Windows install could not finish because registry downloads repeatedly timed out and then a partial install hit a Windows rename EPERM under app/node_modules/.pnpm. I removed the incomplete node_modules afterward because the C: drive is below the local warning threshold.

@he-yufeng he-yufeng requested a review from a team as a code owner June 5, 2026 16:27
@github-project-automation github-project-automation Bot moved this to 📘 Todo in phoenix Jun 5, 2026
@dosubot dosubot Bot added the size:S This PR changes 10-29 lines, ignoring generated files. label Jun 5, 2026
@github-actions github-actions Bot added the triage issues that need triage label Jun 5, 2026
@he-yufeng

Copy link
Copy Markdown
Contributor Author

I rechecked the red checks here. The product checks are green: Python required, TypeScript required, Playwright required, docs, lint, schema, and e2e all passed.

The remaining failures are workflow/secret related rather than patch failures:

  • Run Chromatic fails with Missing project token / missing CHROMATIC_PROJECT_TOKEN.
  • claude-review fails before review starts because the workflow cannot get an OIDC token (Unable to get ACTIONS_ID_TOKEN_REQUEST_URL; likely missing id-token: write).

No code change from this branch appears needed for those two jobs.

@github-project-automation github-project-automation Bot moved this from 📘 Todo to 👍 Approved in phoenix Jun 12, 2026
@axiomofjoy axiomofjoy merged commit d5ba51b into Arize-ai:main Jun 12, 2026
38 of 40 checks passed
@github-project-automation github-project-automation Bot moved this from 👍 Approved to ✅ Done in phoenix Jun 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:S This PR changes 10-29 lines, ignoring generated files. triage issues that need triage

Projects

Status: ✅ Done

Development

Successfully merging this pull request may close these issues.

PXI write_prompt_tools approval diff should expire on provider changes

2 participants