Conversation
There was a problem hiding this comment.
Pull request overview
Adds additional (normalized) issue hierarchy metadata to the IssueRecord returned by linear-core, allowing JSON consumers to inspect parent/child relationships without additional Linear API calls.
Changes:
- Extend
IssueRecordwithparentTitle,childrenCount, andhasChildren(keepingchildCountfor backwards compatibility). - Populate the new fields in the v2
LinearGatewayissue mapping. - Extend the v2 gateway test assertions to cover the new hierarchy fields.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| packages/linear-core/tests/v2-gateway.test.ts | Adds assertions for parentTitle, childrenCount, and hasChildren in the v2 issue enrichment test. |
| packages/linear-core/src/entities/models.ts | Extends the IssueRecord public shape with the new hierarchy metadata fields. |
| packages/linear-core/src/entities/linear-gateway.ts | Populates the new hierarchy fields when converting SDK issues into IssueRecord. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Avoid recomputing children.length three times; keep childCount/childrenCount/hasChildren from drifting.
|
🎉 This PR is included in version 1.5.0-alpha.3 🎉 The release is available on: Your semantic-release bot 📦🚀 |
|
🎉 This PR is included in version 1.5.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
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.
Summary
Adds normalized issue hierarchy metadata so JSON consumers can inspect parent and child relationships without an extra Linear API call.
The issue record now includes
parentTitle,childrenCount, andhasChildrenalongside the existing parent and child fields, preservingchildCountfor backward compatibility.The v2 gateway test now covers the new hierarchy fields.
Validation
pnpm verify