Skip to content

Commit

Permalink
Remove elided value, use a function to closure around the graph on pl…
Browse files Browse the repository at this point in the history
…anner error
  • Loading branch information
wilkerlucio committed Dec 5, 2024
1 parent 0942777 commit bbd9488
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 31 deletions.
29 changes: 0 additions & 29 deletions src/main/com/wsscode/misc/elided_value.cljc

This file was deleted.

7 changes: 5 additions & 2 deletions src/main/com/wsscode/pathom3/connect/planner.cljc
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
[clojure.string :as str]
[com.fulcrologic.guardrails.core :refer [>def >defn >fdef => | <- ?]]
[com.wsscode.misc.coll :as coll]
[com.wsscode.misc.elided-value :as ev]
[com.wsscode.misc.refs :as refs]
[com.wsscode.pathom3.attribute :as p.attr]
[com.wsscode.pathom3.cache :as p.cache]
Expand Down Expand Up @@ -35,6 +34,10 @@
"The graph container, requires nodes."
(s/keys :req [::nodes]))

(>def ::graph-fn
"A function that returns a graph, used to hide the graph from long error messages"
any?)

(>def ::available-data
"An shape descriptor declaring which data is already available when the planner starts."
(? ::pfsd/shape-descriptor))
Expand Down Expand Up @@ -1710,7 +1713,7 @@
(ex-info
(str "Pathom can't find a path for the following elements in the query: "
(pr-str (pfsd/shape-descriptor->query missing)) (p.path/at-path-string env))
{::graph (ev/elided-value graph)
{::graph-fn (fn [] graph)
::unreachable-paths missing
::unreachable-details (unreachable-details env graph missing)
::p.path/path (get env ::p.path/path)
Expand Down

0 comments on commit bbd9488

Please sign in to comment.