even numbers should be easy upgrades; odd numbers may change things
The only major, potentially disruptive change in this release is a bump to Go 1.18.
π Breaking Changes
Update go.mod to Go 1.18.
π¦ Highlights
Codecs: Correct JSON codec Bytes handling. This change does not impact DAG-JSON, which is the generally recommended codec for JSON output as the JSON codec cannot properly handle Bytes or Links.
even numbers should be easy upgrades; odd numbers may change things
So, as an even number, this v0.18.0 release should be a smooth ride for upgraders from v0.17.0. We have 3 major feature additions, all focused on Bindnode.
π¦ Highlights
Bindnode: Custom Go type converters - Bindnode performs bidirectional mapping of Go types to the IPLD Data Model, and in doing so, it assumes a straightforward mapping of values to their encoded forms. But there are common cases where a Go type doesn't have a straightforward path to serialization, either because the encoded form needs a custom layout, or because bindnode doesn't have enough information to infer a serialization pattern. Custom Go type converters for bindnode allow a user to supply a pair of converter functions for a Go type that dictate how to map that type to an IPLD Data Model kind. See the bindnode documentation for more information.
Bindnode: Type registry - Setting up Go type mappings with Bindnode involves some boilerplate. A basic type registry is now available that takes some of this boilerplate away; giving you a single place to register, and perform conversions to and from Go types, Data Model (Node) forms or directly through serialization. See the bindnode/registry documentation for more information.
Bindnode: Full uint64 support - the uint64 support introduced in go-ipld-prime@v0.17.0 has been wired into Bindnode. The Data Model (Node) forms expose integers as int64 values, which is lossy for unsigned 64-bit integers. Bindnode Go types using uint64 values are now lossless in round-trips through serialization to codecs that support the full range (DAG-CBOR most notably).
You can see all of these new features in action using Filecoin Go types, allowing a mapping between Go types, Data Model (Node) forms, and their DAG-CBOR serialized forms with data-transfer vouchers. These features also allow us to interact with the original Go types, without modification, including big.Int serialization to Bytes, Filecoin Signature serialization to a byte-prefix discriminated Bytes and more. Since the Go types are unchanged, they can also simultaneously support cbor-gen serialization, allowing an easier migration path.
v0.17.0
go-ipld-prime's release policy says that:
even numbers should be easy upgrades; odd numbers may change things
In that spirit, this v0.17.0 release includes some potentially breaking changes. Although minor, they are marked below and they may lead to behavioral changes in your use of this library.
π Breaking Changes
Codecs:
DAG-CBOR, DAG-JSON: Error on cid.Undef links in dag{json,cbor} encoding - previously, encoding Link nodes that were empty CIDs (uninitialized zero-value or explicitly cid.Undef) would have passed through the DAG-CBOR or DAG-JSON codecs, silently producing erroneous output that wouldn't successfully pass back through a decode. (Rod Vagg)
Bindnode:
Panic early if API has been passed ptr-to-ptr - previous usage of bindnode using pointers-to-pointers may have deferred (or in some cases avoided) panics until deeper usage of the API, this change makes it earlier to make it clear that pointer-to-pointer is not appropriate usage. (Rod Vagg)
Note also that in this release, the github.com/ipfs/go-cid dependency is upgraded from 0.0.4 to 0.2.0 which includes a breaking change with the removal of the cid.Codecs and cid.CodecToStr maps which may disruptive. See the go-cid@0.2.0 release page for details.
even numbers should be easy upgrades; odd numbers may change things
The major change in this release is a bump to Go 1.18.
π Breaking Changes
Update go.mod to Go 1.18.
π¦ Highlights
Codecs: Correct JSON codec Bytes handling. This change does not impact DAG-JSON, which is the generally recommended codec for JSON output as the JSON codec cannot properly handle Bytes or Links.
even numbers should be easy upgrades; odd numbers may change things
So, as an even number, this v0.18.0 release should be a smooth ride for upgraders from v0.17.0. We have 3 major feature additions, all focused on Bindnode.
π¦ Highlights
Bindnode: Custom Go type converters - Bindnode performs bidirectional mapping of Go types to the IPLD Data Model, and in doing so, it assumes a straightforward mapping of values to their encoded forms. But there are common cases where a Go type doesn't have a straightforward path to serialization, either because the encoded form needs a custom layout, or because bindnode doesn't have enough information to infer a serialization pattern. Custom Go type converters for bindnode allow a user to supply a pair of converter functions for a Go type that dictate how to map that type to an IPLD Data Model kind. See the bindnode documentation for more information.
Bindnode: Type registry - Setting up Go type mappings with Bindnode involves some boilerplate. A basic type registry is now available that takes some of this boilerplate away; giving you a single place to register, and perform conversions to and from Go types, Data Model (Node) forms or directly through serialization. See the bindnode/registry documentation for more information.
BindnodeFull uint64 support - the uint64 support introduced in go-ipld-prime@v0.17.0 has been wired into Bindnode. The Data Model (Node) forms expose integers as int64 values, which is lossy for unsigned 64-bit integers. Bindnode Go types using uint64 values are now lossless in round-trips through serialization to codecs that support the full range (DAG-CBOR most notably).
You can see all of these new features in action using Filecoin Go types, allowing a mapping between Go types, Data Model (Node) forms, and their DAG-CBOR serialized forms with data-transfer vouchers. These features also allow us to interact with the original Go types, without modification, including big.Int serialization to Bytes, Filecoin Signature serialization to a byte-prefix discriminated Bytes and more. Since the Go types are unchanged, they can also simultaneously support cbor-gen serialization, allowing an easier migration path.
v0.17.0
2022 Jun 15
go-ipld-prime's release policy says that:
even numbers should be easy upgrades; odd numbers may change things
In that spirit, this v0.17.0 release includes some potentially breaking changes. Although minor, they are marked below and they may lead to behavioral changes in your use of this library.
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.
Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the [Security Alerts page](https://github.com/filecoin-shipyard/js-lotus-client-schema/network/alerts).
Bumps github.com/ipld/go-ipld-prime from 0.14.4 to 0.19.0.
Release notes
Sourced from github.com/ipld/go-ipld-prime's releases.
... (truncated)
Changelog
Sourced from github.com/ipld/go-ipld-prime's changelog.
... (truncated)
Commits
ac99fc3
Prepare v0.19.0146d1c8
fix: correct json codec links & bytes handling7548eb8
build(deps): bump github.com/google/go-cmp from 0.5.8 to 0.5.9 (#468)4b84deb
build(deps): bump github.com/ipfs/go-cid from 0.3.0 to 0.3.2 (#466)a007538
build(deps): bump github.com/ipfs/go-cid in /storage/bsadapter (#465)6c3aeea
build(deps): bump github.com/ipfs/go-cid in /storage/bsrvadapter (#464)8fd3dea
test(basicnode): increase test coverage for int and map types (#454)e57582f
build(deps): bump github.com/ipfs/go-cid in /storage/bsrvadapter8572ef0
build(deps): bump github.com/ipfs/go-cid in /storage/bsadaptere23acb3
build(deps): bump github.com/ipfs/go-cid from 0.2.0 to 0.3.0Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting
@dependabot rebase
.Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) You can disable automated security fix PRs for this repo from the [Security Alerts page](https://github.com/filecoin-shipyard/js-lotus-client-schema/network/alerts).