Fork me on GitHub

I guess this is a bug with the new planner or dynamic resolver


just in case, can you please try on the latest SHA on the query-planner branch? I've been doing some fixes this week.


but Im not 100% on the current way the new planner handles placeholders, so reports like this are very welcome 🙏


@U066U8JQJ just tested on latest commit, the issue remains. Also, it's not about placeholders. It's in a normal branch. I tried to remove the placeholders, too.


one thing I noticed, the resolvers you are adding with pc/add, they are just ending as regular resolvers, so they are not working as dynamic things, for them to be dynamic you need to point to the real dynamic resolver using ::pc/dynamic-sym, like foreign does


also, be careful around that, the resolvers around dynamic, they do not work like regular resolvers


they are aid resolvers to help the dynamic resolver figures itself, I surely have to document this better, but I myself need to play and figure them better too


just keep in mind, they are different things with different expectations


@U066U8JQJ I only leveraged pc/add to build the indexes, after that I use mergeto override the resolver with :pc/dynamic-resolver? true


is that enough?


what I'm pointing is not the dynamic resolver itself, but the "children resolver" of that dynamic resolver


so, the resolvers that are intended to help a dynamic reoslver, they need to have a ::pc/dynamic-sym (different from ::pc/dynamic-resolver?) that points to the dynamic resolver


its easy to imagine this in the foreign context, where all resolvers that are foreign (from a separated parser) should point to the dynamic resolver that calls that parser


they are used to decide how to call the foreign, but they are never part of the execution graph themselves, and to pathom understand that they need to point to the dynamic resolver they are assisting, makes sense?


let me see, still trying to process 😉


why don't I see this dynamic-sym`` thing in pathom-datomic?


because the datomic is simple enough it doesnt need one, datomic is just too regular 🙂


if you see, the datomic only has the dynamic resolver, it doesn't have any "assistent resolvers"


graphql will require some


what are the input and output of an assistant resolver?


I still don't see why (and where) I should add dynamic-sym to the gist link (it's basically me mimicking pathom-datomic, but too lazy to type the indexes so I use p/add)


so, seems like you are trying to ray-trace how to make it work, which will be dificult IMO, the pathom-datomic is the simplest dynamic resolver that I can imagine, because datomic is very consistent across relationships (any entity can use any property of the schema, very consistent)


in your case, its not going to be so much


the need for assistent resolvers is so pathom can understand how to compute nested queries to send to the dynamic resolver (reducing number of calls), because of the nature of deep queries, this defintion can't be done in a single place, and may require multiple passes to figure what to send, that's were the assistent resolvers come, they serve as instructions of what is available at some specific context for that dynamic resolver


that said, I didn't made any other implementation on this expect for the foreign-parser thing


the way to use this for other types of dynamic resolvers is unclear at this point


I hope to get more docs around that in the next month, but right now I'm focusing on tooling and more on the user side of the story (not the extension side for developers of dynamic resolvers, yet)


sorry its so confusing, its just you are a very early adopter of something that still work in progress 😛


I believe this will be more figure out when I sit and stop to do the new GraphQL integration, that's the one closest to what you are trying to do


well, I guess I did it wrong when I tried to port walkable to planner/dynamic by mimicking datomic. It's working now, but I think the resolver is doing too much right now. I guess some assistant should be extracted instead. I will try that


Thank you so much for all these nice things 😄

🙏 4