Skip to content

test(markdown): pin voice and deploy output for parenthesised links - #15951

Merged
bolichen97 merged 1 commit into
kirodotdev:mainfrom
unstablebrainiac:test/link-sweep-review-notes
Oct 2, 2026
Merged

bolichen97 merged 1 commit into
kirodotdev:mainfrom
unstablebrainiac:test/link-sweep-review-notes

Conversation

@unstablebrainiac

Copy link
Copy Markdown
Contributor

Problem / Motivation

Goal: A later change to either link output that the approving review of #15714 found untested fails a test.

The approving review of #15714 named two outputs that no test covers:

  • The voice reply reads an unbalanced-paren link destination aloud, where main read only the label.
  • The artifact-deploy page keeps a quote inside a parenthesised link URL escaped in the href, but no test proves it.

Why it matters

The deploy page turns an artifact into a standalone web page. If its href re-escape were dropped, a quote in a link's URL would end the attribute and start a new one: see [a](https://example.com/(b"onmouseover="x)) now would render <a href="https://example.com/(b"onmouseover="x)">a</a>. On main, that change passes all 1,433 tests in the two test files that call the deploy renderer.

The voice output has no guard either. A later fallback that read such a link as its label would pass all 2,523 tests in the ten test files that import voice_reply, and what the reply speaks would change unnoticed.

Not a goal

  • Changing what the voice reply speaks for an unbalanced link. This PR pins today's output; whether a relative destination should be read aloud is a separate decision.
  • Any production code change.

What changed (motivation → approach → change)

Three new tests pin the outputs below. No production code changes.

Output Input Pinned result
Voice reply, web address see [a](https://example.com/(b) now see [a]( (link) now
Voice reply, relative destination see [guide](docs/setup(old) now see [guide](docs/setup(old) now
Deploy page see [a](https://example.com/(b"onmouseover="x)) now <a href="https://example.com/(b&quot;onmouseover=&quot;x)">a</a> now

An unbalanced ( means the text is not a Markdown link, so the voice reply leaves it as written. Its bare-URL pass then swaps a web address for "(link)". That pass only knows web addresses, so a relative destination is read aloud as written. On the deploy page the link is balanced, and its quote stays &quot; inside the href, so it cannot end the attribute. Two of the tests are in test/test_voice_reply.py and one is in test/test_deploy_web_render_scan.py.

Backwards compatibility

Compatible: the diff adds tests only.

Tests

  • test_a_web_address_in_an_unbalanced_link_is_never_spoken locks in "(link)" in place of the URL.
  • test_a_relative_destination_in_an_unbalanced_link_is_spoken_as_written locks in the spoken text, unchanged.
  • test_a_quote_in_a_parenthesised_link_url_stays_escaped_in_the_href locks in &quot; inside the href, with no raw onmouseover=" anywhere on the page.

Each new test fails when its output changes. Four mutations in a throwaway worktree each failed the tests they target: dropping the voice bare-URL pass, restoring the old voice pattern that cut at the first ), adding a fallback that reads an unbalanced link as its label, and putting the unescaped URL in the href.

Manual verification

N/A: the outputs are plain string transforms, and the tests assert them directly.

Related Issues

no linked issue: follow-up to the two non-blocking notes in the approving review of #15714.

Checklist

  • At most two commits (one is the norm), with a Conventional Commits title (feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...)
  • Existing tests pass and new tests added for new functionality
  • Self-review completed; code follows project style guidelines
  • Documentation updated (if applicable): N/A, tests only
  • No secrets, credentials, or internal references in the diff

@unstablebrainiac
unstablebrainiac requested a review from a team as a code owner October 1, 2026 17:46
@github-actions github-actions Bot added fork Pull request from a fork (external contributor) readiness: checking Automated validation is still running labels Oct 1, 2026
@github-actions

github-actions Bot commented Oct 1, 2026 •

Copy link
Copy Markdown
Contributor

GPT 5.6 Review (fork) — ✅ no blocking findings

Reviewed e269ad58f6e2bb6a02723d0761cafe633361144b via the fork AI-review pipeline; updated in place on each push.

Review details

No findings.
[GPT-REVIEWED] e269ad5

@github-actions

github-actions Bot commented Oct 1, 2026 •

Copy link
Copy Markdown
Contributor

Design Review (Fable 5, fork) — ✅ PASS

Design-level review of e269ad58f6e2bb6a02723d0761cafe633361144b via the fork AI-review pipeline — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS/CONCERNS are advisory.

Design-Verdict: PASS

Confirm maintainers want the awkward see [a]( (link) now voice output pinned as-is rather than fixed first; the PR defers that deliberately.

[DESIGN-REVIEWED] e269ad5

Description read

[DESCRIPTION-READ] 9b599f75ebf7085061e5b77c588aa6b067542adbe0f0c38d052c48b2728b83a5

That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with .github/scripts/pr-description-capture.sh over the same inputs; if it differs, the description or that evidence changed after this verdict was formed and any finding drawn from either is unproven.

@github-actions

github-actions Bot commented Oct 1, 2026 •

Copy link
Copy Markdown
Contributor

Opus 5 Review (fork) — ✅ no blocking findings

Reviewed e269ad58f6e2bb6a02723d0761cafe633361144b via the fork AI-review pipeline; updated in place on each push.

Review details

No findings.

[OPUS-REVIEWED] e269ad5

@unstablebrainiac
unstablebrainiac force-pushed the test/link-sweep-review-notes branch from ef30717 to 0aa5c96 Compare October 1, 2026 20:02
@unstablebrainiac

Copy link
Copy Markdown
Contributor Author

Re-pushed to rerun CI, rebased onto main 1338692 with the patch unchanged (main's one new commit touches none of this PR's files). On ef30717, Backend Lint & Type Check (3.12) hit the job's 25-minute limit: black took 14.5 minutes on that runner, so mypy was cancelled partway through, after black, isort and flake8 had passed. Lint jobs on other PRs that started at the same time finished in 17 to 19 minutes. Every other check that ran on ef30717 passed, including all AI review lanes.

@unstablebrainiac
unstablebrainiac force-pushed the test/link-sweep-review-notes branch from 0aa5c96 to c95b8d8 Compare October 2, 2026 00:01
@unstablebrainiac

Copy link
Copy Markdown
Contributor Author

Re-pushed the same patch, rebased onto main bc80d8d8a, to re-run CI. The only red on 0aa5c96e5 was CI / Backend Tests (Windows) (3), failing test/test_session_export.py::test_a_sent_export_streams_its_staged_file_and_removes_it with assert not True. That is the load-dependent race tracked in #15736. This PR touches neither that test nor its code, and the same shard passed on ef307179e. On 0aa5c96e5 the GPT and Opus lanes found nothing, Design passed, and First Principles and UX had no surface to review.

Two outputs of the parenthesised-URL sweep (kirodotdev#15714) had no test.

A link whose destination holds an unbalanced "(" is not a link, so the
voice reply leaves its text as written. A web address in it is still
replaced by "(link)", but a relative destination is spoken as written.

The artifact-deploy page keeps a quote inside a parenthesised URL
escaped as &quot; in the link's href, so it cannot end the attribute.

Both outputs are pinned now, so a later change to either fails a test.
@unstablebrainiac
unstablebrainiac force-pushed the test/link-sweep-review-notes branch from c95b8d8 to e269ad5 Compare October 2, 2026 01:22
@unstablebrainiac

Copy link
Copy Markdown
Contributor Author

Rebased onto main fa37aa54f. Backend Lint & Type Check (3.12) failed on src/kiro_crew/autonudge.py:1797:9: F811 redefinition of unused 'probes', a duplicate import main carried from #12781 until #16032 removed it. This PR touches neither file. CI re-running.

@github-actions github-actions Bot added readiness: passed Eligible automated validation passed for the current revision and removed readiness: checking Automated validation is still running labels Oct 2, 2026

@bolichen97 bolichen97 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved: PR Readiness green on this head, merges cleanly into current main, no outstanding blocking review.

@bolichen97
bolichen97 merged commit 671b7c1 into kirodotdev:main Oct 2, 2026
100 checks passed
@github-actions github-actions Bot removed the readiness: passed Eligible automated validation passed for the current revision label Oct 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fork Pull request from a fork (external contributor)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants