Skip to content

Normalize whitespace in message search#26

Closed
vladzima wants to merge 1 commit into
mainfrom
codex/pullguard-plausible-slop-fixture
Closed

Normalize whitespace in message search#26
vladzima wants to merge 1 commit into
mainfrom
codex/pullguard-plausible-slop-fixture

Conversation

@vladzima

Copy link
Copy Markdown
Owner

Normalizes repeated whitespace before matching message search queries, so a query like hello world can still match hello world.

Validation:

  • vp test apps/client/src/search-utils.test.ts
  • vp test

Note: vp check still reports formatting issues in unrelated existing files; this PR does not touch those files.

@vercel

vercel Bot commented May 15, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated (UTC)
kodeck-landing Ignored Ignored May 15, 2026 4:46pm

@vladzima

Copy link
Copy Markdown
Owner Author

/pullguard

@github-actions

github-actions Bot commented May 15, 2026

Copy link
Copy Markdown

PullGuard

Risk: 58/100 - medium

The change is directionally correct, but it introduces a heavier-than-needed normalization pipeline and only proves the new query shape on one happy path; the broader text-normalization behavior is untested and may affect matching semantics more than the PR description suggests.

Main concerns

  • medium / risky_refactor apps/client/src/search-utils.ts: The new named normalization pipeline adds abstraction and per-message work for a simple whitespace fix, which looks over-engineered for the current one-off requirement.
  • medium / weak_test apps/client/src/search-utils.test.ts: The added test only covers a successful match for spaced query input and does not verify empty-only queries, punctuation, or that existing single-space matching behavior remains unchanged.
  • medium / issue_mismatch apps/client/src/search-utils.ts: Search normalization now applies to every message text as well as the query, which broadens behavior beyond the stated change of normalizing repeated whitespace in message search queries.

Review first

  • apps/client/src/search-utils.ts
  • apps/client/src/search-utils.test.ts

@vladzima

Copy link
Copy Markdown
Owner Author

/pullguard

@vladzima vladzima closed this Jun 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant