Fork me on GitHub
#clojure-europe
<
2023-08-11
>
grav05:08:24

Good morning!

otfrom08:08:22

got ☀️ got 🔋 need hotwater

otfrom08:08:27

I'd stay upwind of me

🦨 2
thomas09:08:58

TGIF!!!

2
ray10:08:16

🐝 happy

🐝 6
❤️ 3
RAMart10:08:33

👋 ☀️

maleghast11:08:11

Hello there everyone, long time no see 🙂. How’s you all doin’?

👋 6
ray11:08:15

Optimistic about the potential in retirement (not mine, or at least not yet)

😄 1
Ed12:08:29

Are you thinking that spec might actually see a non-alpha release Ray? ... or just hopeful that something else may come of it?

ray12:08:40

I mean, that would be great. I don't know why it stalled out, but if it was work pressure - and we get that - it would be a wonderful contribution.

Ed12:08:40

I can't disagree with anything you say ... 😉

😇 1
simongray13:08:23

insert skeleton waiting meme

Ed13:08:40

> I can't disagree with anything you say except intelij being better than emacs, obviously ... 😜

1
thomas13:08:17

VI!

6️⃣ 2
ray14:08:22

Roman numerals ftw

dharrigan14:08:44

(when-not (resolve 'clojure.core/parse-long)
  (defn parse-long [s]
    (Long/parseLong s)))

dharrigan14:08:12

yet when I pull in the namespace, it seems to return 'nil' for the resolve, thus it evals the (defn...

dharrigan14:08:50

i.e., (require '[foo.bar :as f]) gives me a WARNING: parse-long already refers to: #'clojure.core/parse-long in namespace: foo.bar

dharrigan14:08:39

I don't understand why the resolve would return a nil (obviously, I'm using clojure 1.11+)

dharrigan14:08:22

I guess it would be easier to do :refer-clojure :exclude [parse-long] instead. Although my question still remains 😉

borkdude14:08:02

This is because defn causes an analysis-time side effect, always creating the var. It's better to do this via a macro:

(defmacro when-not-exists [sym body]
  (when-not (resolve sym) body))

borkdude14:08:17

and then

(when-not-exists clojure.core/parse-long
  (defn ...))

dharrigan15:08:09

Ah, I see. Thank you!

dharrigan15:08:51

I didn't know that about defn and the side effect

borkdude15:08:07

it's more general than defn , it happens with each def

borkdude15:08:02

user=> (when false (def x 10))
nil
user=> x
#object[clojure.lang.Var$Unbound 0x5c20ffa8 "Unbound: #'user/x"]

gratitude 2
dharrigan15:08:38

gotcha! ta 🙂

reefersleep19:08:04

Hah, that's curious behaviour 🙂

reefersleep19:08:16

A little gotcha

ray16:08:52

Just https://www.youtube.com/watch?v=jTX45V5JuN4 by the ThoughtWorks CTO and her favourite fitness function is the Simian Army. This is nice but er, a bit fancy IMHO. Is there a term such as 1% architecture? By which I mean the FANGs are the 1% (or even 0.1% or 0.01% etc) and the rest of us can do monoliths and a DB without the need for monkeys?

otfrom16:08:29

not if you are trying to sell those sweet, sweet consultant hours

🤑 4
seancorfield17:08:05

@raymcdermott At what point does "a monolith and a DB" get complex enough to warrant more "advanced" approaches? I agree that the FAANGs of this world have crazy complexity scale issues to deal with but I think they also have some interesting insights into dev/test workflows to offer... Many decades ago, the small UK company I worked for was big into testing and software QA (and static analysis) and one of the things we worked on was mutation testing: you have a testing engine that makes small, random code changes and runs the test suite to see if you could detect the change/breakage. We did quite a bit of work on compilers, runtime systems, and test suites 🙂 So I inherently like the Simian Army / "chaos testing" stuff.

ray09:08:40

It’s definitely interesting technology. And of course there are patterns outside of monolith + DB (eg event driven) that are interesting. But I feel like there’s a significant danger of finding complexity in edge cases that won’t often happen or matter.

seancorfield16:08:20

True, you have to judge how likely you are to run into those edge cases -- and you have to be aware of the trade offs being made and whether they're appropriate trade offs for your company.

2
vijaykiran18:08:12

@slipset with Clojure meetup invite and skies with beautiful views - Norway is treating me good 😇

😍 7
🎉 4