pathom

:pathom: https://github.com/wilkerlucio/pathom/ & https://pathom3.wsscode.com & https://roamresearch.com/#/app/wsscode
dehli 2021-02-22T02:25:53.002300Z

I think I’ve figured out what was causing my issue. I have a mutation that’s properly surfacing the error (from the plugin) when I call it regularly. However, if I specify keys to return from the mutation it’s resulting in the error not surfacing.

(pco/defmutation mutate [params]
  {::plugins/params-spec (ds/spec ::spec {::id keyword?})}
  {::params params})

(p.a.eql/process registry `[(mutate {::id "fail")])
;; Returns with a ::pcr/mutation-error

(p.a.eql/process registry `[{(mutate {::id "fail"}) [::params]}])
;; Returns {`mutate {}}
I added a failing test showcasing the difference in behavior in case that’s helpful. https://github.com/dehli/pathom3-plugins/blob/main/test/dehli/pathom3/plugins_test.cljc#L25-L33