Skip to content

build(deps): update dependencies and fix hmac KeyInit import#34

Open
ljahier wants to merge 12 commits into
mainfrom
chore/dissolve-ports-into-domains
Open

build(deps): update dependencies and fix hmac KeyInit import#34
ljahier wants to merge 12 commits into
mainfrom
chore/dissolve-ports-into-domains

Conversation

@ljahier

@ljahier ljahier commented Jul 9, 2026

Copy link
Copy Markdown
Member

No description provided.

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Jul 9, 2026

Copy link
Copy Markdown

Deploying pratrol with  Cloudflare Pages  Cloudflare Pages

Latest commit: c58e19d
Status: ✅  Deploy successful!
Preview URL: https://8e0f2550.pratrol.pages.dev
Branch Preview URL: https://chore-dissolve-ports-into-do.pratrol.pages.dev

View logs

mendral-app[bot]

This comment was marked as outdated.

mendral-app[bot]

This comment was marked as outdated.

mendral-app[bot]

This comment was marked as outdated.

mendral-app[bot]

This comment was marked as outdated.

@ljahier ljahier force-pushed the chore/dissolve-ports-into-domains branch from c6df2ec to 0237f57 Compare July 10, 2026 05:36
mendral-app[bot]

This comment was marked as outdated.

mendral-app[bot]

This comment was marked as outdated.

mendral-app[bot]

This comment was marked as outdated.

@mendral-app mendral-app Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Needs attention — 1 issue in 1 file

The new changes are well-structured — graceful shutdown, dedup cache, Askama migration, and Score encapsulation are all correctly implemented. The contains("merge") guardrail false-positive remains the only actionable finding after four review cycles.

What this PR does

Major refactor: migrates manual .replace() template rendering to type-safe Askama templates, introduces graceful shutdown with TaskTracker + CancellationToken, adds moka-based dedup cache for duplicate webhook deliveries, extracts HMAC verification into an Axum extractor, encapsulates Score behind a clamping constructor, moves constants to dedicated modules, and separates history rendering from domain evaluation into the comment layer.

Prompt for AI agents (all issues)
Check if these issues are valid — if so, understand the root cause of each and fix them.

<assessment>
The new changes are well-structured — graceful shutdown, dedup cache, Askama migration, and `Score` encapsulation are all correctly implemented. The `contains("merge")` guardrail false-positive remains the only actionable finding after four review cycles.
</assessment>

<file name="src/agent/guardrails.rs">
<issue location="src/agent/guardrails.rs:8">
Substring matching with `contains("merge")` false-positives on words like "emerging", "submerge", "merger". This is the fourth review cycle raising this — a recommendation saying "avoid emerging patterns" on a high-suspicion PR will incorrectly trigger `InconsistentApproval`. Use a leading-space prefix to approximate word boundaries.
</issue>
</file>

Tag @mendral-app with feedback or questions. View session

Comment thread src/agent/guardrails.rs

const URL_MARKERS: [&str; 3] = ["http://", "https://", "www."];

const APPROVAL_MARKERS: [&str; 4] = ["approve", "merge", "lgtm", "looks good"];

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

bug (P2): Substring matching with contains("merge") false-positives on words like "emerging", "submerge", "merger". This is the fourth review cycle raising this — a recommendation saying "avoid emerging patterns" on a high-suspicion PR will incorrectly trigger InconsistentApproval. Use a leading-space prefix to approximate word boundaries.

Suggested change
Suggested change
const APPROVAL_MARKERS: [&str; 4] = ["approve", "merge", "lgtm", "looks good"];
const APPROVAL_MARKERS: [&str; 4] = ["approve", " merge", "lgtm", "looks good"];
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At src/agent/guardrails.rs, line 8:

<issue>
Substring matching with `contains("merge")` false-positives on words like "emerging", "submerge", "merger". This is the fourth review cycle raising this — a recommendation saying "avoid emerging patterns" on a high-suspicion PR will incorrectly trigger `InconsistentApproval`. Use a leading-space prefix to approximate word boundaries.
</issue>

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