Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Dec 10, 2025

Plan: Map metadata from issue templates to NewIssue.md

  • Understand current implementation

    • Review issue template parsing in getDataFromTemplate
    • Review IssueTemplate interface in util.ts
    • Review NewIssueFileOptions interface in issueFile.ts
    • Review makeNewIssueFile method in issueFeatureRegistrar.ts
    • Review template selection in createIssue method
  • Implement changes to support labels and assignees in templates

    • Extend IssueTemplate interface to include labels and assignees
    • Update getDataFromTemplate method to parse labels and assignees from YAML frontmatter
    • Extend NewIssueFileOptions interface to include labels
    • Update createIssue method to pass template labels and assignees to options
    • Update makeNewIssueFile method to populate labels line with template labels
    • Update chooseTemplate return type to use IssueTemplate
    • Fix parseYamlTemplate to extract labels and assignees from YAML templates
  • Test the changes

    • Build the extension
    • Test YAML parsing for different formats
  • Run code review and security checks

    • Run code_review tool - No issues found
    • Run codeql_checker tool - No alerts found
    • Address feedback from @alexr00 about YAML parsing

Security Summary

No security vulnerabilities were discovered during the CodeQL security scan.

Original prompt

This section details on the original issue you should resolve

<issue_title>Map metadata from issue templates to NewIssue.md</issue_title>
<issue_description>

I have issue templates with metadata, e.g.:

---
name: Bug report
about: Report a bug, help us improve
title: A clear title describing the bug from a user's perspective
labels: bug, needs triage
assignees: username
---

[...some body...]

When I create a new issue using this template, the title is brought through, but the rest of the metadata is not included.

I.e. this is the generated NewIssue.md:

A brief title describing the bug from a user's perspective

Assignees: 
Labels: 
Milestone: 
Projects:

[...some body...]

Would be great to populate the metadata fields based on the issue template!</issue_description>

Comments on the Issue (you are @copilot in this section)


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Copy link
Member

@alexr00 alexr00 left a comment

Choose a reason for hiding this comment

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

@copilot The issue template is yml, which means we end up with extra yml characters like this:

Assignees: @- alexr000 
Labels: ["bug", "triage"] 

Copy link
Contributor Author

Copilot AI commented Dec 17, 2025

@copilot The issue template is yml, which means we end up with extra yml characters like this:

Assignees: @- alexr000 ...

Fixed in 394a879. The parseYamlTemplate method now extracts labels and assignees from YAML issue templates as proper arrays, avoiding the extra YAML characters in the NewIssue.md output.

Copilot AI requested a review from alexr00 December 17, 2025 15:04
@alexr00 alexr00 marked this pull request as ready for review December 17, 2025 15:28
@alexr00 alexr00 enabled auto-merge (squash) December 17, 2025 15:28
@vs-code-engineering vs-code-engineering bot added this to the December / January 2026 milestone Dec 17, 2025
@alexr00 alexr00 merged commit 9934ff2 into main Dec 17, 2025
6 checks passed
@alexr00 alexr00 deleted the copilot/map-metadata-to-newissue-md branch December 17, 2025 15:52
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.

Map metadata from issue templates to NewIssue.md

3 participants