Fork me on GitHub
#shadow-cljs
<
2019-02-14
>
metacritical03:02:38

@thheller This is so awesome! Thankyou!

thheller08:02:15

no? what does that have to do with anything?

thheller08:02:32

if anything ever calls goog.nodeGlobalRequire it is because of a bug that needs to be fixed

metacritical08:02:55

well i would want to call load-file which calls this.

manuel08:02:45

hi, with latest cider-nrepl, I get this when using shadow-cljs watch:

[2019-02-14 09:49:48.486 - WARNING] :shadow.cljs.devtools.server/nrepl-ex
Note: The following stack trace applies to the reader or compiler, your code was not executed.
CompilerException Syntax error compiling at (cider/nrepl.clj:1:1). #:clojure.error{:phase :compile-syntax-check, :line 1, :column 1, :source "cider/nrepl.clj"}
	clojure.lang.Compiler.load (Compiler.java:7647)
	clojure.lang.RT.loadResourceScript (RT.java:381)
	clojure.lang.RT.loadResourceScript (RT.java:372)
	clojure.lang.RT.load (RT.java:463)
	clojure.lang.RT.load (RT.java:428)
	clojure.core/load/fn--6824 (core.clj:6126)
	clojure.core/load (core.clj:6125)
	clojure.core/load (core.clj:6109)
	clojure.core/load-one (core.clj:5908)
	clojure.core/load-one (core.clj:5903)
	clojure.core/load-lib/fn--6765 (core.clj:5948)
	clojure.core/load-lib (core.clj:5947)
Caused by:
FileNotFoundException Could not locate nrepl/middleware/caught__init.class, nrepl/middleware/caught.clj or nrepl/middleware/caught.cljc on classpath.
	clojure.lang.RT.load (RT.java:466)
	clojure.lang.RT.load (RT.java:428)
	clojure.core/load/fn--6824 (core.clj:6126)
	clojure.core/load (core.clj:6125)
	clojure.core/load (core.clj:6109)
	clojure.core/load-one (core.clj:5908)
	clojure.core/load-one (core.clj:5903)
	clojure.core/load-lib/fn--6765 (core.clj:5948)
	clojure.core/load-lib (core.clj:5947)
	clojure.core/load-lib (core.clj:5928)
	clojure.core/apply (core.clj:667)
	clojure.core/load-libs (core.clj:5985)

thheller08:02:36

looks like something is broken there?

manuel08:02:01

you mean on cider-nrepl side?

manuel08:02:14

because I only bumped the dependency in my shadow-cljs.edn

thheller08:02:11

shadow-cljs is using clojure 1.10 now. guess there is something in the ns form that it doesn't like anymore?

metacritical08:02:13

Seems like a nrepl issue

thheller08:02:59

no caught.clj?

thheller08:02:21

but required there. not sure where that is supposed to be coming from

manuel08:02:33

I see, I'll report the issue to them. Thanks ๐Ÿ™‚

thheller08:02:04

looks like someone maybe forgot to commit it

thheller08:02:43

pretty sure that has nothing to do with bumping shadow-cljs though

thheller08:02:53

cider probably also updated?

manuel08:02:04

yes, I upgraded it this morning

manuel08:02:14

but I've only seen this issue on shadow-cljs watch

manuel08:02:35

note that shadow-cljs compile works just fine, so yes, it's cider-nrepl related

thheller08:02:53

compile doesn't start an nrepl server so it doesn't load cider.nrepl

manuel09:02:06

@thheller yep, I was just saying that shadow-cljs works fine ๐Ÿ˜‰

thheller09:02:52

@metacritical yes I know that. nodeGlobalRequire is bad and should not be used

metacritical09:02:21

So i should just manually load a cljs file in bootstrapped env and eval it?

thheller09:02:15

well what are you trying to do?

thheller09:02:28

(load-file "./some/thing.cljs")?

thheller09:02:50

that would never work since it can only load .js files as no compilation is done

thheller09:02:14

I honestly don't know why this is even a thing that exists

metacritical09:02:35

aah that makes sense.!

thheller09:02:01

maybe it is used by something internally. I don't know but you definitely cannot use it to load .cljs files

metacritical09:02:51

That is helpful i would do a custom load file then. Thanks a lot!

thheller09:02:47

@manuel I guess it was just the outdated nrepl dep. Try 2.7.34

manuel09:02:14

works now, thank you. I only get this warning:

WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by mranderson048.orchard.v0v3v0.dynapath.v0v2v5.dynapath.defaults$eval8306$fn__8307 to method java.net.URLClassLoader.addURL(java.net.URL)
WARNING: Please consider reporting this to the maintainers of mranderson048.orchard.v0v3v0.dynapath.v0v2v5.dynapath.defaults$eval8306$fn__8307
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release

thheller09:02:41

not something I can control

thheller09:02:45

tell them ๐Ÿ˜‰

manuel09:02:06

sure thing

thheller09:02:25

They are still probably testing with Java8 which won't have those warnings

thheller13:02:23

I just pushed 2.7.35 with new logic for the built-in development HTTP servers. Old configs should still work so no changes required (unless you want to). Please let me know if something breaks in your dev setups. https://shadow-cljs.github.io/docs/UsersGuide.html#dev-http

mhuebert15:02:54

@thheller trying this out now. my push-state routes donโ€™t seem to be working, I have :dev-http {8701 "public"} - localhost:8701/ loads my index.html file from /public correctly, but localhost:8701/intro gives me Not found. Missing index.html.

thheller15:02:56

oh right .. forgot about that

thheller15:02:01

@mhuebert thx for testing. fixed in 2.7.36.

5
mhuebert15:02:40

works for me, thanks!

dpsutton15:02:30

@manuel I saw your woes too late. M-x cider-jack-in-clojurescript adds the correct -d nrepl:0.6.0 for you. The jack-in-X commands have gotten very good (in my experience) lately

manuel15:02:57

thanks @dpsutton ๐Ÿ™‚

dpsutton15:02:20

๐Ÿ‘ (and if it doesn't work correctly I consider it a bug)

metacritical17:02:56

WoW three minor version number bumped in a day.

metacritical17:02:24

Slack Driven Development actually works.

dpsutton17:02:48

i would attribute this to @thheller being fantastic for the community

โค๏ธ 40
grounded_sage17:02:00

@thheller how far along are you with doing a simple Gatsby JS clone / SSR story. Last I remember you were going to use Fulcro? Iโ€™m growing interested in Fulcro and also prefer not to do redundant work. So if there is a repo to watch I would love to know :)

thheller17:02:05

no time to work on anything related to that. others have done SSR with fulcro and pathom would make hooking up some kind of storage trivial

metacritical17:02:37

True @thhelleris awesome.

โค๏ธ 60
richiardiandrea22:02:20

is there a trusted deps.edn and shadow-cljs docker container folks use?