Skip to content
This repository has been archived by the owner on Jun 4, 2022. It is now read-only.

Can't require cljs.edn on lumo? #419

Open
JulianBirch opened this issue Jul 22, 2018 · 5 comments
Open

Can't require cljs.edn on lumo? #419

JulianBirch opened this issue Jul 22, 2018 · 5 comments

Comments

@JulianBirch
Copy link

Apologies if this is in error, but I got the following bug report and I'm not sure what's causing it:

JulianBirch/cljs-ajax#213

Steps to reproduce are:

deps.edn:

{:deps {cljs-ajax {:mvn/version "0.7.3"}}}

$ lumo -c $(clojure -Srepro -Spath) -e "(require '[ajax.core])"

and you end up with cljs.edn being not found. Works in regular clojurescript.

@anmonteiro
Copy link
Owner

@JulianBirch what is cljs.edn in this context? The ClojureScript compiler doesn't ship with that namespace

@JulianBirch
Copy link
Author

Huh. It used to be the namespace for the EDN format. I wonder why it's being found normally...

@anmonteiro
Copy link
Owner

I'm not sure cljs.edn ever existed. There's cljs.reader. Unless there's some kind of weird transformation going on trying to convert clojure.edn to cljs.edn via automatic clojure.* -> cljs.* aliasing.

This last case would most likely mean that there's a namespace somewhere that is not compatible with self-host ClojureScript (maybe a macros namespace?).

@JulianBirch
Copy link
Author

JulianBirch commented Jul 22, 2018

Okay, now I'm fairly perplexed, sorry, I should have gone over the code before but... the code doesn't even reference this namespace? https://github.com/JulianBirch/cljs-ajax/blob/master/src/ajax/edn.cljc

(As you can see, clojure.edn is referenced, but it's in a reader macro so shouldn't be a problem.)

Macros may be a problem somewhere.

@arichiardi
Copy link
Collaborator

Is this still a problem?

There is clojure.edn and cljs.reader which offer the same set of feature. However the ClojureScript compiler usually tries to see if for a clojure.x there is a cljs.x.

I have not investigated further but if there is a problem it might be worth checking if you are able to reproduce with JVM ClojureScript

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants