Skip to content

chore: Stop emitting pr/issue-ref-missing and pr/title-not-capitalised labels#6

Open
johnxie wants to merge 1 commit into
mainfrom
chore/disable-issue-ref-and-capitalisation-labels
Open

chore: Stop emitting pr/issue-ref-missing and pr/title-not-capitalised labels#6
johnxie wants to merge 1 commit into
mainfrom
chore/disable-issue-ref-and-capitalisation-labels

Conversation

@johnxie
Copy link
Copy Markdown
Member

@johnxie johnxie commented Jun 6, 2026

What

Stops the PR Assistant from adding two advisory-only title labels:

  • pr/issue-ref-missing :hash: (#️⃣)
  • pr/title-not-capitalised :a: (🅰️)

Both rules now always push to labelsToRemove, so the labels are never added again and existing PRs self-clean on their next pull_request event. The other three title checks (type-missing, title-has-ending-period, feat-fix-no-scope) are unchanged.

Why

Verified across all of taskade/taskcade's .github/workflows: these two labels have zero downstream automation — they gate nothing, trigger no deploy/merge. Pure visual noise on the PR list.

Notes on the build

lib/index.js is the committed artifact the action actually runs, so it is updated in this PR. The pinned @vercel/ncc@0.28.6 toolchain no longer bundles cleanly in current environments (node: import scheme + OpenSSL-3 ERR_OSSL_EVP_UNSUPPORTED), so lib/index.js was hand-patched to mirror the source change exactly — the edit is a literal unconditional labelsToRemove.push(...). Verified: grep shows 0 add-rules / 2 remove-rules for these labels, and node --check lib/index.js passes.

Verification

  • src/verifyPRTitle.ts + lib/index.js diffs match
  • node --check lib/index.js passes
  • grep confirms no labelsToAdd for the two labels remain

…d labels

These two title labels are advisory-only noise (zero downstream automation in
taskcade — verified). Convert both rules to always push to labelsToRemove so the
labels are never added again and existing PRs self-clean on the next PR event.
The other three title checks (type-missing, ending-period, feat-fix-no-scope)
are unchanged.

lib/index.js is hand-patched to mirror the source change because the pinned
@vercel/ncc 0.28.6 toolchain no longer bundles in current envs (node: scheme +
OpenSSL3); the change is a literal unconditional push, verified by grep + node --check.
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR disables two advisory PR-title labeling rules by ensuring the action only removes (and never adds) the labels pr/issue-ref-missing and pr/title-not-capitalised, including in the committed lib/index.js artifact.

Changes:

  • Disable “missing issue reference” labeling by always pushing ISSUE_REFERENCE_MISSING to labelsToRemove.
  • Disable “title not capitalised” labeling by pushing TITLE_NOT_CAPITALISED to labelsToRemove (currently only when parsed.subject != null).
  • Apply the same behavior to the compiled lib/index.js artifact.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
src/verifyPRTitle.ts Disables two title-labeling checks by removing the “add label” paths.
lib/index.js Mirrors the source change in the shipped action artifact.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/verifyPRTitle.ts
Comment on lines 38 to +41
// Subject
if (parsed.subject != null) {
// Capitalisation
const firstChar = parsed.subject.slice(0, 1);

if (firstChar !== firstChar.toUpperCase()) {
result.labelsToAdd.push(TitleLabel.TITLE_NOT_CAPITALISED);
} else {
result.labelsToRemove.push(TitleLabel.TITLE_NOT_CAPITALISED);
}
// Capitalisation — check disabled; always clear the label so existing PRs self-clean
result.labelsToRemove.push(TitleLabel.TITLE_NOT_CAPITALISED);
Comment thread lib/index.js
Comment on lines 309 to +312
// Subject
if (parsed.subject != null) {
// Capitalisation
const firstChar = parsed.subject.slice(0, 1);
if (firstChar !== firstChar.toUpperCase()) {
result.labelsToAdd.push(TitleLabel.TITLE_NOT_CAPITALISED);
}
else {
result.labelsToRemove.push(TitleLabel.TITLE_NOT_CAPITALISED);
}
// Capitalisation — check disabled; always clear the label so existing PRs self-clean
result.labelsToRemove.push(TitleLabel.TITLE_NOT_CAPITALISED);
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.

2 participants