Skip to content

fix(frontend): keep the typed name in the new evaluation drawer when an app is picked - #8204

Merged
mmabrouk merged 1 commit into
release/v0.128.10from
fix/m-new-evaluation-keep-typed-name
Nov 6, 2026
Merged

mmabrouk merged 1 commit into
release/v0.128.10from
fix/m-new-evaluation-keep-typed-name

Conversation

@mmabrouk

@mmabrouk mmabrouk commented Nov 6, 2026

Copy link
Copy Markdown
Member

Context

In the /m New Auto Evaluation drawer, picking an application after you type a name cleared the name. Release QA for v0.128.9 found this. The drawer cleared the name because picking an app rebuilt the whole draft from empty, and the name went with it.

Changes

A name that you type now stays when you pick an app, pick a different app or remove the app. The name auto-fills only while you have not typed one:

  • Typed "my capitals check", then picked Capital finder and a revision. Before: the name field was empty. After: it still reads "my capitals check".
  • A name the drawer made itself still gives way when you pick another app, and it fills again from the new picks.
  • If you clear the field, the auto name comes back when you leave the field.

Note on /w: in the old app, handleAppSelection in NewEvaluationModalInner.tsx also calls setEvaluationName("") when the app changes. This PR follows the rule the release QA asked for, so /m now keeps a typed name.

The drawer is only reachable with beta developer mode on (evaluations is a hidden developer view). Nothing changes for /m without developer mode.

Tests / notes

  • New tests in newEvaluationDraft.test.ts: "A typed name stays when an app is picked, changed or cleared, and later picks keep it" fails before the fix. "An auto name gives way to the next app, and a cleared name auto-fills again" covers the auto-fill.
  • newEvaluationDraft.test.ts and newEvaluationSheet.render.test.tsx pass (42 tests). /m types pass, eslint passes, and prettier and gitleaks ran in the commit hook.
  • Checked live on a parity stack: typed a name, picked Capital finder and a revision, and the name stayed.

What to QA

  • Evaluations > New evaluation > Auto evaluation. Type a name, pick an app, then a revision and a test set. The name you typed stays.
  • Open a fresh drawer and pick an app, a revision and a test set without typing. The name fills in by itself.
  • Clear the name field and click outside it. The auto name comes back.

…an app is picked

Entire-Checkpoint: 01M6RX3H80WJ8AWQYVRX5FDNNG
@coderabbitai

coderabbitai Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Summary

Summary by CodeRabbit

  • Bug Fixes
    • Manually entered evaluation names are preserved when changing or clearing the selected app. Automatically generated names continue to update with app selections.
    • Clearing an app returns the draft to its default section; selecting an app opens the revision section.

The evaluation draft reducer now preserves a manually typed name when an app is selected, changed, or cleared. Tests cover name preservation and updates to auto-generated names.

Changes: Evaluation draft naming

Layer / File(s) Summary
Preserve typed names across draft changes
web/mobile/src/features/evaluations/new/newEvaluationDraft.ts, web/mobile/tests/unit/newEvaluationDraft.test.ts
The reducer preserves a manually typed name when an app is changed or cleared. Tests cover typed names across subsequent picks and the behavior of auto-generated names.

Estimated code review effort: 2 (Simple) | ~8 minutes

Possibly related PRs

  • Agenta-AI/agenta#8149: Adds draft input detection and a discard confirmation that reads the draft name.
Merge Risk: Minimal · up to 4cd8e

Typed names are preserved in the common app-selection workflow. No merge-blocking risk remains.

Pre-merge checks: Passed 5

Check name Status Explanation
Title check Passed The title clearly describes the main change: preserving a typed evaluation name when an app is picked.
Description check Passed The description matches the changes to typed and automatically generated evaluation names and their tests.
Docstring Coverage Passed 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 Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed 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 2 files.

Finishing Touches

Generate docstrings

  • Commit to this branch
  • Create a new PR
Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • 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.

Share

Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 53942d0 and 4cd8e37.

Files selected for processing: 2

  • web/mobile/src/features/evaluations/new/newEvaluationDraft.ts
  • web/mobile/tests/unit/newEvaluationDraft.test.ts

Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 3 remain after this review.

@github-actions

github-actions Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

Railway Preview Environment

Item Value
Status stopped
Commit 4cd8e37de04e8cffd929c8e3bf8051c1587a23de
Manual expiry (UTC) Not granted
CI deadline (UTC) Not granted
Workflow https://github.com/Agenta-AI/agenta/actions/runs/42258538320

Dependent tests finished. Post /preview for manual review. 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.

@mmabrouk

mmabrouk commented Nov 6, 2026

Copy link
Copy Markdown
Member Author

🤖 The AI agent says: @coderabbitai review

@coderabbitai

coderabbitai Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

@mmabrouk I’ll start a review of the PR.

Action not completed

Already reviewed the last commit. Use @coderabbitai full review to rerun a review of the entire changeset.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@mmabrouk
mmabrouk changed the base branch from release/v0.128.9 to release/v0.128.10 November 6, 2026 18:57
@mmabrouk
mmabrouk merged commit eb7e4db into release/v0.128.10 Nov 6, 2026
84 of 86 checks passed
@mmabrouk mmabrouk added the lgtm This PR has been approved by a maintainer label Nov 6, 2026
@mmabrouk mmabrouk mentioned this pull request Nov 6, 2026
4 tasks done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

lgtm This PR has been approved by a maintainer

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant