clojure-dev

Issues: https://clojure.atlassian.net/browse/CLJ | Guide: https://insideclojure.org/2015/05/01/contributing-clojure/
john 2019-04-23T00:22:20.082200Z

Related: Fastly's Cloud Workers are essentially just JS WebWorkers, with lots of tenants on different isolates in the same JS VM

souenzzo 2019-04-23T03:28:13.082900Z

:import from ns do not load cljc files Is it a know issue?

;; should work, once it was required first
;; clj -Srepro -Sdeps '{:deps {import-bug {:git/url "<https://gist.github.com/souenzzo/e23944fac595077f372aa662cde5ff91>" :sha "fd49010c7fee88bc3fb705d5fd494718bbd16f18"}}}' -m ok
;; should fail, once import will not search for cljc files
;; clj -Srepro -Sdeps '{:deps {import-bug {:git/url "<https://gist.github.com/souenzzo/e23944fac595077f372aa662cde5ff91>" :sha "fd49010c7fee88bc3fb705d5fd494718bbd16f18"}}}' -m fail
https://gist.github.com/souenzzo/e23944fac595077f372aa662cde5ff91

seancorfield 2019-04-23T03:37:16.083400Z

@souenzzo Wouldn't it need to have :load-ns true on defrecord for the import to auto-load the namespace?

souenzzo 2019-04-23T03:39:19.083600Z

load-ns?

alexmiller 2019-04-23T03:43:43.083800Z

(doc defrecord)

alexmiller 2019-04-23T03:44:23.084100Z

Supported options:
  :load-ns - if true, importing the record class will cause the
             namespace in which the record was defined to be loaded.
             Defaults to false.

souenzzo 2019-04-23T03:48:30.084600Z

https://gist.github.com/souenzzo/e23944fac595077f372aa662cde5ff91/1335ce6ddafcce916c9a081ecf55c956ceb62645 Trying with this rev, I still fails clj -Srepro -Sdeps '{:deps {import-bug {:git/url "<https://gist.github.com/souenzzo/e23944fac595077f372aa662cde5ff91>" :sha "1335ce6ddafcce916c9a081ecf55c956ceb62645"}}}' -m fail

alexmiller 2019-04-23T03:56:04.085600Z

import is for classes. you have to compile before classes exist that can be imported?

alexmiller 2019-04-23T04:02:42.086200Z

in the ok case, the require is compiling the class and loading it in the DCL so it's found in the import

alexmiller 2019-04-23T04:08:07.086700Z

if you added a compile step like: clj -e "(binding [*compile-path* \".\"] (compile 'record))" then the fail case will work

alexmiller 2019-04-23T04:09:03.087200Z

stepping way back, why do you need to import in the first place?

seancorfield 2019-04-23T04:11:55.088200Z

Hmm, sounds like :load-ns doesn't do quite what I thought then (I haven't used it -- I always just require the namespaces containing records).

alexmiller 2019-04-23T04:13:08.088600Z

it's really designed for the case where you are loading a Clojure record from Java

👍 1
alexmiller 2019-04-23T04:13:55.088900Z

and you already have aot'ed

alexmiller 2019-04-23T04:14:20.089100Z

https://dev.clojure.org/jira/browse/CLJ-1208

seancorfield 2019-04-23T04:16:56.089300Z

Gotcha!

alexmiller 2019-04-23T21:50:41.092Z

In case anyone happens to notice and wonders, I am actively working on moving the last useful vestiges of the old dev wiki https://dev.clojure.org/display/community to either http://clojure.org or some kind of archive (still TBD for the design pages) and I'm planning to fully decommission the old site. This ancient version of Confluence has become an active attack vector for this box.

alexmiller 2019-04-23T21:51:44.093100Z

Additionally, I am working on migrating jira to a modern cloud instance of jira. Lot of tbds still but it's in work.

seancorfield 2019-04-23T21:52:31.093800Z

Awesome! I know that's unpleasant work but I appreciate it!

👍 2
alexmiller 2019-04-23T21:53:59.094200Z

it's like jabbing yourself in the eye with a stick

3
2019-04-23T22:49:15.094700Z

I assume this is in scope? https://dev.clojure.org/display/design/test.check I put some non-trivial stuff there

2019-04-23T23:14:35.095Z

but it's like, a shiny stick, right? 🙂