pathom

:pathom: https://github.com/wilkerlucio/pathom/ & https://pathom3.wsscode.com & https://roamresearch.com/#/app/wsscode
mauricio.szabo 2021-06-05T21:40:11.047100Z

Hi there! @wilkerlucio I was talking with you in private about some resolver problems, and here's what I found: On my current Duck-REPLed project, I'm able to query REPL interactions. To make this happen, I somehow need to know what to query. To make things as simple as possible, I decided to do some "default contents", for example: if I do query [:var/fqn] I probably want the "full qualified name" of the current var in the editor.

mauricio.szabo 2021-06-05T21:41:58.049100Z

This made the planner incredibly slow - it's taking +500ms to plan the query. How can I send you more info, so you can check if it's some bug or it's inherently a problem on how I made my resolvers?

mauricio.szabo 2021-06-06T15:19:15.050400Z

Helpers is duck-repled.repl-helpers eql is generated with duck-repled.core/gen-eql

mauricio.szabo 2021-06-06T15:19:17.050800Z

Ok, in theory if you start a REPL with duck-repled and try to evaluate these codes, it should have the same problem that I had

mauricio.szabo 2021-06-06T15:20:59.051100Z

The problem is that I'm not being able to connect Viz on them: on Clojure, it always return nil for the eval result, and not give me the trace, and in ClojureScript it's crashing node with:

INFO [com.wsscode.pathom.viz.ws-connector.impl.sente-cljs:81] - Connecting to websocket {:com.wsscode.pathom.viz.ws-connector.core/on-message #object[Function], :com.wsscode.pathom.viz.ws-connector.impl.sente-cljs/send-ch #object[cljs.core.async.impl.channels.ManyToManyChannel], :com.wsscode.pathom.viz.ws-connector.core/parser-id :duck-repled.core/duck}
INFO [com.wsscode.pathom.viz.ws-connector.impl.sente-cljs:62] - Waiting for channel to be ready 1000
INFO [com.wsscode.pathom.viz.ws-connector.impl.sente-cljs:75] - Waiting for channel to be ready 1000

/home/mauricio/projects/duck-repled/.shadow-cljs/builds/tests/dev/out/cljs-runtime/cognitect/transit.cljs:418
        (WithMeta. (-with-meta ^not-native x nil) m)
        ^
TypeError: x.cljs$core$IWithMeta$_with_meta$arity$2 is not a function
    at Transit$JSONMarshaller.transform (/home/mauricio/projects/duck-repled/.shadow-cljs/builds/tests/dev/out/cljs-runtime/cognitect/transit.cljs:418:9)

mauricio.szabo 2021-06-06T15:21:58.051300Z

I was only be able to truly connect to Viz and check the query inside the Chlorine project 😞 But then, it's quite hard to setup everything to make it work

mauricio.szabo 2021-06-05T21:44:16.049200Z

More info about this problem: here's the "slow" query:

mauricio.szabo 2021-06-05T21:44:32.049600Z

And here's the fast one:

wilkerlucio 2021-06-05T23:41:34.050Z

hello, can you send an example of how I can reproduce it?