This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2018-02-08
Channels
- # aleph (2)
- # aws (1)
- # beginners (172)
- # boot (15)
- # cider (17)
- # clara (7)
- # cljs-dev (22)
- # cljsrn (12)
- # clojars (3)
- # clojure (110)
- # clojure-dev (5)
- # clojure-italy (13)
- # clojure-sanfrancisco (5)
- # clojure-spec (3)
- # clojure-uk (31)
- # clojurescript (110)
- # community-development (2)
- # cursive (16)
- # datomic (19)
- # docs (4)
- # emacs (49)
- # fulcro (24)
- # jobs (5)
- # keechma (2)
- # lein-figwheel (41)
- # leiningen (10)
- # luminus (4)
- # lumo (24)
- # mount (24)
- # numerical-computing (1)
- # off-topic (16)
- # om (4)
- # onyx (6)
- # parinfer (9)
- # planck (8)
- # re-frame (7)
- # reagent (6)
- # shadow-cljs (125)
- # sql (5)
- # test-check (9)
- # unrepl (6)
- # yada (5)
@dnolen in self-host we build source maps inline with ?rel=number
. Would it make sense to have a path that gets rid of that only if target is node
? I have basically discovered that cljs.stacktrace/remove-ext
does not work if ?rel=...
is in there, I opened https://dev.clojure.org/jira/browse/CLJS-2493
(unless I am missing some normalization step along the way)
Ok I opened a couple of issues and sent a patch for https://dev.clojure.org/jira/browse/CLJS-2492. Now lumo
has working stacktrace mapping 😄 🎉
@richiardiandrea thanks will take a look
@martinklepsch yeah that was an old conversation, enough people have stated they have legitimate reasons for whitespace - it should be supported
there’s probably some funny cases, since it’s a bit less common, but if it doesn’t work and could be made to work - that should be considered a defect
Closure february release is available, I'll try to check soon if that would happen to fix the problems my patch had
data point, I updated lumo
and had a test failure in an simple :npm-test
.
So, Closure update doesn't fix the problem, but I think I finally might have found the cause
script/test
has one AMD module, so that will enable .setTransformAMDToCJSModules
for Closure Compiler
Other tests probably don't try AMD modules (at least with Node packages)
I think this is bug in Closure (it tries to process all files as AMD modules before json files are converted) but as AMD support has been deprecated, maybe it would be just bast to remove the AMD support from our side and remove the tests
Still getting one test failure:
FAIL in (test-printing) (core-advanced-test.js:1262:83)
Testing pr-str
expected: (#{"[1 true {:b #\"x\\\"y\", :a 2} #js [3 4]]" "[1 true {:a 2, :b #\"x\\\"y\"} #js [3 4]]"} (pr-str [1 true {:a 2, :b #"x"y"} (array 3 4)]))
actual: nil
Seems strange that this would be broken by Closure-compiler update? The problem is that #"x\"y"
is printed as #\"x\"y\"
, instead of as #\"x\\\"y\"
.
Or maybe not? After Cljs compilation JS looks like /x\"y/
but after optimization it is /x"y/
Running bisect on Closure to find the change, but seems like this has changed between v20170806 and v20171112
The optimization might be correct here, it is not necessary to escape "
inside JS regex literal, the regex pattern will work correctly
But this will affect cases where the regex is converted back to string (e.g. printing)
https://github.com/google/closure-compiler/commit/179b62cc4770fd6a9eb306d3cf529eb99e992026
These should be ready now:
https://dev.clojure.org/jira/browse/CLJS-2375 Remove AMD Module support and tests
https://dev.clojure.org/jira/browse/CLJS-2389 Closure Update, tests pass after CLJS-2375
https://dev.clojure.org/jira/browse/CLJS-2494 :npm-deps false
to disable indexing node_modules
https://dev.clojure.org/jira/browse/CLJS-2495 Throw if Closure reports errors
wow. 🎉 great work @juhoteperi