Skip to content

Comments

Add YAML parsing support to mappings#1935

Merged
isum merged 4 commits intomainfrom
ion/add-yaml-support
Feb 11, 2025
Merged

Add YAML parsing support to mappings#1935
isum merged 4 commits intomainfrom
ion/add-yaml-support

Conversation

@isum
Copy link
Member

@isum isum commented Jan 31, 2025

This PR adds type definitions for two host functions that parse YAML documents and defines some helper methods to make working with YAML types nicer.

The main use case for this feature is to parse subgrah manifests, but it is flexible enough to allow parsing any YAML document.

Part of graphprotocol/graph-node#5772
Host functions are implemented in graphprotocol/graph-node#5785

@isum isum self-assigned this Jan 31, 2025
@changeset-bot
Copy link

changeset-bot bot commented Jan 31, 2025

🦋 Changeset detected

Latest commit: 802768a

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@graphprotocol/graph-ts Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions
Copy link
Contributor

github-actions bot commented Jan 31, 2025

🚀 Snapshot Release (alpha)

The latest changes of this PR are available as alpha on npm (based on the declared changesets):

Package Version Info
@graphprotocol/graph-cli 0.96.0-alpha-20250211183825-802768a7b811892d1c945e88491926e436413436 npm ↗︎ unpkg ↗︎
@graphprotocol/graph-ts 0.38.0-alpha-20250211183825-802768a7b811892d1c945e88491926e436413436 npm ↗︎ unpkg ↗︎

@isum isum force-pushed the ion/add-yaml-support branch from 59f799f to 564b43c Compare January 31, 2025 18:54
@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Jan 31, 2025

Deploying graph-tooling with  Cloudflare Pages  Cloudflare Pages

Latest commit: 802768a
Status: ✅  Deploy successful!
Preview URL: https://4a91756e.graph-tooling.pages.dev
Branch Preview URL: https://ion-add-yaml-support.graph-tooling.pages.dev

View logs

@isum isum force-pushed the ion/add-yaml-support branch 2 times, most recently from 46c291a to 12864a4 Compare January 31, 2025 19:11
@isum isum marked this pull request as ready for review January 31, 2025 19:23
@YaroShkvorets
Copy link
Collaborator

Thanks for the PR. Can you add some unit tests in packages/ts/test/yaml.ts?

@isum isum force-pushed the ion/add-yaml-support branch from 12864a4 to a1920a6 Compare February 10, 2025 18:54
@isum isum force-pushed the ion/add-yaml-support branch from a1920a6 to 99d12e9 Compare February 10, 2025 19:02
@isum
Copy link
Member Author

isum commented Feb 10, 2025

@YaroShkvorets I added tests to the PR

Copy link
Collaborator

@YaroShkvorets YaroShkvorets left a comment

Choose a reason for hiding this comment

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

Added one more test. Looks good.

@isum isum merged commit 0c36a02 into main Feb 11, 2025
9 checks passed
@isum isum deleted the ion/add-yaml-support branch February 11, 2025 18:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants