feat(review): tag tracking comments for classification - #133
Open
factory-andrew-seo wants to merge 6 commits into
Open
feat(review): tag tracking comments for classification#133factory-andrew-seo wants to merge 6 commits into
factory-andrew-seo wants to merge 6 commits into
Conversation
Add a dedicated hidden marker to PR review tracking comments and preserve it across sanitized summary updates. Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
Contributor
|
Droid finished @factory-andrew-seo's task —— View job The PR review marker tagging is cohesive and well-tested. One correctness gap remains: tag execution can create a tracking comment before the automatic security “run once” logic, leaving a misleading “running a security check” message even when security is skipped. |
Replace the review-specific marker with a generic PR validation marker carrying an explicit source value for future validation comment types. Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
Resolve a typed run identity before tracking comments are created, pass it through each mode and MCP server, and derive PR validation metadata independently of comment presentation. Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
Check automatic security run-once state before creating the tracking comment. Skip comment creation for security-only no-op runs and downgrade dual-review comments when security will not run. Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
Replace the single-value validation source with exact run-type metadata. Mark code review, security review, and full security scan comments while keeping fill and CI Steward outside the PR validation marker. Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
Add a dedicated droid-default run type for bare @droid commands and return null when no command or automatic mode identifies a run. Propagate unresolved runs without exporting or marking a false review identity. Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
DroidRunTypeenum for default, review, security review, fill, full security scan, and CI Steward runs@droidcommand asdroid-defaultand leave the run typenullwhen no command or automatic mode identifies one<!-- factory-pr-validation: run-type=droid-review -->Why
GitHub issue comments do not retain structured metadata linking them to the workflow or validation that created them. The hidden PR validation marker lets downstream consumers identify the exact originating run type without coupling classification to presentation-oriented comment text.
Reviewer notes
The action derives the marker from its trusted
DroidRunTyperather than accepting it from model output. The comment server restores it after sanitization, so arbitrary HTML comments remain stripped and the trusted marker survives every update. ExistingCommentTypevalues and user-facing status messages remain presentation-only.The emitted marker values are:
run-type=droid-defaultrun-type=droid-reviewrun-type=droid-security-reviewrun-type=droid-security-scanWhen no command is parsed and neither automatic mode applies, run-type resolution returns
null; no run type is exported or added to the marker.Automatic security reviews now check the existing security summary before creating a tracking comment. A security-only no-op creates no comment, while a combined run that skips security creates a code-review-only comment.
Testing
npx --yes bun@1.2.11 test(599 passed)npm run typechecknpm run format:check