Fork me on GitHub
#clojure
<
2019-10-31
>
ahungry02:10:38

hey everone

ahungry02:10:08

But, if I want to have multiple subs on one pub (same topic) - whats the best way to do that?

ahungry02:10:47

essentially I want many things to be able to register/listen/subscribe for an event,and when a publish goes off, they get the data and run something, but do not block each other or know about each other in anyway (similar to redis pub/sub) - is core.async the wrong tool for that?

ahungry02:10:30

As it is, if I register more than one sub on the pub/topic/chan, I have to do a pub for each sub and they seem to go in order

hiredman02:10:50

That is not correct

hiredman02:10:12

They do go in order, but a single published message will be sent out to any channel subscribed to whatever topic fn returns

hiredman02:10:25

Internally the pub creates a mult for each topic and each subscribed channel taps the mult

ahungry03:10:28

What am I apparently doing wrong here? One go-loop per sub?

ahungry03:10:46

(def input-chan (chan))
         (def our-pub (pub input-chan :msg-type))
         (def output-chan (chan))

         (defn fire                                                                                                                                                       
           "Send in a message / payload that we'll publish to one or more listeners."                                                                                     
           [topic m]                                                                                                                                                      
           (>!! input-chan {:msg-type topic :data m}))

         (defn listen                                                                                                                                                     
           "Recv a message / payload that we'll run some function against."                                                                                               
           [topic f]                                                                                                                                                      
           ;; pub topic channel                                                                                                                                           
           (sub our-pub topic output-chan)                                                                                                                                
           (go-loop []                                                                                                                                                    
             (let [{:keys [data]} (<! output-chan)]                                                                                                                      
               (log/info "Received an event on topic: " {:topic topic :data data})                                                                                        
               (f data)                                                                                                                                                   
               (recur))))

         (listen :foo prn)
         (listen :foo (fn [x] (prn "Hello from the second one" x)))

         ;; Called first, it only runs code from the initial listen                                                                                                       
         (fire :foo 44)
         ;; If I call a second time, it then runs the second function 

ahungry03:10:11

I want the rest of my app to be able to just import "listen" or "fire" from here, and not have to think about whats going on

ahungry03:10:21

I could just do with futures and a col of fs I guess

hiredman03:10:28

You are using double bang operations in a go block, big no no

ahungry03:10:43

but core.async seemed to come up the most for pub/sub stuff - the behavior is still present with single, sorry, the double was a stupid guess-and-hope attempt

ahungry03:10:30

(edited the sample - same behavior)

hiredman03:10:30

If you are restarting your repl the executor used by go blocks is likely all jammed up with blocking double bang operations

ahungry03:10:02

I did a fresh repl reload, same behavior. I'll do some more reading I guess

ahungry03:10:25

is the main use case for core.async to solve concurrency issues with code that has a lot of wait/idle time? (such as long db query or remote http request - basically similar use cases to js Promise.all ?)

alexmiller03:10:22

no, not primarily. it's best for decoupling independent parts of your application with channels (queues) and/or building staged pipelines of work

ahungry03:10:49

Any idea what I'm botching in that snippet above?

bfabry03:10:06

hiredman is right that you should not use >!! or <!! inside a go block. however another problem is you’re creating two go blocks both pulling from output-chan. (every time you execute listen you’re starting a new go-loop)

alexmiller03:10:10

unfortunately, I do not have time to read it atm but I can look at it tomorrow

ahungry03:10:51

My use case - I have a log scanner that reads lines using RandomAccessFile as lines are added - based on line regex matches, I want to fire off publishes that dont wait for anything at all. Then, I want other parts of the system to be able to sub to those particular line msg-types

ahungry03:10:28

how would I "listen" with multiple function callbacks without setting up a go-loop for each? (I want the body of the go-loop to come from a function sent in at sub time)

ahungry03:10:40

so I may fire off something like (fire :system-down-line {:date (some-date)}) - then my (potentially many independent and unaware of each other) listeners hears it and does something

ahungry03:10:20

if I have to store a collection of fns, I don't see what I'm gaining with channels vs just applying my list of fns via pmap or something in a future

bfabry03:10:57

I actually can’t see why your code is behaving the way it is, other than having 2 subs subscribing to the same topic using the same channel is weird and might do something unexpected. what happens if you make it 2 different output chans?

ahungry03:10:29

https://rupsshankar.tumblr.com/post/66648884392/demystifying-coreasyncs-tap-and-mult - that suggests maybe mult and tap accomplish what I'm envisioning?

ahungry03:10:37

oh thanks @bfabry - that was it

ahungry03:10:46

(defn listen                                                                                                                                                     
           "Recv a message / payload that we'll run some function against."                                                                                               
           [topic f]                                                                                                                                                      
           ;; pub topic channel                                                                                                                                           
           (let [output-chan (chan)]                                                                                                                                      
             (sub our-pub topic output-chan)                                                                                                                              
             (go-loop []                                                                                                                                                  
               (let [{:keys [data]} (<! output-chan)]                                                                                                                     
                 (log/info "Received an event on topic: " {:topic topic :data data})                                                                                      
                 (f data)                                                                                                                                                 
                 (recur)))))

bfabry03:10:09

yeah. from the description of what you want pub/sub should totally satisfy it

ahungry03:10:17

awesome thanks everyone! 🙂

bfabry03:10:48

the documentation is not perfectly clear, however the consequence of this https://github.com/clojure/core.async/blob/a25ae2fb44f0bc2828377866443ed638beeed9c9/src/main/clojure/clojure/core/async.clj#L869 I believe is that a channel can’t be subscribed to a topic more than once

jrychter11:10:49

I am looking at switching to building with deps, and I wonder: my current build process uses the lein git-version plugin to produce a resources/version.edn file containing info like {:tag "5.5.0", :ref-short "4b3619b1"… } before the main build is done. That file is then slurped by a macro, so that I can use the information during the compilation. Any hints on how to produce this (e.g. run git) with clj? Or should I fall back to doing this in a top-level Makefile before running clj?

mgrbyte12:10:18

Currently using metav for this purpose. Found it on: https://github.com/clojure/tools.deps.alpha/wiki/Tools

jrychter12:10:23

Oooh, interesting — metav seems to do what I need (spit the info into an EDN file), but there is still the question of running it before the main build. I guess a top-level Makefile is the way to go for now.

ghadi12:10:15

@jrychter I usually echo git rev-parse HEAD into a file, then stuff the file into the jar

jrychter12:10:36

Right — so, a toplevel build script (similar to a Makefile in spirit), that calls clojure.

borkdude12:10:11

why call clojure?

jrychter12:10:55

Well, to build the main application after git info gets extracted.

jrychter14:10:25

So, what do people use to build AOT-compiled uberjars with tools.deps? I found https://github.com/tonsky/uberdeps, but it doesn't pre-compile.

dominicm14:10:31

clojure -e "(compile 'my.main)"

dominicm14:10:45

I run this, then with pack I pass -e classes to include the aot'd classes.

jrychter15:10:10

Thanks. It does make sense, but I'd need to think how to put it together with the rest of the build.

ben14:10:33

Hi all, I would like to compare how multiple versions of the same library perform on a set of tasks. Is there an easy way to load multiple versions of the same package into a project with lein? Is there another, better way to do this? I’m aware that I could run the tests for each version separately, with the differing versions handled with different :profiles, but this doesn’t scale well above a handful of versions.

andy.fingerhut15:10:56

One possibility is to create different versions of the library with some encoding of the version number in their name, so they have different names. That can be as small as a 1-line change, or copying a file and a one-line change, or it might be changes to many source files, depending upon the library.

andy.fingerhut15:10:07

and it assumes you have access to the source code of that library.

andy.fingerhut15:10:10

The other would be to write some kind of script that changes your :profile contents (assuming by that you mean you are using Leiningen, so creating different project.clj files for each run, but automated, not manual)

ben15:10:39

I guess the other thing I don’t like about the :profile approach is that then I have to do any comparison between the different versions as another separate step. I’ll take a look at the option of altering the name of the library. Thanks, Andy

andy.fingerhut15:10:01

Multiple libraries with different names approach, loaded into the same JVM process, also opens up the possibility that things will not work because the library does some kind of global variable or other resource usage that causes it to conflict with itself. Not all libraries do that, but just so you are aware of the possibility.

jrychter14:10:00

Hmm. So after going through the build tools: uberdeps, depstar and Pack do not do global AOT, badigeon is more of a library than a tool, and cambada breaks with an error.

dominicm15:10:49

Did you see my thing about using compile?

kenny15:10:03

When I was running some tests that required :aot :all, I ended up switching to lein. None of the tools-deps options would compile everything. It was kinda unfortunate since everything else we do is in tools-deps.

vlaaad15:10:44

why not call compile function with root ns symbol before running tests?

kenny15:10:46

IIRC, I still needed to include .clj files in the final artifact.

vlaaad15:10:29

compile just creates class files, you can then include both them and clj files in an artifact

kenny15:10:04

But I think it would fail unless certain .clj files were on the classpath at runtime. We wanted to bundle without source.

vlaaad15:10:36

I'm currently developing a (yet unreleased) library with tools deps that needs some aot, if you are intersted in example: https://github.com/cljfx/css/blob/master/release.sh

vlaaad15:10:32

it has compile.clj script that just aot-compiles namespace I need AOTed into classes folder, and then it gets packed using depstar, since I have "classes" in :src

jrychter15:10:28

Well, I think I will hold off on migratoin and stick to building with leiningen for now, until things settle down a bit. It's a big app, and time is very limited.

seancorfield15:10:17

@jrychter We build all our (uber) jars at work for production deployment with depstar but we do not AOT anything. We don't see the point of using AOT.

seancorfield15:10:47

I have an open source library that requires AOT on one namespace, that uses deps.edn tooling https://github.com/seancorfield/cfml-interop/blob/master/deps.edn

ghadi15:10:49

depstar supports AOT @jrychter , you put an AOT alias with an extra directory, then call compile to do the compilation on the namespace of your choice

seancorfield15:10:20

That cfml-interop library is packaged with depstar -- see the :build alias in that file I just linked.

dominicm16:10:32

Most of the packaging tools do.

ccann16:10:43

Is it a code smell to use not-empty on a string?

acron16:10:35

It could lead to confusion, as people may assume you mean "not-blank"

lukasz16:10:12

"it depends" 😉

lukasz16:10:23

we use it a lot in our validations

alexmiller16:10:32

should prob prefer clojure.string/blank?

👍 3
ccann16:10:38

anecdotally, I see people do it a lot

alexmiller16:10:58

not-empty will coerce a string to a sequence which seems like it's doing work it shouldn't

👍 1
seancorfield16:10:48

We use it for situations where we want either a non-empty/non-blank string or nil in a threaded expression so clojure.string/blank? doesn't work there.

ccann16:10:04

This is the context I used it in, actually, but some found it confusing because not-empty indicated the result might be a collection

seancorfield16:10:08

(some-> s str/trim not-empty) for example

alexmiller16:10:22

given that I almost always use blank? with not, I kind of wish there was an optimized not-blank?

☝️ 2
orestis17:10:27

Also a very common spec predicate

Derek Passen16:10:14

Funny. I used (complement str/blank?) yesterday

lukasz16:10:40

@alexmiller absolutely agree, a quick look in a couple of our codebases reveals some kind of implementation of not-blank

alexmiller16:10:22

I wouldn't just not blank? either, the impl can exit earlier in this case

alexmiller16:10:31

maybe that's no different, but anyhow

thetalogn16:10:16

Hi all, I have a project that depends on https://github.com/mikera/clisk and I am having problems compiling the project with this library. When running the uberjar I get the following error: java.lang.IllegalStateException: Attempting to call unbound fn: #'clisk.functions/sigmoid It shows for any call to a clisk function. I tried to make a separate test project where I have only clisk but it results in the same error. I also tried running the test project with deps edn and then I get this error: clojure.lang.Var$Unbound cannot be cast to clojure.lang.DynamicClassLoader

ataggart17:10:14

When using clojure.test.check, is anyone aware of a way to decorate the various clauses with explanatory text, akin to clojure.test/testing, such that it is included in the output when tests fail?

noisesmith17:10:48

I would just use test.check inside deftest / testing / is

noisesmith17:10:21

each is assertion can have its own explanatory text

ataggart17:10:05

Ah, I've been using clojure.test.check.clojure-test/defspec

ataggart17:10:56

Ok, I'll take a look at how to do it that way.

Derek Passen17:10:23

^ the checking macro

👍 2
eoliphant17:10:16

Hi I have a quick question on transducers, i’m using them for a little bit of ETL, and so far everything works great. However, at run time, I’m going to want a bit of logging in the mix at certain stages for better operational visibility. Is a simple log transducer at the desired points in the composed xform the best way to do this?

noisesmith17:10:22

that's what I would use, yes - something as simple as (map #(doto % some-log-fn)) should suffice

unbalanced17:10:53

My personal experience is that this works very well -- with the caveat that transducers were not designed for side-effecty xfns.

noisesmith17:10:30

some most transducing contexts are eager, and side-effecting fns are fine there

unbalanced17:10:11

Per Mr. Hickey's talk on transducers, IIRC. Using side-effects is an "at-your-own-risk" proposition

unbalanced17:10:31

But I'm also adding that I do this frequently

unbalanced17:10:44

(for logging specifically)

eoliphant17:10:55

yeah I’m basically pulling stuff into datomic, but what we’re doing is a bit more involved than say the example in the docs for bulk loads,but same basic principle. set it up, then call pipeline..

unbalanced18:10:04

I think he's saying you might not want to be doing things like augmenting from databases in the middle of an xfn chain

unbalanced18:10:23

or doing http requests or whatnot

eoliphant18:10:42

ironically.. that’s some of what we need to do lol

unbalanced18:10:59

they were for data transformations

unbalanced18:10:33

but that doesn't mean you can't it's just saying use extra awareness when doing so

noisesmith18:10:38

I don't have the context you are referencing @goomba, but in an eager context (into, transduce, a core.async chan, eduction etc.) I don't see what the problem would be with a side effecting transducing function

unbalanced18:10:08

in an eager context, sure. But if you're consuming from a channel or you have a stateful transducer dot dot dot

unbalanced18:10:37

I'm saying you can do it just be aware there are extra corner cases to watch out for

noisesmith18:10:39

a channel is eager, and that's why it's safe

eoliphant18:10:40

all my stuff is eager thankfully

noisesmith18:10:00

it's laziness and retries that make side-effects iffy

unbalanced18:10:01

a channel is eager when there's something on the channel

noisesmith18:10:07

it's eager period

noisesmith18:10:25

what do you think eager means?

unbalanced18:10:49

if there's nothing on the channel it will block until the next thing pops in

noisesmith18:10:12

right, as it should, and if your reducing function blocks on IO, it is still eager too

noisesmith18:10:16

channel ops are IO

ataggart18:10:52

equivalently, channels are not lazy.

unbalanced18:10:17

:thinking_face:

noisesmith18:10:41

there can be gotchas of course if you are trying to use lexical scope to manage a resource and your transducer tries to use the resource and escapes scope (common gotcha eg. with with-open)

noisesmith18:10:46

but that's not an issue with transducing functions, it's an issue with with-open

unbalanced18:10:49

I'm not really sure "eager" can apply in an I/O context

noisesmith18:10:02

it absolutely can

unbalanced18:10:20

I think eager only applies when data exists

unbalanced18:10:59

can a collection of items be consumed lazily or eagerly -- that's testable. How do you eagerly consume hypothetical data?

noisesmith18:10:37

@goomba in clojure if you don't use a delay or a lazy function, the code is eager

unbalanced18:10:02

You have a source for that, or is it your opinion? What happens if there's an unhandled exception? I don't think eager/lazy is defined for those situations.

noisesmith18:10:38

from clojure core devs, I've been told the only thing that's lazy in clojure is the LazySeq type and its derivatives

noisesmith18:10:59

and delay is an alternate, more manual, way of postponing evaluation

unbalanced18:10:16

you mean lazily evaluated

noisesmith18:10:31

there's no such thing as lazy that isn't lazily evaluated in clojure

unbalanced18:10:48

I agree, but you can't evaluate data that doesn't exist

noisesmith18:10:12

I'm sorry but this is absurd, blocking on an event is not laziness

unbalanced18:10:30

this is why I'm saying transducers were designed around pure data and not intended to be used with interposing I/O -- we can dance around the semantics all we want. Everyone is welcome to use interposing side-effects but then they can get into these discussions lol

noisesmith18:10:01

"this is why" what is why? there's nothing about blocking on IO that causes correctness issues with transducers

unbalanced18:10:39

Are transducers somehow more provable than regular functions when it comes to IO?

noisesmith18:10:16

are they somehow risky in a way that a normal function isn't in an IO context?

unbalanced18:10:04

They are at least as risky as regular functions in an I/O context

noisesmith18:10:35

OK but clojure isn't a pure language and I don't see why transducers would be called out specially here

noisesmith18:10:11

I'm hoping there's something you are referring to that I didn't know, but so far I'm just seeing an assertion that isn't congruent with other things I know about clojure

unbalanced18:10:45

Because if you're running a production system, and you don't want potentially masked bugs, then you should probably take special care when implementing side-effecty xfns in transducing contexts. I'm not sure why this is coming across as impractical advice.

noisesmith18:10:35

https://groups.google.com/forum/#!topic/clojure/SVaFtQgtolc from Stuart Sierra: > Transducing/reducing is always non-lazy, so it's less risky to have side effects in a reduce compared with side effects in a lazy sequence.

unbalanced18:10:06

Alright let me give you a concrete example

unbalanced18:10:24

partition-all

noisesmith18:10:48

the http://clojure.org page on transducers doesn't even mention side effects at all https://clojure.org/reference/transducers

unbalanced18:10:40

If you're consuming from a channel, augmenting with a DB, and logging, while using partition-all for chunking batched http requests -- you could have results that would surprise you

hiredman18:10:11

there are a lot of different parts of the things you guys are talking about, and you haven't even agreed which parts you are talking about or even what the common terminology for those parts is

hiredman18:10:30

so like, you are not going to get anywhere

unbalanced18:10:55

No, @hiredman. This is a neckbeard contest, obviously

unbalanced18:10:28

I'm playing the "highlander" theme song in the background right now

hiredman18:10:20

I suspect @goomba is talking about what I think I have seen called stateful transducers, which partition-all is one, it uses a mutable array list internally, so if you use that kind of transducer in a parallel context, like can happen with core.async, you will get surprising results

hiredman18:10:04

but sometimes people refer to defining a collection via a reduce operation (reifing CollReduce or whatever) as a transducer as well (I think this is not correct usage but people do it) because they are concepts that are introduced together

hiredman18:10:22

in which case, you can have some abstract notion of collection that only exposes a reducing operation where the items in the "collection" don't exist until you do the reducing, which is different from the lazy seq model, but in certain lights you might refer to as being lazy

unbalanced18:10:47

What are you a diplomat? 😄

noisesmith18:10:16

OK - you can have transducers that are not safe for parallel usage, I agree

noisesmith18:10:16

I only brought up reduce because it's something canonically eager

unbalanced18:10:44

Better said than me, @hiredman. You're also being very charitable -- @noisesmith called me out on some imprecise language and I got roped into a "spirited" debate 😛

hiredman18:10:14

which is a difference between lazy seqs and the reduce model, if you are defining a lazy seq, each step in the process is lazy, if you are defining via reduce you can have a "collection" where no work has happened which seems lazy, but as soon as you start working it is all or nothing (more or less)

noisesmith18:10:01

I don't think it's useful to conflate work that is indefinitely paused / blocked with laziness

unbalanced18:10:12

Ok at the risk of starting this all over again, I think we're in Clojure koan territory. Meaning this is a trick question. I.e. -- lazy/eager is by definition something that can only be applied in a functional sense. It really doesn't make sense in a non-functional context.

noisesmith18:10:23

that's false

unbalanced18:10:42

Is code that never gets executed eager or lazy?

noisesmith18:10:16

does code that never gets executed have bugs in it? it's an absurd question

unbalanced18:10:22

or undefined

seancorfield18:10:44

Take it to a thread please. This is a pointless (and very annoying) conversation for the whole channel to witness.

hiredman18:10:06

eager or lazy are properties of the abstract meaning (semantics) of the language (logic) not properties of a given execution of a program

2
hiredman18:10:36

execuse me?

unbalanced18:10:44

(had to start the thread somewhere)

unbalanced18:10:08

(as in "go here to continue discussion")

unbalanced18:10:50

and since they're logical properties, that's why they can only be defined in a logical (aka pure functional) context.

noisesmith18:10:53

but clojure has these properties and is not purely functional

hiredman18:10:05

all programming languages are logics (formal systems)

hiredman18:10:54

anyway, I am done, I thought you and noisesmith were talking past each other, but this is just nonsense

1
unbalanced18:10:30

Awww well thanks for joining. I thought it was fun. 🙂

joaohgomes18:10:22

Aren’t lazy and eager in the perspective of the consumer? I mean, just because the producer is not producing does not mean it is lazy. Whereas in lazy, the consumer has the discretion of saying when is enough… just throwing ideas here.

unbalanced18:10:08

Yeah it's a really good question. apparently some folks think it's pointless but I think it's kind of a thought provoking question.

unbalanced18:10:46

Because there are multiple views -- there's the syntactic view, the semantic view, and a behavioral view

noisesmith18:10:44

the frustrating thing is that you are using terms that have specific and precise definitions in clojure in loose and incompatible ways; as far as other people learning or understanding the language is concerned you are muddying things and making them more difficult, which makes me feel a need to make a correction or objection for their sake

noisesmith18:10:51

but this conversation is clearly pointless

unbalanced18:10:21

this is clojure, not clojure-beginner. Where else do you expect this conversation to go?

noisesmith18:10:22

I object to fun that adds unneeded difficulty and confusion for others

unbalanced18:10:12

I'm not just saying it for fun -- I'm sharing practical advice from production systems that you need to treat stateful, side-effecty transducers with respect or they'll bite you.

unbalanced18:10:27

I disagreed with your cavalier assertion that it's exactly the same as a pure function

unbalanced18:10:47

I think saying that is equally damaging to folks who are learning

noisesmith18:10:36

I tried to prompt for a version of what you were saying that didn't contradict usage of terminology in clojure, and when hiredman offered it I agreed, anyway I'm done here

Andreas S.20:10:17

Hello I have a problem which is I guess Unicode related, could someone help me trying to understand the issue better?

seancorfield20:10:15

If you explain the issue, maybe someone can help...

Andreas S.20:10:26

hello sean! Ok I have a programm in java that uses jgit API to acess data from a github repository, in java it works as expected , but in clojure I get strange symbols for some unicode characters

Andreas S.20:10:57

I'm runnig my code from the clojure REPL on windows

Andreas S.20:10:55

the clojure program does the same thing: query the git repository and displays some commit data

Andreas S.20:10:51

any suggestions how to debug or fix this problem?

andy.fingerhut20:10:02

Some terminals or REPLs may have ways of handling non-ASCII characters that cause them to display strangely.

andy.fingerhut20:10:30

Looking at a sequence of Unicode code points in both environments can be a bit tedious, perhaps, but at least should always render properly on the screen.

hiredman20:10:51

how are you starting your clojure repl?

andy.fingerhut20:10:28

In Clojure, (map int some-string) will show a sequence of UTF-16 code points.

hiredman20:10:13

in a lot of places in java apis you can either pass in a character encoding or use a system wide default

Andreas S.20:10:26

@hiredman I type: lein repl

hiredman20:10:49

you should compare the value of the file.encoding property between jvms

hiredman20:10:13

how are you running your java program?

Andreas S.20:10:23

how do I acess this value from the clojure REPL?

Andreas S.20:10:36

my java programm is running with intelliJ

noisesmith20:10:01

user=> (System/getProperty "file.encoding")
"UTF-8"

hiredman20:10:05

there are two places character encoding stuff is happening

hiredman20:10:16

1. on the input reading in data 2. the output printing out data

hiredman20:10:35

my guess now is whatever terminal you are running lein in is not setup for utf-8 output

Andreas S.20:10:57

the REPL prints

Cora21:10:04

isn't that the default encoding in PDFs?

Cora21:10:09

weird aside, ignore me

Andreas S.21:10:12

hmm this seems really bad, an Idea how to get a unicode shell in windows?

Andreas S.21:10:57

but I don't have x there and the project uses seesaw too...

bfabry21:10:07

try just adding “Dfile.encoding=UTF-8” to your project.clj :jvm-opts and see how it goes I reckon

👍 1
andy.fingerhut21:10:43

Probably needs a dash before the D?

bfabry21:10:52

doh, yes definitely does

Andreas S.21:10:21

ok now the property prints: zettel-clj.core=> (System/getProperty "file.encoding") "UTF-8"

Andreas S.21:10:37

but the characters are still messed, which is because of the font?

bfabry21:10:23

so you run a java program that works correctly, does it run and output in this same terminal?

Andreas S.21:10:58

the java programm runs on intelliJ

bfabry21:10:20

are you able to run it from this terminal to check?

1
bfabry21:10:06

the answer might be to update windows lol https://github.com/microsoft/terminal/issues/306

Andreas S.21:10:06

I just checked it displays now correct in the seesaw swing elements, thats good enough for me

Andreas S.21:10:19

thank you very much clojure community for your help and patience 🙂

bfabry21:10:28

yeah I’m pretty sure it’s the terminal. so files, ui elements etc will all be fine

bfabry21:10:49

ALSO, if you get the cursive plugin for intellij and use that to develop your clojure, and use its repl, it will probably work fine

Andreas S.21:10:23

hm a colleague is all over it, but i'm undecided

Andreas S.21:10:37

intelliJ is quite heavy and I have to get a licence and stuff

Andreas S.21:10:46

its just a toy project is it really worth it?

sogaiu21:10:04

if your project is open source then the license for cursive is at no cost iirc

bfabry21:10:19

fair enough, the repl in vim, emacs, atom and vscode probably would work as well

Andreas S.21:10:40

I usevscode actually

Andreas S.21:10:50

to edit the source, how do I get a REPL there?

dpsutton21:10:38

i see one called betterthantomorrow.calva

dpsutton21:10:47

no idea which one is correct

Andreas S.21:10:39

calva is better?

bfabry21:10:36

I’ve never used vscode so I’d go with the judgment of someone who has

dominicm21:10:40

Calva is better

Andreas S.21:10:05

I'll try it thanks again everyone, cya

darwin21:10:14

deps question: is it expected :local/root coordinate respects :paths in library’s deps.edn? I cannot seem to get it working

alexmiller21:10:53

It should if I understand your question

darwin21:10:54

ah, it works, for some reason classpath caching prevented the change to take effect, deleting .cpcache in the main project using :local/root resolved the issue

alexmiller21:10:18

Changes in the local project won’t invalidate the cache

alexmiller21:10:35

So use -Sforce if you know it’s changed

darwin21:10:06

ok thanks, will try to remember, just starting with deps

alexmiller21:10:05

This is a known issue

pez21:10:21

@andreas.scheinert please feel welcome to ask about Calva in #calva-dev .