Skip to content

Incorporate #317: factor validation into a reusable validate-task.yml - #320

Merged
ptr727 merged 3 commits into
developfrom
incorporate-317-validate-task
Jul 16, 2026
Merged

Incorporate #317: factor validation into a reusable validate-task.yml#320
ptr727 merged 3 commits into
developfrom
incorporate-317-validate-task

Conversation

@ptr727

Copy link
Copy Markdown
Owner

Incorporates #317 (filed from the Financial-Modeling standup): the template's publisher carried no pre-release validation gate because the PR lint was inlined - the reference could not express the gate the spec (and Financial-Modeling#14's acceptance criteria) require, forcing downstream divergence from the verbatim carry.

Changes

  • validate-task.yml (new, workflow_call) - the lint job moves verbatim; the file/name shape matches the downstream validate-task.yml pattern so carries align.
  • test-pull-request.yml - the validate job uses: the task. The ruleset-bound aggregator keeps its exact name (Check pull request workflow status job binds by name and stays an inline job); its needs:/result checks point at validate.
  • publish-release.yml - gains validate (same reusable task) and publish.needs: [validate]: a manual dispatch can no longer cut a release from a ref that fails validation.
  • WORKFLOW.md source-only walkthrough states the gate, so the spec and the reference implementation agree and the next downstream re-sync is byte-for-byte.

Validation

  • actionlint clean; workflow YAML LF; ruleset-bound check context unchanged.

Closes#317 (fires on promotion).

🤖 Generated with Claude Code

ptr727and others added 2 commits July 16, 2026 07:51
The publisher carried no validation gate because the PR lint was inlined -
the reference could not express the pre-release gate the spec (and the
Financial-Modeling #14 criteria) require. validate-task.yml (workflow_call)
is now called by test-pull-request (aggregator unchanged - the ruleset-bound
check keeps its name) and by publish-release (publish needs: validate, so a
dispatch cannot release a ref that fails validation). WORKFLOW.md source-only
walkthrough states the gate.
Closes#317 (keyword fires on promotion).
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
CopilotAI review requested due to automatic review settings July 16, 2026 15:03

CopilotAI 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.

Pull request overview

Factors the repo’s lint/validation logic into a reusable workflow so both PR validation and manual release dispatches share the same single validation gate, aligning the template with the spec/acceptance criteria from #317.

Changes:

  • Adds a reusable .github/workflows/validate-task.yml (workflow_call) that encapsulates the existing lint/validation steps.
  • Updates test-pull-request.yml to call the reusable validation task while keeping the ruleset-bound aggregator job name unchanged.
  • Updates publish-release.yml to run validation before publishing, and documents the gate in WORKFLOW.md.

Reviewed changes

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

FileDescription
.github/workflows/validate-task.ymlNew reusable validation workflow that centralizes lint/spec validation steps.
.github/workflows/test-pull-request.ymlReplaces the inline lint job with a call to the reusable validate task; aggregator now depends on validate.
.github/workflows/publish-release.ymlAdds a validate job and gates publish on it so dispatch releases cannot bypass validation.
WORKFLOW.mdUpdates the source-only walkthrough to explicitly describe the dispatch publisher’s validation gate.

Comment thread.github/workflows/validate-task.yml Outdated
Comment thread.github/workflows/validate-task.yml Outdated
Comment thread.github/workflows/validate-task.yml Outdated
Comment thread.github/workflows/publish-release.yml Outdated
Collapse the moved/new workflow comments to single lines per comment hygiene,
and add --pull=always to the editorconfig-checker invocation to match the
canonical lint command.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
CopilotAI review requested due to automatic review settings July 16, 2026 15:08

CopilotAI 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.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated no new comments.

Comments suppressed due to low confidence (1)

.github/workflows/publish-release.yml:30

  • Because publish now gates on validate, both jobs should operate on the same commit SHA. Currently the publish job checks out ref: ${{ github.ref_name }} (a moving branch ref), so if new commits land after the workflow starts, validate can pass on the original github.sha while publish releases a newer, unvalidated commit. Pin the publish checkout to github.sha so the validated ref and released commit always match.
 needs: [ validate ]
permissions:
contents: write
steps:

@ptr727
ptr727 merged commit 50ab249 into developJul 16, 2026
7 checks passed
@ptr727
ptr727 deleted the incorporate-317-validate-task branch July 16, 2026 15:11
ptr727 added a commit that referenced this pull request Jul 16, 2026
…321)
Promotes #320 (the #317 incorporation): validation factored into a
reusable validate-task.yml, called by the PR workflow (ruleset-bound
aggregator unchanged) and by publish-release, so a manual dispatch
cannot cut a release from a ref that fails validation. WORKFLOW.md
source-only walkthrough states the gate.
Closes#317.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Sign up for freeto 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

@ptr727