Conversation
… field Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot created this pull request from a session on behalf of
pelikhan
March 14, 2026 21:32
View session
pelikhan
reviewed
Mar 14, 2026
| @@ -32,17 +32,14 @@ async function generateWorkflowOverview(core) { | |||
| "<details>\n" + | |||
| "<summary>Run details</summary>\n\n" + | |||
Contributor
There was a problem hiding this comment.
- show engine_id and version in summary
- show all fields in rendered markdown by rendering all files from aw_info.json using a javascript helper (look for existing json object to markdown helper)
Contributor
Author
There was a problem hiding this comment.
Done in 3c922a6:
- The
<summary>tag now includesengine_idandversion, e.g.Run details - copilot v1.2.3 - Created a new
json_object_to_markdown.cjshelper that converts any JS object to a Markdown bullet list (handles nested objects, arrays, primitives, empty values) generate_workflow_overview.cjsnow uses this helper to render all fields fromaw_info.json— nothing is omitted
…s via json_object_to_markdown helper Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot
AI
changed the title
Improve run details step summary: bullet points + aw version
Improve run details step summary: bullet points, aw version, and full aw_info rendering
Mar 14, 2026
Contributor
|
@copilot humanify key in json to markdown (replace -_ with whitespace) |
…spaces) Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Contributor
Author
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the GitHub Actions step summary for workflow “Run details” to use a bullet-list rendering of aw_info.json, and includes engine/version in the <summary> label.
Changes:
- Added
json_object_to_markdown.cjshelper to render arbitrary objects as nested Markdown bullet lists (with key humanification). - Refactored
generate_workflow_overview.cjsto render the fullaw_info.jsonpayload via the helper and includeengine_id/versionin the collapsible summary label. - Updated and added Vitest coverage to assert the new summary format and helper behavior.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| actions/setup/js/json_object_to_markdown.cjs | New helper to convert objects/arrays/primitives into nested Markdown bullet lists. |
| actions/setup/js/json_object_to_markdown.test.cjs | New unit tests for key humanification and markdown rendering behaviors. |
| actions/setup/js/generate_workflow_overview.cjs | Switches step summary rendering from tables to bullet lists and updates <summary> label. |
| actions/setup/js/generate_workflow_overview.test.cjs | Updates assertions to match the new summary label and bullet-list rendering. |
Comments suppressed due to low confidence (1)
actions/setup/js/json_object_to_markdown.cjs:72
- Empty objects currently render as a label line followed by an empty string (e.g., "- key:" with nothing under it) because the recursive call can return "" and is still appended. It would be clearer to render empty objects as "(none)" (or skip them) and avoid pushing empty lines into the output.
} else if (typeof value === "object" && value !== null) {
lines.push(`${indent}- **${label}**:`);
lines.push(jsonObjectToMarkdown(/** @type {Record<string, unknown>} */ value, depth + 1));
} else {
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
You can also share your feedback on Copilot code review. Take the survey.
Comment on lines
+61
to
+66
| for (const item of value) { | ||
| if (typeof item === "object" && item !== null) { | ||
| lines.push(jsonObjectToMarkdown(/** @type {Record<string, unknown>} */ item, depth + 1)); | ||
| } else { | ||
| lines.push(`${" ".repeat(depth + 1)}- ${String(item)}`); | ||
| } |
Comment on lines
+21
to
+29
| // Build the collapsible summary label with engine_id and version | ||
| const engineLabel = [awInfo.engine_id, awInfo.version].filter(Boolean).join(" "); | ||
| const summaryLabel = engineLabel ? `Run details - ${engineLabel}` : "Run details"; | ||
|
|
||
| // Render all aw_info fields as markdown bullet points | ||
| const details = jsonObjectToMarkdown(awInfo); | ||
|
|
||
| // Build summary using string concatenation to avoid YAML parsing issues with template literals | ||
| const summary = | ||
| "<details>\n" + | ||
| "<summary>Run details</summary>\n\n" + | ||
| "#### Engine Configuration\n" + | ||
| "| Property | Value |\n" + | ||
| "|----------|-------|\n" + | ||
| `| Engine ID | ${awInfo.engine_id} |\n` + | ||
| `| Engine Name | ${awInfo.engine_name} |\n` + | ||
| `| Model | ${awInfo.model || "(default)"} |\n` + | ||
| "\n" + | ||
| "#### Network Configuration\n" + | ||
| "| Property | Value |\n" + | ||
| "|----------|-------|\n" + | ||
| `| Firewall | ${awInfo.firewall_enabled ? "✅ Enabled" : "❌ Disabled"} |\n` + | ||
| `| Firewall Version | ${awInfo.awf_version || "(latest)"} |\n` + | ||
| "\n" + | ||
| (networkDetails ? `##### Allowed Domains\n${networkDetails}\n` : "") + | ||
| "</details>"; | ||
| const summary = "<details>\n" + `<summary>${summaryLabel}</summary>\n\n` + details + "\n" + "</details>"; |
| "\n" + | ||
| (networkDetails ? `##### Allowed Domains\n${networkDetails}\n` : "") + | ||
| "</details>"; | ||
| const summary = "<details>\n" + `<summary>${summaryLabel}</summary>\n\n` + details + "\n" + "</details>"; |
This was referenced Mar 14, 2026
fix: emit GH_HOST: github.com on Install GitHub Copilot CLI step to prevent GHES host leakage
#20992
Open
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.
The run details step summary used markdown tables, was missing the gh-aw version, and only showed a subset of workflow metadata.
Changes
json_object_to_markdown.cjs(new helper): Converts any plain JavaScript object to a Markdown bullet list. Handles nested objects (indented sub-lists), arrays (sub-bullets or(none)for empty), and primitives (null/""→(none)). Keys are humanified by replacing_and-with spaces (e.g.engine_id→engine id).generate_workflow_overview.cjs: Replaced manual table/bullet construction with the new helper. The<summary>tag now includesengine_idandversion(e.g.Run details - copilot v1.2.3). All fields fromaw_info.jsonare rendered — nothing is omitted.Before
After
generate_workflow_overview.test.cjs: Updated assertions to match the new format (summary label, bullet-point field rendering with humanified keys, nested objects and arrays).json_object_to_markdown.test.cjs(new): 11 unit tests covering flat key-value pairs, booleans, null/empty values, arrays, empty arrays, nested objects, invalid inputs, and key humanification.💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.