Skip to content

Improve skills-validator invoking and outputs presenting#1387

Merged
aaronpowell merged 1 commit intogithub:stagedfrom
JanKrivanek:dev/jankrivanek/improve-output
Apr 14, 2026
Merged

Improve skills-validator invoking and outputs presenting#1387
aaronpowell merged 1 commit intogithub:stagedfrom
JanKrivanek:dev/jankrivanek/improve-output

Conversation

@JanKrivanek
Copy link
Copy Markdown
Contributor

Context

Fixing the skill-validator invocation to prevent invocation errors - e.g.:

  • making the validation output .md structured (currently it's cli formatting)

By submitting this pull request, I confirm that my contribution abides by the Code of Conduct and will be licensed under the MIT License.

Copilot AI review requested due to automatic review settings April 13, 2026 17:20
Copy link
Copy Markdown
Contributor

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

Updates the Skill Validator PR comment workflow to present validator output in a more structured, Markdown-friendly format and to reduce invocation/output-related noise when posting results back to pull requests.

Changes:

  • Sanitizes captured validator output (handles missing output file and strips ANSI color codes).
  • Replaces keyword-based finding counts with emoji-based counts (❌/⚠/ℹ) and adds structured summary tables.
  • Adds a compact “Summary” section plus a <details> block containing the full validator output.
Show a summary per file
File Description
.github/workflows/skill-check-comment.yml Reformats the PR comment body with tables + summary extracted from validator output, and improves output handling/sanitization.

Copilot's findings

  • Files reviewed: 1/1 changed files
  • Comments generated: 1

Comment on lines +70 to +77
const summaryLines = highlightedLines.length > 0
? highlightedLines.slice(0, 10)
: output
.split('\n')
.map(line => line.trim())
.filter(Boolean)
.filter(line => !line.startsWith('###'))
.slice(0, 10);
Copy link

Copilot AI Apr 13, 2026

Choose a reason for hiding this comment

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

summaryLines falls back to the first 10 non-empty lines when no emoji-prefixed findings are detected. Since skill-validator output can include headers/info lines (e.g., "## ") even when there are no findings, this can populate the “Finding” table with non-findings and prevent the “No findings…” message from ever showing. Consider only building the findings table from highlightedLines (emoji-prefixed lines), and when that list is empty (and exitCode === '0'), render the no-findings message instead of a fallback slice of arbitrary output.

Suggested change
const summaryLines = highlightedLines.length > 0
? highlightedLines.slice(0, 10)
: output
.split('\n')
.map(line => line.trim())
.filter(Boolean)
.filter(line => !line.startsWith('###'))
.slice(0, 10);
const summaryLines = highlightedLines.slice(0, 10);

Copilot uses AI. Check for mistakes.
@aaronpowell aaronpowell merged commit dd3bce4 into github:staged Apr 14, 2026
11 of 12 checks passed
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