You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(frontend): fix the endpoints snippet, prompts type, variants labels and the traces filter warning in /m - #8076
Small fixes to hidden /m views. Safe for v0.128.5 if the release session wants them; otherwise the next release.
Context
A live QA run on the hidden /m developer views (endpoints, prompts, variants and the observability app filter) found bugs that block showing these views to users. Each fix below is its own commit with a test that failed before the fix. The QA also found that a prompt moved into a folder cannot be moved back to the top level. That fix needs an API change, so it is in #8077 for the next release, and the /m Move dialog still offers folders only.
Changes
Endpoints: the code snippet sent empty inputs. The snippet read the revision's input schema, and a prompt app usually has none, so a copied call failed with HTTP 400 "Expected ['country']". The snippet now reads the revision's input ports, as /w does, so each prompt variable gets a placeholder. It works for completion and chat apps, and odd variable names stay quoted in Python, cURL and TypeScript.
Prompts: a chat app showed "Completion". The list read the type from the app list flags, which carry no chat flag. The row now reads the type from the latest revision, the same source /w uses.
Variants: labels and Modified by.
An empty deploy note now stays empty, as in /w. /m sent no note, and the shared package then wrote Deploy <app>.revision as the note.
The revision drawer title is "Revision" (it said "Workflow Revision"), and the delete toast says "Deleted revision successfully".
Modified by now shows the user. /m never binds the shared user lookup that UserAuthorLabel needs, so every id showed a dash. The Deployments tab now passes the names from the workspace members (username, else email). Other /m tables with Created by still show a dash; binding the lookup app wide would add a members request to every page, so it is left for a follow-up.
Observability: React logged "Cannot update a component while rendering a different component". The screen wrote the app scope atoms during its render, and the mounted TracesFilters read them, so React logged an error on the first filter change. The picker now writes the scope in its change handler, so the render after the URL change has nothing to write. The write during the first render stays, because it scopes the first traces request before any reader mounts.
Shared package changes
@agenta/settings-ui: buildAppEndpointParams takes inputs (the input ports) instead of inputSchema. Only /m and its Storybook story call it. /w does not use it.
@agenta/entity-ui: the revision drawer title. Only /m renders that drawer.
The /w type check passes, and nothing changes for /w.
Tests
New and updated tests: endpoints screen and snippet builder, prompts screen type, deploy note (real publish mutation, only the HTTP client mocked, asserting the commit body), deployments tab, revision drawer, and the app scope warning.
/m and /w type checks pass. The full /m suite passes except membersTabRoleChange, which fails on the release branch too. The entities, entity-ui and settings-ui suites pass except mcp-policy-ladder, which fails only on a copy without .git.
speed:check passes. Every shared page has the same first-load size as the base. The variants view grew by 0.1 KB.
One review round (slop, simplify, correctness) rated every lens Low. A final correctness pass found nothing. After that pass, the move commit was taken out, and nothing else changed.
What to QA
Turn on the developer views endpoints, prompts, variants and observability-app-filter.
Endpoints: deploy a completion app that uses {{country}}, open its environment, copy the Python snippet and run it with a real key. The call succeeds.
Prompts: a chat app shows Chat, and a completion app shows Completion.
Variants: deploy with an empty note. The Notes column shows a dash. Modified by shows your user. Open a revision: the drawer title is Revision.
Observability: change the app filter on the Traces tab. The browser console shows no React error.
Regression: on the /m variants Deployments tab, deploy with a written note. The note shows as written.
…ables in /m
The snippet read the revision's input schema, which a prompt app often leaves
empty, so it sent "inputs": {} and a copied call failed with HTTP 400. Read the
input ports instead, as /w does, so each prompt variable gets add_a_value.
The list read the type from the app list flags, which carry no chat flag, so
every prompt showed Completion. Read the latest revision's type, as /w does.
Review loop result for head f8fbe2f2cc (base d6ef7781e5), one round plus a final correctness pass.
Lens
Final rating
Slop (Opus and Codex)
Low
Simplify (Opus and Codex)
Low
Correctness (Codex, round 1 and final head)
Low
Fixed: the Endpoints story still passed inputSchema, so it threw on load. The params builder used inputs for two things. Left on purpose: the PromptItem alias stays, because the dialog state types name it. The two-line folder_id guard stays in both the application and evaluator services, so the services stay independent.
No actionable comments were generated in the recent review.
Summary
Summary by CodeRabbit
New Features
Generated endpoint snippets now include prompt variables with editable placeholders, including for chat apps.
Deployment history displays authors’ workspace usernames or email addresses when available.
Bug Fixes
Selecting an app in observability keeps the selected app scope in sync with the URL.
Prompt rows show the correct workflow type.
Deployment notes are trimmed before saving, including empty notes.
Updates
Revision deletion confirmations and revision drawer titles now use clearer wording.
The PR updates endpoint snippet inputs, observability app selection, prompt type display, and variant deployment and revision behavior. It also changes revision labels and notifications, and updates tests and Storybook examples for these changes.
Changes: Endpoint snippet inputs
Layer / File(s)
Summary
Input contract and snippet generation web/packages/agenta-settings-ui/src/publish/snippets/appEndpoint.ts, web/packages/agenta-settings-ui/tests/unit/appEndpointSnippets.test.ts
The snippet builder accepts keyed inputs with optional schemas. It uses schema defaults or an add_a_value placeholder. Tests cover chat inputs, defaults, and input-name formatting.
Revision input wiring and validation web/mobile/src/features/endpoints/useEndpointSnippets.ts, web/mobile/tests/unit/endpointsScreen*, web/storybook/stories/developer-views/EndpointsScreen.stories.tsx
The endpoint hook and Storybook example pass input ports to the builder. Mobile tests cover generated completion and chat snippets.
Observability app selection
Layer / File(s)
Summary
App selection and URL update web/mobile/src/features/observability/observabilityAppScope.ts, web/mobile/src/features/observability/ObservabilityScreen.tsx, web/mobile/tests/unit/observabilityAppScope.test.tsx
The new useSelectObservabilityApp hook updates the selected app scope before updating the URL. The screen uses the hook, and the test checks the scope and shallow URL update.
Prompt type display
Layer / File(s)
Summary
Workflow type source and row display web/mobile/src/features/prompts/*, web/mobile/tests/unit/promptsScreen.render.test.tsx, web/mobile/tests/unit/promptsTestStore.tsx
Prompt records no longer receive a derived type field. Prompt rows read the type from the workflow type atom. Tests seed latest-revision data and check the displayed labels.
Variant deployment and revision updates
Layer / File(s)
Summary
Workspace member lookup and history labels web/mobile/src/features/variants/DeploymentsTab.tsx, web/mobile/src/features/variants/DeploymentHistoryTable.tsx, web/mobile/src/features/variants/VariantsScreen.tsx, web/mobile/tests/unit/deploymentsTab.render.test.tsx, web/storybook/stories/developer-views/DeploymentsTab.stories.tsx
The deployments tab builds an author-name map from workspace members and passes it to the history table. Tests cover username, email, and unknown-author labels.
Trimmed note serialization and tests web/mobile/src/features/variants/useDeploymentWrites.ts, web/mobile/tests/unit/variantsDeployNote.test.tsx
The deployment write payload retains an empty string after trimming a blank note. Tests cover empty and non-empty deploy and revert notes.
Revision title and deletion notification web/mobile/src/features/variants/DeleteRevisionDialog.tsx, web/packages/agenta-entity-ui/src/variant/RevisionDrawer/RevisionDrawerHeader.tsx, web/mobile/tests/unit/variantDialogs.render.test.tsx, web/packages/agenta-entity-ui/tests/unit/revisionDrawer.render.test.tsx, web/storybook/stories/entity-ui/RevisionDrawer.stories.tsx
The revision drawer title changes to “Revision.” The successful deletion message changes to “Deleted revision successfully.” Tests and the Storybook interaction use the updated text.
Some deployment author names and prompt type indicators may remain unavailable after recoverable lookup failures, but safe fallback UI remains and the affected workflows can continue.
Pre-merge checks: 5
Check name
Status
Explanation
Description check
The description clearly covers the endpoints, prompts, variants, and observability changes in the pull request, including testing and QA details.
Title check
The title accurately summarizes the main fixes for endpoints snippets, prompt types, variants labels, and the observability filter warning in /m.
Docstring Coverage
No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentat…
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage
Explanation
No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 0 functions across 28 files.
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 3 remain after this review.
- An empty deploy note now stays empty, as in /w. /m sent undefined, and the
package then wrote the raw "Deploy <app>.revision" key as the note.
- The revision drawer title is Revision, and the delete toast says revision.
- Modified by shows the member name. /m never binds the shared user atoms, so
the author label could not resolve an id; the tab now passes the names from
the workspace members.
…traces app filter
The screen wrote the app scope atoms during its render. With the traces filters
already mounted, that write updated TracesFilters while ObservabilityScreen
rendered, and React logged an error. A pick in the toolbar now writes the scope
in the change handler, so the render after the URL change has nothing to write.
mmabrouk
changed the title
fix(frontend): fix the endpoints snippet, prompts type and move, variants labels and the traces filter warning in /m
fix(frontend): fix the endpoints snippet, prompts type, variants labels and the traces filter warning in /m
Nov 3, 2026
PR closed or converted to draft. Environment absence verified; retained storage requires separate provider accounting.
Post /preview as a new comment to request a one-hour preview. Repeating it while active does not extend the hour.
Preview data is disposable. Expiry is enforced by the next successful cleanup sweep, not an exact timer.
Environment deletion stops its compute. Provider-retained storage and permanent services may still be billed.
Repository rules for web/** allow at most one short line per in-code comment. Multi-line prose that describes test setup is not an exception. Keep the mocking distinction in one line.
Proposed edit
-/**- * The deploy and revert writes over the real publish mutation. Only the HTTP client is replaced,- * so each test checks the environment commit body that would reach the server.- */+// Exercise the real publish mutation; mock only HTTP.
Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 7 remain after this review.
🤖 The AI agent says: Live QA passed on head 7f1a2c7 (release/v0.128.5 merged in, no conflicts).
Setup: one fresh OSS dev stack built from release/v0.128.5 with #8075, #8076, #8077 and #8086 merged in, developer views playground,prompts,variants,endpoints,observability-app-filter on, a new account, Chromium at 1440 px and 390 px. The API ran this batch's code.
Endpoints: I copied the production Python and cURL snippets. They send "country": "add_a_value". With an API key and a real value, both calls returned HTTP 200 ("Paris", "Tokyo"). Pass at 1440 and 390.
Prompts: qa-chat shows Chat and qa-completion shows Completion. Pass at 1440 and 390.
Variants: a deploy with an empty note sends message: "", and the Notes column shows a dash. A deploy with a note shows the note as written. Modified by shows the user. The revision drawer title is "Revision".
Observability: the first and second app filter changes log no "Cannot update a component" error. The filter stays after a reload. Pass at 1440 and 390.
Checks on this head: /m types, /w types, pnpm run lint in web/mobile (0 errors), the PR's tests (mobile 87, entity-ui, settings-ui), and speed:check after a fresh next build all pass. Needed CI is green. Only the web test jobs fail, and they do not gate.
The screen recording (MP4) is saved with the QA evidence. I could not attach it here because the browser upload was not available in this session.
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
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.
Small fixes to hidden /m views. Safe for v0.128.5 if the release session wants them; otherwise the next release.
Context
A live QA run on the hidden /m developer views (endpoints, prompts, variants and the observability app filter) found bugs that block showing these views to users. Each fix below is its own commit with a test that failed before the fix. The QA also found that a prompt moved into a folder cannot be moved back to the top level. That fix needs an API change, so it is in #8077 for the next release, and the /m Move dialog still offers folders only.
Changes
Endpoints: the code snippet sent empty inputs. The snippet read the revision's input schema, and a prompt app usually has none, so a copied call failed with HTTP 400 "Expected ['country']". The snippet now reads the revision's input ports, as /w does, so each prompt variable gets a placeholder. It works for completion and chat apps, and odd variable names stay quoted in Python, cURL and TypeScript.
Before:
"inputs": {}. After:"inputs": {"country": "add_a_value"}.Prompts: a chat app showed "Completion". The list read the type from the app list flags, which carry no chat flag. The row now reads the type from the latest revision, the same source /w uses.
Variants: labels and Modified by.
Deploy <app>.revisionas the note.UserAuthorLabelneeds, so every id showed a dash. The Deployments tab now passes the names from the workspace members (username, else email). Other /m tables with Created by still show a dash; binding the lookup app wide would add a members request to every page, so it is left for a follow-up.Observability: React logged "Cannot update a component while rendering a different component". The screen wrote the app scope atoms during its render, and the mounted
TracesFiltersread them, so React logged an error on the first filter change. The picker now writes the scope in its change handler, so the render after the URL change has nothing to write. The write during the first render stays, because it scopes the first traces request before any reader mounts.Shared package changes
@agenta/settings-ui:buildAppEndpointParamstakesinputs(the input ports) instead ofinputSchema. Only /m and its Storybook story call it. /w does not use it.@agenta/entity-ui: the revision drawer title. Only /m renders that drawer.The /w type check passes, and nothing changes for /w.
Tests
membersTabRoleChange, which fails on the release branch too. The entities, entity-ui and settings-ui suites pass exceptmcp-policy-ladder, which fails only on a copy without.git.speed:checkpasses. Every shared page has the same first-load size as the base. The variants view grew by 0.1 KB.What to QA
Turn on the developer views
endpoints,prompts,variantsandobservability-app-filter.{{country}}, open its environment, copy the Python snippet and run it with a real key. The call succeeds.