Fork me on GitHub
#pathom
<
2022-06-21
>
sheluchin16:06:53

I have a request that fails only when A and B are requested together, but works when either A or B are requested. Can anyone suggest how to troubleshoot the problem?

Björn Ebbinghaus16:06:22

What resolvers do you have? How does the Query look like? Have you checked if the output of the resolvers is properly defined?

sheluchin18:06:45

Hmm, that all seems okay to me, but I do notice that when I include both A and B, the RAD DB adapter resolvers are not being run, but when I eliminate either A or B, they do run :thinking_face:

sheluchin14:06:48

I still haven't really figured out why it's happening, but I did figure out that if I request C along with A and B, it all works lol. They should all be accessible simply from :A/id, so all the more confusing.

Björn Ebbinghaus09:06:38

Hm. Sorry, but I don't have a lot of experience as of how RAD generates resolvers.

Björn Ebbinghaus09:06:03

Is this with pathom2 or 3?

sheluchin15:06:17

It's Pathom3. Indeed, I think some of the issue is in the resolver generation. I had some strange issues, including https://github.com/wilkerlucio/pathom3/blob/d5b86d8e6d7a159ef0ef970de02c4145a82e030b/src/main/com/wsscode/pathom3/connect/runner.cljc#L358= that I was only able to fix by altering the https://github.com/roterski/fulcro-rad-xtdb/blob/07d713b64104ad588ab85f7dc4ac873c4927bba0/src/main/roterski/fulcro/rad/database_adapters/xtdb/generate_resolvers.clj#L121 to stop batching. At the moment I'm not going to pursue a fix beyond just including C in my query to make it all work, even though I don't need C. I would like to understand what can cause such a problem; it seems illogical to me. I need to get better at interpreting the planner graphs.

sheluchin16:07:15

I'm still having some issues with this, as described in the thread root. I'm looking at the plan and it looks like what is happening is that at some point A and B get merged together, which causes a failure when trying to get both of them. I attached the graph; I need to get both 1 and 3, but after Merging sibling resolver calls to resolver, I think one of them gets cancelled out. Any tips for dealing with this?

wilkerlucio11:07:45

hello @UPWHQK562, can you make a repro for this? I haven't been using RAD so I'm not sure whats going on

sheluchin16:07:08

@U066U8JQJ I took some time to try to make a minimal repro for it the other day but couldn't reproduce outside my environment 😕 I guess it's my data or something else that is responsible. Can you please suggest which area of the docs/source I should study to improve my ability to troubleshoot Pathom issues?

wilkerlucio20:07:18

not really sure at this point, I always try to reduce the query as much as possible, so we can get to the root cause, but so far with the info here its still vague to me

sheluchin16:07:15

I'm still having some issues with this, as described in the thread root. I'm looking at the plan and it looks like what is happening is that at some point A and B get merged together, which causes a failure when trying to get both of them. I attached the graph; I need to get both 1 and 3, but after Merging sibling resolver calls to resolver, I think one of them gets cancelled out. Any tips for dealing with this?