chyh1990 / yaml-rust

A pure rust YAML implementation.
Apache License 2.0
601 stars 138 forks source link

Allowing tags to be propagated for other events as well #180

Open dchakrav-github opened 2 years ago

dchakrav-github commented 2 years ago

This change is need to support https://github.com/dtolnay/serde-yaml/pull/220. It provides the needed propagation of tags for SequenceStart and MappingStart events. This allows consumers of these events using MarkedEventReceiver or EventReceiver to take advantage of the tags to reason mapping.

In addition to the usage for serde-yaml show above, a usage when dealing with AWS CloudFormation templates can be seen here.

Please note, this PR did not change the testing to also return events with tags contained as outline in issue #148.

Issues: https://github.com/dtolnay/serde-yaml/issues/147, #147, I believe this also helps address #35 (need more verification here, but the examples provided are both implemented in https://github.com/dtolnay/serde-yaml/pull/220 pull and the CloudFormation provided above)

dchakrav-github commented 2 years ago

Support for Windows-gnu with mingw is not functioning. The tests pass for all other versions. AppVeyor file hasn't changed in 2 years, but the tar is no longer hosted there for clang-9.0 versions.

http://repo.msys2.org/mingw/x86_64/

Current versions supported are >= 10.0.

LLVM_VERSION is at 9.0. Should we up the version to 10 at least? @chyh1990

error: failed retrieving file 'mingw-w64-x86_64-clang-9.0.1-1-any.pkg.tar.xz' from repo.msys2.org : The requested URL returned error: 404
warning: failed to download http://repo.msys2.org/mingw/x86_64/mingw-w64-x86_64-clang-9.0.1-1-any.pkg.tar.xz
error: 'http://repo.msys2.org/mingw/x86_64/mingw-w64-x86_64-clang-9.0.1-1-any.pkg.tar.xz': unexpected error
error: failed retrieving file 'mingw-w64-x86_64-llvm-9.0.1-1-any.pkg.tar.xz' from repo.msys2.org : The requested URL returned error: 404
warning: failed to download http://repo.msys2.org/mingw/x86_64/mingw-w64-x86_64-llvm-9.0.1-1-any.pkg.tar.xz
error: 'http://repo.msys2.org/mingw/x86_64/mingw-w64-x86_64-llvm-9.0.1-1-any.pkg.tar.xz': unexpected error
yuhr commented 2 years ago

What's the status of this PR? I really need this. @dchakrav-github @chyh1990

dchakrav-github commented 2 years ago

@yuhr I am using my forked version of this code here currently to unblock. There is also a pending change to serde_yaml crate that i am unable to release. Currently, there is a appveyor.yml that is failing to run when trying to fetch the correct LLVM/CLANG versions from a location (see build logs) that I am unable to fix. I would like to get this merged. @chyh1990 please let me know what you would need to merge thie change.

akshayrane commented 2 years ago

Hi owners,

Wanted to check with you if there is a way we can prioritize getting this PR merged?

We are AWS CloudFormation team and our release for Guard 2.1 is blocked to be published on crates.io because we need this fix to be implemented in the crate for this repo.

If there are any recommended changes that we'd need to do before we could merge it, please advise and we will work on them.

Appreciate any guidance we could get. Thanks!

Akshay