Ivan “CLOVIS” Canet's Avatar

Ivan “CLOVIS” Canet

@ivcanet

Kotlin developer & teacher @ 4SH, learn more about me: ivan.canet.dev Open source at https://opensavvy.dev • @opensavvy.techhub.social.ap.brid.gy Organizing the Kotlin Bordeaux User Group at https://bordeauxkt.io

362
Followers
296
Following
1,056
Posts
14.09.2023
Joined
Posts Following

Latest posts by Ivan “CLOVIS” Canet @ivcanet

Preview
Kotlin tricks: Mandatory varargs - Ivan “CLOVIS” Canet Software engineering, open source and computer security

New article!

Did you know #Kotlin has mandatory varargs?

ivan.canet.dev/blog/2026/03...

09.03.2026 21:16 👍 11 🔁 4 💬 2 📌 1

Having talked to a few teachers, the secret seems to be ‘have all the grades be based on oral exams’.

Maybe they can't write the code, but if they can understand what the LLM wrote, that's still a skill.

09.03.2026 19:32 👍 2 🔁 0 💬 0 📌 0

Technically not, but it's very useful as ‘recursive navigate to usage’

08.03.2026 22:25 👍 1 🔁 0 💬 0 📌 0

My favorite is ‘data flow to here’ which isn't even in this popup

08.03.2026 22:06 👍 0 🔁 0 💬 1 📌 0

(note also that in the Kotlin version, the argument to the lambda is implicit for these methods, this is another language feature: these are extension lambdas, not regular ones, which implicitly expose the instance they're called on)

Together, these features allow very expressive and concise DSLs

08.03.2026 22:05 👍 0 🔁 0 💬 0 📌 0

In Rust, this would look like

let retry = pipeline.job(build, |job| {
job.script(|script| {
script.shell("...");
});

job.retry(2, |reason| {
reason.onExitCode(127);
});
});

(Sorry if it's not exact, I haven't written Rust in a while)

08.03.2026 22:03 👍 0 🔁 0 💬 1 📌 0
			// Retry with when type
			val retryWithWhen by job(stage = build) {
				script {
					shell("echo 'Retry with when type test'")
				}
				retry(2) {
					on(RetryCause.RunnerSystemFailure)
				}
			}

			// Retry with multiple when types
			val retryWithMultipleWhen by job(stage = build) {
				script {
					shell("echo 'Retry with multiple when types test'")
				}
				retry(2) {
					on(RetryCause.RunnerSystemFailure)
					on(RetryCause.ApiFailure)
				}
			}

// Retry with when type val retryWithWhen by job(stage = build) { script { shell("echo 'Retry with when type test'") } retry(2) { on(RetryCause.RunnerSystemFailure) } } // Retry with multiple when types val retryWithMultipleWhen by job(stage = build) { script { shell("echo 'Retry with multiple when types test'") } retry(2) { on(RetryCause.RunnerSystemFailure) on(RetryCause.ApiFailure) } }

Other people have already answered the questions, but I wanted to share an example of how it looks like in practice

Each call is a function + the lambda it receives, it's very convenient to concisely describe complex structures (here, GitLab CI config instead of YAML)

08.03.2026 22:03 👍 0 🔁 0 💬 1 📌 0

Like, Git isn't a blockchain, but it's decentralized and there's an append-only ledger, so if I were mandated to use blockchain tools just because it's the hype, then I'd claim Git counts

08.03.2026 21:37 👍 1 🔁 0 💬 1 📌 0

I wish we had nice well-defined terms to talk about stuff, but I also much prefer branding a feature that works as the buzzword-of-the-moment than actually having it be rewritten as a worse version using an unrelated tech just because it's in the hyper circle

08.03.2026 21:37 👍 1 🔁 0 💬 1 📌 0

It is also a way of riding the hype. If rebranding an existing feature as ‘AI’ even though it's just a basic predictive algorithm makes it sell more and makes the clients happy...

08.03.2026 21:37 👍 2 🔁 0 💬 1 📌 0
NextCloud notification with 3 quick actions: cancel, cancel & cancel.

NextCloud notification with 3 quick actions: cancel, cancel & cancel.

Okayyy, I get it

08.03.2026 11:14 👍 3 🔁 0 💬 3 📌 0

Challenge for people who believe Claude *is* conscious and use it anyway: Explain how you’re not a slaver.

07.03.2026 19:04 👍 2541 🔁 548 💬 74 📌 24

I'm nominated in ‘online presence’, vote for me!

07.03.2026 15:40 👍 3 🔁 0 💬 0 📌 0
‘Humans use Energy and Water too’ An engineer I admire was lamenting about AI. He said that his new programming agent is excellent at fixing bugs! And all that it costs is a bunch of energy and many litres of water. He said that he co...

✊🏻

07.03.2026 04:33 👍 23 🔁 8 💬 0 📌 2
Un mail de la BNP Paribas dont le sujet est "Ivan Canet, je vous aime… et votre argent encore plus"

Un mail de la BNP Paribas dont le sujet est "Ivan Canet, je vous aime… et votre argent encore plus"

Ils ont pété un câble…

(oui c'est un mail officiel)

06.03.2026 09:39 👍 2 🔁 0 💬 0 📌 0

again? :/

05.03.2026 13:09 👍 0 🔁 0 💬 0 📌 0

Yes, 100%

04.03.2026 19:30 👍 0 🔁 0 💬 0 📌 0

Oh yes you could. Have random ‘I'm adult’ paper tokens that you can buy at liquor stores or other places that already age-check.

Protection for children. Full anonymity. It can be done.

04.03.2026 16:46 👍 0 🔁 0 💬 1 📌 0
Preview
The AI Vampire This was an unusually hard post to write, because it flies in the face of everything else going on.

steve-yegge.medium.com/the-ai-vampi...

04.03.2026 11:02 👍 1 🔁 1 💬 0 📌 0

...I *hope* they would find a better name

04.03.2026 11:50 👍 2 🔁 0 💬 0 📌 0

I'm sure with hindsight they wouldn't name them this way 😅

04.03.2026 11:36 👍 2 🔁 0 💬 1 📌 0
Preview
Gradle vocabulary: projects, builds, artifacts… - Ivan “CLOVIS” Canet Software engineering, open source and computer security

Are you confused by Gradle terminology? What's a module, a configuration, a build, a project? Unless you're deep into Gradle, they probably aren't what you think.

I wrote an article to organize all of that → ivan.canet.dev/blog/2026/03...

04.03.2026 10:45 👍 8 🔁 2 💬 0 📌 1

Idea: halfway through your integration tests, switch to the new version, see what happens.

Just a heuristic, not as powerful as what the article describes, but it could be quite simple to set up?

28.02.2026 14:14 👍 3 🔁 0 💬 0 📌 0
What Functional Programmers Get Wrong About Systems - Ian Duncan Type systems verify properties of programs. Production correctness is a property of systems. The gap between these is where the interesting failures live.

This is a *very* interesting read on managing new versions of existing deployments.

www.iankduncan.com/engineering/...

27.02.2026 16:42 👍 5 🔁 1 💬 0 📌 0
Preview
Better Immutability in Kotlin aka "Value Classes 2.0" -- Motivation and Design Space · Kotlin KEEP · Discussion #472 We are happy to finally share a new KEEP proposal exploring the motivation and design space for better value classes in Kotlin -- an evolution of the current inline value classes aimed at making im...

Though, it won't be a big change on behavior, since value classes are moving towards doing what we use data classes for.

The Kotlin team is asking for your thoughts on what will probably become the roadmap for the next few years → github.com/Kotlin/KEEP/...

26.02.2026 17:40 👍 7 🔁 1 💬 0 📌 0

This may look like a small feature on the outside, but it will radically change how we write #Kotlin code.

Once this is implemented fully, almost all existing data classes will be replaced by value classes. This may be the most impactful change in overall code style in a while!

26.02.2026 17:40 👍 4 🔁 0 💬 1 📌 0
This is a screenshot from the Cucumber test framework titled "Sharing state between scenarios", with the content "Don't do it."

This is a screenshot from the Cucumber test framework titled "Sharing state between scenarios", with the content "Don't do it."

Nice xD

26.02.2026 15:48 👍 2 🔁 0 💬 0 📌 0

I'm curious, how are people positioned? Is it mainly based on follows?

26.02.2026 11:13 👍 0 🔁 0 💬 1 📌 0
Preview
Rework the BSON hierarchy (#112) · Issues · OpenSavvy / KtMongo • Alpha · GitLab Currently, we have: Bson: a stored BSON document BsonArray: a stored BSON array BsonValueWriter: a writer...

Have you used KtMongo? Are you planning to?

I'd love your thoughts → gitlab.com/opensavvy/kt...

24.02.2026 18:17 👍 0 🔁 0 💬 0 📌 0

It's not even fully rolled out yet!

21.02.2026 11:12 👍 0 🔁 0 💬 0 📌 0