go-ipld-prime
go-ipld-prime copied to clipboard
Golang interfaces for the IPLD Data Model, with core Codecs included, IPLD Schemas support, and some handy functional transforms tools.
The current `traversal/selector` package works, but I think at this point, after seeing how users interact with it (and what confuses them), we could make some changes that would make...
Hello! For go graphsync, we need to be able to pause a selector traversal at a block boundary and come back to it later. Currently, we deal with this by...
That is, returning an empty set from `Selector.Interests()` currently means "all". There's no way to say "don't explore any sub-paths". https://github.com/ipld/go-ipld-prime/blob/4acc5447a2efc98fa91a2396c43f570299b4a782/traversal/selector/selector.go#L84-L88
Take Unions, for instance: https://github.com/ipld/go-ipld-prime/blob/75dcac7542945f0b3a5b86d625f989974cfa031c/schema/kind.go#L101-L102 "Any" has a similar problem; it "acts like" anything, so we can't return a single kind. And its representation behavior is simiarly unknown. See https://github.com/ipld/go-ipld-prime/pull/324#discussion_r780788448....
Code generation distinguishes basic and user-defined types. Currently the distinction is accomplished with an indexing hack https://github.com/ipld/go-ipldtool/pull/3/files#diff-32f293a9eaeb1ef73860917a7716464927af787a5e6ac54a034c6697793a34aeR245
Graphsync uses selectors but is primarily focused on the block layer -- all of it's communication is based on intercepting BlockReadOpener functions. Moreover, Graphsync wants to be able to stop...
Right now we end up generating `[]uint8`, which is identical, but also misleading.
The implementation at https://github.com/ipld/go-ipld-prime/blob/e39d20bf18dcc21a50ef2005bae6de11e5c311e0/schema/gen/go/genStructReprTuple.go#L13 says they are allowed as trailing fields: > // Optional fields for tuple representation are only allowed at the end, and contiguously. However, the current spec...
For instance, we implement ordered maps in the form of: ``` struct { Keys []K Values map[K]V } ``` These containers are precisely what generics is good at. For instance,...
The following code compiles, and will panic in a confusing way: proto := bindnode.Prototype(schemaType, nil) The right way to supply a schema type and infer the Go type is: proto...