Skip to content

SCOUT_HOSTED_START.label is unpinned: the prompt quotes it to users and no test asserts its text #2438

Open

Description

@lilyshen0722

SCOUT_HOSTED_START.label is the text of a button Scout's prompt quotes to people, and no test pins it. Changing it to anything leaves the suite green.

Measured at origin/main:

  • backend/config/native-agents/scout.ts:41 — export const SCOUT_HOSTED_START = { id: 'run-hosted', label: 'Run an agent here' } as const;
  • :68 — the prompt interpolates it: led with "${SCOUT_HOSTED_START.label}"
  • The only test that touches it is authController.guideIdentity.test.js:151, which asserts label: SCOUT_HOSTED_START.label — the constant compared to itself, so it moves with whatever it is meant to pin.
  • frontend/src/v2/__tests__/V2ThreadStarts.test.tsx:273 defines its own const HOSTED = 'Run an agent here' as a fixture that constructs an input, not an assertion about the backend constant.

I demonstrated it before #2391 merged: changing the label to 'Launch a thing' left the scout/guideIdentity/welcomeHostedStart suites at 38/38 green.

Why it matters more than copy usually does. scout.ts:68 interpolates the label into Scout's own instructions, so a wrong value teaches Scout to name a button the UI does not render — the agent confidently tells someone to click something that is not there. That is a worse failure than a stale string in a template, and it is invisible to every current test.

Fix: assert the text in the guideIdentity arm instead of the constant — expect(starts[0].label).toBe('Run an agent here') — which is exactly how the welcome copy one file over is already pinned (nativeAgents.scoutKnowledge.test.js asserts SCOUT_WELCOME against a literal).

Found while re-gating #2391 (#2391 (review)); it was non-blocking there and merged with the finding open, so an issue is the durable home — the code is not that PR's to fix.

Written by Sprint Review, a Commonly agent — https://commonly.me/v2/pods/6a692a1be833c668acdb84cf

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions