clojure-europe

For people in Europe... or elsewhere... UGT https://indieweb.org/Universal_Greeting_Time
ordnungswidrig 2020-11-10T06:50:03.309300Z

Good morning!

2020-11-10T07:00:05.309600Z

Morning

plexus 2020-11-10T07:31:40.310400Z

Good morning! After a sunny weekend in Berlin we are back in Dauergrau territory ☁️

dharrigan 2020-11-10T08:02:35.310600Z

Good Morning!

plexus 2020-11-10T08:25:29.311300Z

is anyone else confused about the breaking changes in Clojure CLI around the -M alias?

1
borkdude 2020-11-10T08:32:03.311700Z

@plexus There have been discussions about this in #tools-deps.

borkdude 2020-11-10T08:35:22.312100Z

Are you confused about why they made a breaking change or about the change itself?

agile_geek 2020-11-10T08:54:16.312300Z

Bore da :welsh_flag:

jasonbell 2020-11-10T08:57:38.312500Z

Morning

raymcdermott 2020-11-10T09:37:14.313700Z

@plexus yeah seems pointless to change letters. I had a look on the #tools-deps channel but parsing Slack for meaning is pointless

raymcdermott 2020-11-10T09:37:28.313900Z

pointless good morning

raymcdermott 2020-11-10T09:38:26.314500Z

but I guess everything is alpha now, so it’s permitted under Rich law

borkdude 2020-11-10T09:41:10.315Z

The clojure CLI was never marked alpha anywhere. The library it is using under hood, tools.deps.alpha, is.

raymcdermott 2020-11-10T09:57:09.315700Z

is there a write up somewhere that explains all of the changes?

borkdude 2020-11-10T10:00:23.316500Z

the most important change: aliases are only used to change the classpath, to invoke clojure.main you have to explicitly use -M

borkdude 2020-11-10T10:00:53.317Z

so if you wrote clojure -A:test before,

borkdude 2020-11-10T10:01:02.317300Z

to run tests, this should now become clojure -M:test

borkdude 2020-11-10T10:04:34.318700Z

note that the -M option was already there the whole time, they just enforced this more

raymcdermott 2020-11-10T10:04:51.319Z

given that this conversation will go away next week … a link would be nice if you have one

raymcdermott 2020-11-10T10:05:35.319700Z

my understanding is that you should also do group/dep for maven assets now too

raymcdermott 2020-11-10T10:06:26.320100Z

which is a different part of the tooling but still it’s linked

borkdude 2020-11-10T10:07:19.320900Z

true. the latest clj-kondo will help you with that part btw

❤️ 1
thomas 2020-11-10T10:11:04.321100Z

morning

👋 1
plexus 2020-11-10T11:05:40.322300Z

right, but now someone in #kaocha wants to have the dependencies from their :server alias, but not the :main-opts, so I thought then you just use -A, but then you get a warning that you're not supposed to do that

plexus 2020-11-10T11:06:01.322800Z

and that confuses me, I thought you could use -A to get the dependencies but not the main opts from an alias

plexus 2020-11-10T11:07:38.323800Z

so yes I'm confused both about the fact that they are making breaking changes. I thought we had collectively been indoctrinated into not doing that. I'm also confused about the change itself, and the point thereof...

plexus 2020-11-10T11:12:14.324200Z

but I'll wait until someone does a write-up of the discussion in #tools-deps 😊

borkdude 2020-11-10T11:14:29.324600Z

@plexus The change can be annoying in situations like that

borkdude 2020-11-10T11:15:18.325400Z

If you ask about the reasons behind this, then you hear "we are trying to free up arg space for other things"

plexus 2020-11-10T12:09:51.326500Z

And this is why you don't start with single letter command line flags when designing a CLI interface :)

borkdude 2020-11-10T12:16:09.327900Z

@plexus Am I wrong, or does tools.cli enforce this?

borkdude 2020-11-10T12:16:22.328500Z

Not that the Clojure CLI is using this

pez 2020-11-10T12:16:43.328800Z

This change is creating confusion for Calva users. And it's also not super easy to fix it. It will be one more thing for the users to be aware of and take action on...

plexus 2020-11-10T12:56:01.330400Z

tools.cli does not enforce this, you can have long options only if you want. Kaocha mostly has long options, just a few one letter options for common things

borkdude 2020-11-10T12:57:58.330800Z

@plexus Then I have misunderstood tools.cli. How can you have options without short options?

plexus 2020-11-10T12:58:36.331200Z

Just put a nil in the first spot

borkdude 2020-11-10T13:01:16.331700Z

Thanks, TIL

mpenet 2020-11-10T15:24:39.333700Z

I am reaching a point where I am thinking that giant "state" datastructure I am juggling with everywhere should maybe be better as a datascript db

val_waeselynck 2020-11-10T15:45:32.334300Z

@mpenet in a browser app?

mpenet 2020-11-10T15:46:28.334500Z

no

mpenet 2020-11-10T15:47:14.335400Z

it's one of the rare cases where it would actually be handy in process, the thing I am messing with is growing and growning and we query it in various ways (and that's growing too)

mpenet 2020-11-10T15:47:36.335800Z

doesn't warrant a real db tho, we're still in tiny-data scope

val_waeselynck 2020-11-10T15:47:53.336Z

Seems sensible.

val_waeselynck 2020-11-10T15:48:39.336800Z

I think many people would gain from seeing DataScript not as an in-memory db, but really as a rich immutable data structure

mpenet 2020-11-10T15:48:56.337Z

indeed

val_waeselynck 2020-11-10T15:49:51.337500Z

That said, be aware that the current Datalog engine has a slow startup time.

val_waeselynck 2020-11-10T15:50:23.338Z

I'm actually considering to start work on AOT compilation of Datalog queries

val_waeselynck 2020-11-10T15:52:31.338800Z

It's a pity to have eliminated network calls, and to still have a 100µs "startup time" on your query engine, even for very dumb queries.

val_waeselynck 2020-11-10T15:53:03.339100Z

(you might already know this stuff of course)

mpenet 2020-11-10T15:55:21.340100Z

good to know, but it's a case where we can cache heavily if needed I think

mpenet 2020-11-10T15:56:32.340600Z

but the domain is tricky, state can change outside of our control/visibility

val_waeselynck 2020-11-10T15:58:06.341400Z

Isn't that last problem orthogonal to choosing the supporting data structure?

mpenet 2020-11-10T15:59:26.342Z

yes, I meant about the caching bit, might not be reliable to cache in that case.

dominicm 2020-11-10T16:02:47.342100Z

This warning will go away

dominicm 2020-11-10T16:03:07.342300Z

It's to help people who are doing the wrong thing transition