clojure-europe 2025-11-05

Morning πŸ₯±

Morning

Good morning!

Good nailing it morning. Actually the opposite. What do we call that?

unnailing?

Nailing it has some more powerful connotations so I’m looking for something of an antonym to the phrase πŸ€·πŸ»β€β™‚οΈπŸ˜…πŸ˜…πŸ™πŸ»

ask ChatGPT?

🚫 1

De-fanging it πŸ§›β€β™‚οΈπŸ¦·

sounds painfull

so good in that sense

Human thoughts only plz

hmmmm high expectations πŸ˜‰

I’m so glad you’re joking. This group doesn’t disappoint

❀️

Though it sometimes feels like pulling teeth πŸ₯

I haven’t a clou

1

Talking of claws

πŸ‘ 1

This civitas post made me understand when to use scittle https://clojurecivitas.github.io/scittle/presentations/browser_native_slides.html

🍬 2
πŸ”₯ 3

Wow, that's a great tour of scittle

(I don't do much cljs work so I hadn't really understood when to use one rather than another)

what are people's takes on all the "digital sovereignity" discourse? If you're working at an EU company, are there conversations happening about becoming less reliant on US cloud providers?

A little late to the party: I’ve moved my personal stuff off US hosts, minus some things on Apple’s servers (they’re proving the hardest for me to let go for social reasons), and I’m considering starting a new company around getting EU government agencies off US platforms and onto open source systems. Sadly, many parts of the German government are extremely attached to MSFT products πŸ€¦πŸ»β€β™‚οΈ

πŸ‘ 3
πŸ‘ 1
πŸ₯΄ 1

@jackrusher where do we submit our CVs?

πŸ€” 1

Yeah, I'd sign up. Maybe a coop to resist being bought up by a US company?

2

actually, aren't you both murican?

Neither of us πŸ˜†

Only when it is funny

See? Funny!

πŸ’― 1
πŸ˜‚ 1

I'm seriously considering it personally and for the company. I'm not super happy about losing services b/c the orange guy wakes up on the wrong side of the bed

tho it is made me worry about any tech where there is a single company that can be pressured by a government so I'm mostly trying to double down on FLOSS as a mitigation

πŸ’― 1

I'm not sure if I need to keep things hosted in the UK or not as I'm not sure the UK will always end up on the same side as the EU

There are discussions here internally and the official line is that we don't move at the moment (we use both AWS and Azure a lot). And if things change that will be reviewed.

I fear for both of us that if we don't move now that when we do need to move it will be too late

πŸ’― 1

I should probably sync my google docs and fetch my email more often if I'm not going to move yet

I'm not too tied to github and we're not using AWS/Azure/GCloud for anything (other than as comms w/clients)

but we are "enterprise", so different things are important to people I guess

yeah, in that you have more money to move and the risk will have much higher impact if it is realised. πŸ˜‰

of course, but that is above my pay scale.

Oh, that's what enterprise means

I'd rewrite it all in Clojure/Rama. 3 datacentres in different locations with multiple machines in each and that way provide availability etc. But jut because I think it would be really cool IMHO.

πŸ˜‚ 2

I also think it would be cheaper... but can't really prove that of course. and "not invented here" would kick in as well.

I don't write clojure because it is my identity. I chose it because it is fun and I like speaking to other people who write clojure

The only possible rational argument is that a language with such little syntax and referential transparency is easier for a part time coder like me

exoscale are getting serious but we still have deps on US SAAS :(

😿 1

I work at a university and the infrastructure that we use for our homegrown software is already on-prem Red Hat servers, no AWS or anything like that. The real sovereignty issue is how ingrained the use of Microsoft Office, Microsoft Teams, and Outlook/Exchange is.

πŸ‘ 3
πŸ‘πŸΌ 1

There is no attempt at changing this Microsoft office suite situation at the uni at all, but at least at our little centre we are 100% open source and only running on Linux servers.

πŸ˜‡ 3

I also think that a lot of programmers are thinking about what they'd like to do for their next job (either monetarily or just for the fun of it) and this drives a lot of tech choice. Saying you learned perl from the perl book guy would look good on a resume, and lots of things that make a company survive or die are out of the control of the tech team.

(In case you are wondering I'm not really buying the guy's argument)

CV driven development is a thing of course

and I do think that is logical

as is wanting to do things that are more fun and perl might have looked like "more fun" than PHP given that team

Good morning

Burning off days off, so I'm having one in the middle of the week. Feels weird

Is there such a thing, or a use for something like (take-while-having-seen pred coll) where the pred looks at all the items accumulated so far? Like (take-while-having-seen #(< (apply + %) 10) [3 5 1 1 7 8]) ;;=> (3 5 1)

(defn take-while-having-seen [pred coll]
  (->> (reductions conj [] coll)
       (take-while pred)
       last))

I think I would write your thing differently because of performance. I think I would make a sequence of items collected so far and their sums so I don't have to do the sum over and over again

but it depends on your use case whether this makes a difference or not

This notion is an offshoot detour of a concrete problem that could probably be solved in a myriad of ways. But for take-while-having-seen, I was imagining more complex preds that could depend on the exact makeup of the accumulated values.

Nice brief implementation there! I need to get more use of reductions

You could also use the take-while transducer with a stateful fn?

(sequence (take-while (let [total (volatile! 0)] (fn [x] (< (vswap! total + x) 10)))) [3 5 1  1 7 8]) ;; => (3 5 1)
(edited to change the halt-when transducer to take-while)

πŸ’― 1
πŸ€“ 1

there might be something in xforms for this

The "window" thingy seems esque, but not quite there.

"window" thingie?

In xforms

I think I'd just go with @l0st3d’s solution, no libs needed

Yeah sure 😊 seems great.

the lazy take-while (non-transducer) version also works, if we're adding state:

(vec (take-while (let [total (atom 0)] (fn [x] (< (swap! total + x) 10)))
       [3 5 1 1 7 8]))

sometimes you just need some state :)

Indeed! It is essentially a stateful thing I'm asking about.

TIL about *file*

πŸ”₯ 1

it's absolutely lovely πŸ€— I've used it to make a REPL snippet to compile single-page Clerk documents for my web site! I stick this in the bottom of ny namespace:

^{:nextjournal.clerk/visibility {:code :hide :result :hide}}
(comment
  ((requiring-resolve 'nextjournal.clerk/serve!) {:browse true})
  ((requiring-resolve 'clojure.repl.deps/sync-deps))
  (clerk/build! {:paths [(fs/file-name *file*)] :out-path "."})
  (clerk/clear-cache!)
  ,)