cljs-dev

bronsa 2024-04-18T08:36:11.553949Z

yeah that explains why the {::foo/bar} syntax works -- it uses str instead of ns-name

bronsa 2024-04-18T08:36:38.158269Z

seems an innocuous enough change to make, will do

bronsa 2024-04-18T08:40:48.843929Z

fix pushed to master, if anybody can confirm that fixes it, I'll do a release

thheller 2024-04-18T11:03:03.480239Z

@bronsa yep, confirmed fixed

bronsa 2024-04-18T11:52:26.426119Z

cool, will make a release

🎸 4
dnolen 2024-04-18T12:29:14.631029Z

resolved and closed https://clojure.atlassian.net/browse/CLJS-3412

dnolen 2024-04-18T12:32:29.583339Z

https://github.com/clojure/clojurescript/pull/228

lilactown 2024-04-18T14:57:19.362009Z

thanks y'all! that was super fast

thheller 2024-04-18T06:20:06.013929Z

another argument to why dropping stacktraces sucks 😛 I added the stacktrace for the error, so we know at least where it fails 😛

thheller 2024-04-18T06:20:08.534379Z

30 | (def data #::b {:x 1 :y 2 :z 3})
---------------------^----------------------------------------------------------
No namespace: app.b found
	clojure.tools.reader/read* (reader.clj:953)
	clojure.tools.reader/read* (reader.clj:917)
	clojure.tools.reader/read-delimited (reader.clj:198)
	clojure.tools.reader/read-delimited (reader.clj:191)
	clojure.tools.reader/read-list (reader.clj:209)
	clojure.tools.reader/read-list (reader.clj:205)
	clojure.tools.reader/read* (reader.clj:935)
	clojure.tools.reader/read* (reader.clj:917)
	clojure.tools.reader/read (reader.clj:988)
	clojure.tools.reader/read (reader.clj:961)
    ...
Caused by:
Exception: No namespace: app.b found
	clojure.core/the-ns (core.clj:4163)
	clojure.core/ns-name (core.clj:4165)
	clojure.core/ns-name (core.clj:4165)
	clojure.tools.reader/read-namespaced-map (reader.clj:762)
	clojure.tools.reader/read-namespaced-map (reader.clj:753)
	clojure.tools.reader/read-dispatch (reader.clj:72)
	clojure.tools.reader/read-dispatch (reader.clj:68)
	clojure.tools.reader/read* (reader.clj:935)
	clojure.tools.reader/read* (reader.clj:917)
	clojure.tools.reader/read-delimited (reader.clj:198)
	clojure.tools.reader/read-delimited (reader.clj:191)
	clojure.tools.reader/read-list (reader.clj:209)
	clojure.tools.reader/read-list (reader.clj:205)
	clojure.tools.reader/read* (reader.clj:935)
	clojure.tools.reader/read* (reader.clj:917)
	clojure.tools.reader/read (reader.clj:988)
	clojure.tools.reader/read (reader.clj:961)

thheller 2024-04-18T06:20:56.674989Z

(this is with shadow-cljs, regular cljs likely would have the vendorized reader variant)

thheller 2024-04-18T06:29:43.912079Z

ok, so the issue is that *alias-map* contains the {b app.b} symbol. that gets passed to ns-name which for symbols calls find-ns. since its just an alias it doesn't exist.

thheller 2024-04-18T06:31:08.358919Z

seems like it should have a special case for whether it has a Namespace instance or a symbol? since all it needs is the string, creating a dummy empty ns seems pointless? although this is already done for all cljs namespaces anyway, so not a big deal

thheller 2024-04-18T06:31:13.774429Z

^ @bronsa