This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-11-29
Channels
- # aws (1)
- # aws-lambda (2)
- # bangalore-clj (3)
- # beginners (26)
- # boot (25)
- # braveandtrue (1)
- # cider (5)
- # cljsrn (7)
- # clojure (144)
- # clojure-android (2)
- # clojure-czech (1)
- # clojure-greece (3)
- # clojure-italy (17)
- # clojure-poland (5)
- # clojure-russia (25)
- # clojure-spec (9)
- # clojure-uk (100)
- # clojurescript (85)
- # core-async (42)
- # cursive (11)
- # datascript (2)
- # datomic (25)
- # duct (3)
- # emacs (5)
- # figwheel (2)
- # fulcro (49)
- # graphql (16)
- # hoplon (8)
- # klipse (10)
- # leiningen (10)
- # lumo (9)
- # off-topic (12)
- # om (14)
- # onyx (25)
- # planck (34)
- # portkey (6)
- # re-frame (43)
- # reagent (4)
- # remote-jobs (2)
- # ring (36)
- # ring-swagger (1)
- # rum (1)
- # shadow-cljs (187)
- # specter (25)
- # sql (5)
- # unrepl (75)
@thheller i’m interested in making this timeout configurable: https://github.com/thheller/shadow-cljs/blob/6607f209b9535564ed9d59754cbde956537e8388/src/main/shadow/cljs/devtools/server/worker.clj#L74
not quite sure what best way is for threading a parameter all the way there. what approach would you suggest?
@sundbp does you code actually run this long? I noticed that sometimes the REPL doesn’t properly return the result and ends up in a timeout which is a bug.
i’m using the REPL and sometimes have some long DB queries and such I’m waiting for. for exploration.
I generate a piece of code the the exports. that piece does not have source maps so there is a “gap”
right.. i’m actually producing a node-script, but used node-library to use the bin/runner.js
I am running into this case on my build-server:
<- Compile CLJS: om/next.cljc (15087 ms)
Cache write: om/next.cljc
aborted par-compile, [:shadow.build.classpath/resource "fulcro/client/util.cljc"] still waiting for #{om.next}
{:aborted [:shadow.build.classpath/resource "fulcro/client/util.cljc"], :pending #{om.next}}
ExceptionInfo: aborted par-compile, [:shadow.build.classpath/resource "fulcro/client/util.cljc"] still waiting for #{om.next}
clojure.core/ex-info (core.clj:4739)
clojure.core/ex-info (core.clj:4739)
shadow.build.compiler/par-compile-one (compiler.clj:647)
shadow.build.compiler/par-compile-one (compiler.clj:622)
shadow.build.compiler/par-compile-cljs-sources/fn--11576/iter--11577--11581/fn--11582/fn--11583/fn--11584 (compiler.clj:721)
clojure.core/apply (core.clj:657)
clojure.core/with-bindings* (core.clj:1965)
clojure.core/with-bindings* (core.clj:1965)
clojure.core/apply (core.clj:661)
clojure.core/bound-fn*/fn--5471 (core.clj:1995)
java.util.concurrent.FutureTask.run (FutureTask.java:266)
java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1149)
java.util.concurrent.ThreadPoolExecutor$Worker.run (ThreadPoolExecutor.java:624)
java.lang.Thread.run (Thread.java:748)
Is this fixable?Maybe this helps:
17-11-29 12:48:05 cb56ad16b459 WARN [shadow.build.compiler:286] - [:shadow.build.classpath/resource "fulcro/client/logging.cljc"] waiting for #{om.next}
17-11-29 12:48:05 cb56ad16b459 WARN [shadow.build.compiler:286] - [:shadow.build.classpath/resource "fulcro/i18n.cljc"] waiting for #{fulcro.client.logging}
17-11-29 12:48:05 cb56ad16b459 WARN [shadow.build.compiler:286] - [:shadow.build.classpath/resource "fulcro/client/mutations.cljc"] waiting for #{fulcro.client.util fulcro.client.logging om.next fulcro.i18n}
17-11-29 12:48:05 cb56ad16b459 WARN [shadow.build.compiler:286] - [:shadow.build.classpath/resource "fulcro/client/impl/om_plumbing.cljc"] waiting for #{fulcro.client.mutations fulcro.client.logging om.next}
17-11-29 12:48:05 cb56ad16b459 WARN [shadow.build.compiler:286] - [:shadow.build.classpath/resource "fulcro/client/impl/data_fetch.cljc"] waiting for #{fulcro.client.util fulcro.client.mutations fulcro.client.logging om.next fulcro.client.impl.om-plumbing}
17-11-29 12:48:05 cb56ad16b459 WARN [shadow.build.compiler:286] - [:shadow.build.classpath/resource "fulcro/client/network.cljc"] waiting for #{fulcro.client.logging}
17-11-29 12:48:05 cb56ad16b459 WARN [shadow.build.compiler:286] - [:shadow.build.classpath/resource "fulcro/client/impl/application.cljc"] waiting for #{fulcro.client.util fulcro.client.impl.data-fetch fulcro.client.network fulcro.client.logging om.next fulcro.client.impl.om-plumbing fulcro.i18n}
17-11-29 12:48:05 cb56ad16b459 WARN [shadow.build.compiler:286] - [:shadow.build.classpath/resource "fulcro/client/core.cljc"] waiting for #{fulcro.client.util fulcro.client.mutations fulcro.client.impl.application fulcro.client.network fulcro.client.logging om.next fulcro.client.impl.om-plumbing}
17-11-29 12:48:05 cb56ad16b459 WARN [shadow.build.compiler:286] - [:shadow.build.classpath/resource "atlas_crm/api/mutations.cljs"] waiting for #{fulcro.client.mutations fulcro.client.logging om.next fulcro.client.routing}
17-11-29 12:48:05 cb56ad16b459 WARN [shadow.build.compiler:286] - [:shadow.build.classpath/resource "fulcro/client/routing.cljc"] waiting for #{fulcro.client.util fulcro.client.core fulcro.client.mutations fulcro.client.logging om.next}
17-11-29 12:48:06 cb56ad16b459 WARN [shadow.build.compiler:286] - [:shadow.build.classpath/resource "atlas_crm/ui/app/routes.cljc"] waiting for #{fulcro.client.routing}
17-11-29 12:48:07 cb56ad16b459 WARN [shadow.build.compiler:286] - [:shadow.build.classpath/resource "fulcro_css/core.cljc"] waiting for #{om.next}
<- Compile CLJS: om/next.cljc (15087 ms)
Cache write: om/next.cljc
aborted par-compile, [:shadow.build.classpath/resource "fulcro/client/util.cljc"] still waiting for #{om.next}
{:aborted [:shadow.build.classpath/resource "fulcro/client/util.cljc"], :pending #{om.next}}
ExceptionInfo: aborted par-compile, [:shadow.build.classpath/resource "fulcro/client/util.cljc"] still waiting for #{om.next}
clojure.core/ex-info (core.clj:4739)
clojure.core/ex-info (core.clj:4739)
shadow.build.compiler/par-compile-one (compiler.clj:647)
shadow.build.compiler/par-compile-one (compiler.clj:622)
shadow.build.compiler/par-compile-cljs-sources/fn--11576/iter--11577--11581/fn--11582/fn--11583/fn--11584 (compiler.clj:721)
clojure.core/apply (core.clj:657)
clojure.core/with-bindings* (core.clj:1965)
clojure.core/with-bindings* (core.clj:1965)
clojure.core/apply (core.clj:661)
clojure.core/bound-fn*/fn--5471 (core.clj:1995)
java.util.concurrent.FutureTask.run (FutureTask.java:266)
java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1149)
java.util.concurrent.ThreadPoolExecutor$Worker.run (ThreadPoolExecutor.java:624)
java.lang.Thread.run (Thread.java:748)
guess I really need to crank up this delay. did not expect any namespaces to ever take longer to compile than cljs.core
technically the only reason to have this abort is to prevent infinite loops due to bugs
Thnx that will solve it for now, fulcro has forked om.next, I hope that compiles faster
I need to decide on a framework I want to use for the shadow-cljs UI I want to build
@mitchelkuijpers try [email protected]
, bumped the timeout to 60sec
Awesome! Thnx @thheller
Fulcro is pretty awesome in my opinion they even have special devtools released which makes it a pretty nice dev env. If you are seriously interesed I would be happy to assist in any way
They are almost release fulcro 2.0 RC
but there is also a 1.2 version which we are using in production
I like fulcro although I’m not convinced that co-locating queries in components is the best idea
For me the most important thing is that it has good documentation
We co-locate: queries, initial-state and css
We love it, it makes a lot of stuff a lot more straightforward. For us the biggest win is the graph-db format
I already solved css for me so I don’t need that 😉 https://github.com/thheller/shadow/wiki/shadow.markup
Oh nice, we loved the way fulcro did it because you need to compose css to root. We use that to SSR markup and only return the css that is necessary for that view
No you re-render from any point that you like
you can also re-render by ident
if you know what that means. And then it will only re-render what is bound to that ident
It has some nice tools to handle performance sensitive stuff
But fulcro 2.0 forked om.next to fix some important stuff
Something todo with the "Dynamic queries" and to add some nice performance optimizations
Hmm I am trying to use the :karma
target but it gives me:
[:ci] Compiling ...
{:type :shadow.build.targets.karma/test-namespaces, :test-namespaces [atlas-crm.ui.components.entity-selector-test atlas-crm.ui.impl.routing.path-test atlas-crm.ui.impl.routing.linear-search-router-test], :entries [shadow.test.env atlas-crm.ui.components.entity-selector-test atlas-crm.ui.impl.routing.path-test atlas-crm.ui.impl.routing.linear-search-router-test shadow.test.karma]}
no goog/base.js
{}
ExceptionInfo: no goog/base.js
clojure.core/ex-info (core.clj:4739)
clojure.core/ex-info (core.clj:4739)
shadow.build.output/closure-defines-and-base (output.clj:46)
shadow.build.output/closure-defines-and-base (output.clj:41)
shadow.build.targets.karma/flush-karma-test-file (karma.clj:72)
shadow.build.targets.karma/flush-karma-test-file (karma.clj:67)
shadow.build.targets.karma/flush (karma.clj:94)
shadow.build.targets.karma/flush (karma.clj:91)
shadow.build.targets.karma/process (karma.clj:109)
shadow.build.targets.karma/process (karma.clj:99)
clojure.lang.Var.invoke (Var.java:381)
shadow.build/process-stage (build.clj:110)
shadow.build/process-stage (build.clj:102)
shadow.build/flush (build.clj:316)
shadow.build/flush (build.clj:312)
shadow.cljs.devtools.api/compile* (api.clj:189)
shadow.cljs.devtools.api/compile* (api.clj:184)
shadow.cljs.devtools.cli/do-build-command (cli.clj:40)
shadow.cljs.devtools.cli/do-build-command (cli.clj:30)
shadow.cljs.devtools.cli/do-build-commands/fn--61387/fn--61388 (cli.clj:68)
clojure.core/binding-conveyor-fn/fn--5476 (core.clj:2022)
java.util.concurrent.FutureTask.run (FutureTask.java:266)
java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1149)
java.util.concurrent.ThreadPoolExecutor$Worker.run (ThreadPoolExecutor.java:624)
java.lang.Thread.run (Thread.java:748)
Any idea why?
Or am I running it wrong I run: bin/lein run -m shadow.cljs.devtools.cli compile ci
Haha what command should I run?
Hehe but i have set leiningen to true
So I don't see a difference 😛
Lol it does work when I run it like that
No worries it does work with the shadow-cljs command
No I am stupid
Hold on
No I get the same error
:ci {:target :karma
:output-to "resources/public/ci/karma.js"}
Is this config maybe wrong?I stole it from you 😛
Yeah I though I had
But it doesn't seem to work
That is absolutely fine because this is only for Ci
Yes sure
No Karma breaks on:
Really sorry to keep disturbing you
Ah lol
I am still trying to get the other browser-test build working
:karma
is basically a very simplified version that doesn’t do live reloading or a REPL
Oh sorry, :karma
does not work
So I should just add js-options provider shadow?
Awesome
That works awesome!
Today we are moving over completely to shadow-cljs with my team ^^
I had one more idea btw, we are also using devcards do you think we could use :browser-test
target to automatically include all files that end on -cards
Yeah ^^
but I don’t think you want to include devcards with your tests? those don’t do anything cljs.test
related or do they?
No but I just want something to automatically include all -card
namespaces so I don't have to keep adding them to one file
I can make my own targets right?
Hmm that might be cool to do
https://github.com/thheller/shadow-cljs/blob/master/src/main/shadow/build/targets/karma.clj
First I am struggling to get my :browser-test
to work again, for some reason it does not seem to pick up my runner-ns
Oh lol then I could have still used the old way with using browser-test for karma
That would explain why that broke
Would you be interested if I setup a circleci config for shadow-cljs to start adding some tests?
fixed in [email protected]
. same issue indeed.
Ah awesome thnx
Maybe a examples folder with for example a karma test, that one we could verify
browser output is a bit harder
well just verifying that the compile completed without an error would be enough to start
There is the new chrome project where you can run chrome and do pretty nifty stuff
I could just start with creating a circleci config and run some tests
that would be a good start at least
If you create a issue in github I would be happy to help, we already have some cljs tests running on circleci
I’ll look over the circleci docs, getting the config right is probably the hardest part
I built one myself
FROM circleci/clojure:lein-2.7.1
USER root
RUN curl -sL | bash -
RUN apt-get install -y nodejs
#
RUN wget -q -O - | apt-key add -
RUN echo 'deb stable main' >> /etc/apt/sources.list
RUN apt-get update && apt-get install --no-install-recommends -y google-chrome-stable
Sorry to hijack this thread, but I’m wondering if I can use lein checkouts (or something similar) with shadow
I’m using shadow-cljs
That’s what I thought
but the checkout dependency still needs to be in :dependencies
so its dependencies get picked up properly
Right, it is
Yeah that’s cool, I’d like that
Then, could I just change the source paths in the release config?
Ie, the release override
Alternatively, if I go through lein, checkouts should just work?
Cool thanks
@mitchelkuijpers the first lein test
via circleci succeeded. not very meaningful since there are no tests but still 😉
Nice small steps
I would love to contribute some tests, it would help us a lot
yeah I wanted proper tests for a while. accidental changes like the :karma
/`:browser-test` breaking are not cool
Yeah that is very understandable
Yeah yml sucks but spacemacs protects me a bit from mixing spaces and tabs and such
hmm can you start a process and then run other commands while that process is running?
You can also start multiple docker containers
run shadow-cljs server
in the background and then run a bunch of things against that server
Ah like that
Maybe just create a clj script which does multiple things? Is that an option
Oh ofcourse