Skip to content

Fix VBD Analysis workflow root npm package resolution - #8

Merged
visionarycoder merged 13 commits into
mainfrom
copilot/fix-github-actions-job-102940536472
Sep 10, 2026
Merged

visionarycoder merged 13 commits into
mainfrom
copilot/fix-github-actions-job-102940536472

Conversation

Copilot AI commented Sep 10, 2026 •

Copy link
Copy Markdown
Contributor

The VBD Analysis Validation workflow was invoking npm run from the repository root even when no root package.json existed, causing npm ENOENT in job 102940536472. This change makes the workflow explicitly validate and use the repository-level Node package context instead of assuming it.

  • Workflow scope

    • Restore/update .github/workflows/vbd-analysis.yml on this branch.
    • Keep the workflow focused on repository-level VBD/frontmatter/solution validation.
  • Root package detection

    • Check only the repository-root package.json.
    • Distinguish between:
      • no root manifest
      • invalid root manifest
      • missing required validation scripts
  • Deterministic npm execution

    • Require a root package-lock.json before running Node-based validation.
    • Run npm ci and all npm run steps from the detected package directory via working-directory.
  • Consistent script gating

    • Apply the same execution guard to:
      • vbd:artifacts:test
      • frontmatter:test
      • solution:markdown:test
      • vbd:analysis:validate
      • frontmatter:validate
      • solution:markdown:check
  • Failure clarity

    • Add explicit workflow steps/messages for:
      • invalid root package.json
      • missing required validation scripts
      • missing root lockfile
    • Skip Node validation cleanly when the repository intentionally has no root Node package.
- name: Install Node dependencies
  if: steps.detect-node-validation.outputs.has_validation_package == 'true' && steps.detect-node-validation.outputs.has_package_lock == 'true'
  working-directory: ${{ steps.detect-node-validation.outputs.package_dir }}
  run: npm ci

- name: Run VBD artifact automation tests
  if: steps.detect-node-validation.outputs.has_validation_package == 'true' && steps.detect-node-validation.outputs.has_package_lock == 'true'
  working-directory: ${{ steps.detect-node-validation.outputs.package_dir }}
  run: npm run vbd:artifacts:test

Copilot AI and others added 11 commits September 10, 2026 15:52
Co-authored-by: visionarycoder <8689814+visionarycoder@users.noreply.github.com>
Co-authored-by: visionarycoder <8689814+visionarycoder@users.noreply.github.com>
Co-authored-by: visionarycoder <8689814+visionarycoder@users.noreply.github.com>
Co-authored-by: visionarycoder <8689814+visionarycoder@users.noreply.github.com>
Co-authored-by: visionarycoder <8689814+visionarycoder@users.noreply.github.com>
Co-authored-by: visionarycoder <8689814+visionarycoder@users.noreply.github.com>
Co-authored-by: visionarycoder <8689814+visionarycoder@users.noreply.github.com>
Co-authored-by: visionarycoder <8689814+visionarycoder@users.noreply.github.com>
Co-authored-by: visionarycoder <8689814+visionarycoder@users.noreply.github.com>
Co-authored-by: visionarycoder <8689814+visionarycoder@users.noreply.github.com>
Co-authored-by: visionarycoder <8689814+visionarycoder@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix failing GitHub Actions job for VBD analysis validation Fix VBD Analysis workflow root npm package resolution Sep 10, 2026
@visionarycoder

Copy link
Copy Markdown
Owner

@copilot resolve the merge conflicts in this pull request

@visionarycoder

Copy link
Copy Markdown
Owner

@copilot resolve the merge conflicts in this pull request

…tions-job-102940536472

# Conflicts:
#	.github/workflows/vbd-analysis.yml

Co-authored-by: visionarycoder <8689814+visionarycoder@users.noreply.github.com>

Copilot AI commented Sep 10, 2026

Copy link
Copy Markdown
Contributor Author

@copilot resolve the merge conflicts in this pull request

Resolved the merge conflict and committed the merge as a70cdf1.

Copilot AI commented Sep 10, 2026

Copy link
Copy Markdown
Contributor Author

@copilot resolve the merge conflicts in this pull request

Already resolved in a70cdf1. The branch is currently conflict-free.

@visionarycoder
visionarycoder marked this pull request as ready for review September 10, 2026 18:31
Copilot AI lite review requested due to automatic review settings September 10, 2026 18:31
@visionarycoder
visionarycoder merged commit b16fb05 into main Sep 10, 2026
5 checks passed

Copilot AI 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.

🟢 Approval recommended

The workflow changes correctly gate all npm steps on a valid root package.json plus package-lock.json and improve failure clarity without introducing inconsistent conditions.

Pull request overview

Updates the VBD Analysis Validation GitHub Actions workflow to reliably run Node-based VBD/frontmatter/solution checks only when a valid repository-root Node package (with required scripts and lockfile) is present.

Changes:

  • Adds package-lock.json to the workflow path filters so lockfile changes trigger validation.
  • Detects and validates the repository-root package.json (valid JSON + required scripts) and fails with explicit messages when invalid/misconfigured.
  • Requires a root package-lock.json, runs npm ci, and executes all npm run validations from the detected package directory via working-directory.
File summaries
File Description
.github/workflows/vbd-analysis.yml Adds root package/lockfile detection and deterministic npm execution gating for all Node-based validation steps.
Review details
  • Files reviewed: 1/1 changed files
  • Comments generated: 0
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

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.

3 participants