This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2020-07-15
Channels
- # admin-announcements (1)
- # announcements (8)
- # babashka (6)
- # beginners (70)
- # bristol-clojurians (1)
- # chlorine-clover (15)
- # cider (3)
- # cljs-dev (2)
- # cljsrn (27)
- # clojure (249)
- # clojure-europe (19)
- # clojure-italy (2)
- # clojure-nl (12)
- # clojure-spec (11)
- # clojure-uk (42)
- # clojuredesign-podcast (6)
- # clojurescript (39)
- # community-development (1)
- # conjure (43)
- # cursive (37)
- # data-science (1)
- # datomic (3)
- # duct (16)
- # figwheel-main (23)
- # fulcro (3)
- # instaparse (5)
- # java (5)
- # jobs (1)
- # jobs-discuss (1)
- # malli (11)
- # off-topic (27)
- # re-frame (32)
- # reagent (5)
- # reitit (2)
- # rum (15)
- # shadow-cljs (24)
- # spacemacs (7)
- # sql (5)
- # test-check (3)
- # tools-deps (5)
The optionsUrl is in the generated index.js ; I use the local IP so I can test/refresh on a real device rather than the simulator
Anyone having a good time with Krell running on a real android device? I'm seeing odd issues which I think might be race condition related.
e.g. namespaces loading out of order
It's proving hard to pin down
Tends to express itself in errors like these: • "TypeError: goog.debug.freeze is not a function" (common on one big project) • "goog.require could not find: awesome_project.core" • "ReferenceError: re_frame is not defined"
Tentitive theory that perhaps waitForCore needs to wait on more files to avoid a race condition
function waitForCore(cb) {
// we only care if goog/base.js is actually in the cache, that's enough
// to bootstrap regardless whether some things must be refetched
if(KRELL_CACHE.ready
&& KRELL_CACHE.has(toPath("goog/base.js"))
&& KRELL_CACHE.has(toPath("goog/deps.js")) // <-- HERE
&& KRELL_CACHE.has(toPath("cljs_deps.js")) // <-- HERE
&& KRELL_CACHE.has(toPath("krell_repl_deps.js"))) {// <-- HERE
bootstrap();
cb();
} else if(typeof cljs !== 'undefined') {
console.log("typeof cljs !== 'undefined'")
cb();
} else {
setTimeout(function() { waitForCore(cb); }, 250);
}
}
@dnolen I think you had a productive android device setup - is that right? we're having trouble.
That's where we're seeing it
if you look closely at the code for Android in the REPL JS you'll see that there's a few things in place to ensure order
it's possible I missed something but it hasn't come up in the emulator or on the device (personally) in some time
one thing you could try is that you could bump the tcp-socket dep, I think there were several issues w/ how it worked and some have been addressed
I'm back on work that directly needs Krell so I should be more active again on in it the coming weeks
Okay, thanks. I'll give that a try and see what else I can pin down.
Certainly would describe what I'm seeing.
Bumping to the latest react-native-tcp-socket doesn't seem to have helped.
I have a feeling the clue is this error which appears in adb logcat
> 07-15 19:29:32.163 21032 21195 I ReactNativeJS: 'Bootstrap from cache failed:', { [TypeError: undefined is not an object (evaluating 'KRELL_CACHE.get(toPath("goog/deps.js")).source')]
Anyway, I'm out of ideas for today. Thanks for the suggestions.
@olivergeorge ah yeah I was going to say that's the other possibility your cache was corrupted - i.e. the issue is not related to react-native-tcp-socket at all