Tootfinder

Opt-in global Mastodon full text search. Join the index!

@mgorny@social.treehouse.systems
2025-10-08 08:13:24

Sequoia PGP exemplifies everything that's wrong about #RustLang (don't mean this against Sequoia). It features a bunch of different CLIs, which is a reasonable design.
If Sequoia were written in C, these CLIs would probably be using some shared library. If Sequoia were written in Python, they would probably use a shared Python package. However, it's written in Rust, so every CLI is a huge binary with its own copy of subset of shared Sequoia code, built separately:
-rwxr-xr-x 1 root root 12M 10-08 06:36 /usr/bin/gpg-sq
-rwxr-xr-x 1 root root 4,7M 10-08 06:36 /usr/bin/gpgv-sq
-rwxr-xr-x 1 root root 21M 10-08 08:38 /usr/bin/sq
-rwxr-xr-x 1 root root 6,9M 10-08 08:38 /usr/bin/sqop
-rwxr-xr-x 1 root root 3,1M 10-08 08:32 /usr/bin/sqv

@mgorny@pol.social
2025-10-08 08:15:35

Sequoia PGP ukazuje wszystko to, co jest nie tak z #RustLang (nie czepiam się tu projektu Sequoia). Mamy kilka różnych binarek CLI, co ma sens.
Gdyby Sequoia była napisana w C, to najpewnie używałyby jakiejś biblioteki współdzielonej. Gdyby napisała była w Pythonie, to najpewniej mielibyśmy wspólną paczkę Pythona. Ale napisano ją w Ruście, więc każdy interfejs to odrębna, wielka binarka z włas…

@chrysn@chaos.social
2025-10-01 11:32:12

Just released: embedded-io 0.7.{0,1}, along with its -async and -adapter siblings. These #RustLang crates help #embedded systems abstract over byte data input and output, similar to the standard library's io module.
If all goes as I hope, the embedded-io 0.7.x series can be followed compatibly …

@beeb@hachyderm.io
2025-12-10 17:37:59
Content warning: Advent of Code 2025 Day 10

Yes! Today's puzzle in #AdventOfCode was quite hard (especially part 2) but so rewarding and I learned a lot!
For part 1, I implemented A* from scratch, my favorite little pathfinding algo that I use pretty much every year for #AoC (sometimes I use a lib instead of implementing it but it's been a while so a refresher was in order).
For part 2, after trying A* again and noticing it was running for way too long, I went back to the drawing board and solved the first machine by hand. I noticed the constraints were a system of linear equations.
I then researched algorithms to solve such integer programming problems and didn't feel like learning AND implementing the algorithms in one day (ain't nobody got time fo that). But this lead me to discover the `good_lp` #rust crate which is really good and that I will keep in my back pocket from now on!
So I used the library to define a system of variables and constraints which could be solved magically for me.
#AoC2025 #AdventOfCode2025 #RustLang

@grifferz@social.bitfolk.com
2025-10-21 13:13:43

"How to Optimize Rust for Slowness" – Carl Kadie
#rustlang

@niklaskorz@rheinneckar.social
2025-11-12 10:36:32

I wish there was a #JavaScript / #TypeScript package manager that behaved more like #RustLang's cargo. Specifically, in a workspace of many inter-dependent packages, I only want to f…

@beeb@hachyderm.io
2025-12-09 20:04:21
Content warning: Advent of Code 2025 Day 9

A nice bump in difficulty for today's #AdventOfCode problem!
Although the first part came to me very easily, I spent way too much time trying to implement a flooding algorithm for part 2, only to find out that it would take too much time and there should be a better way.
The worst part is that I had the intuition for my final solution super early on, but couldn't materialize it in a simple way until tonight.
I also must admit I realized quite late that the points were sorted in the input :D I should RTFM better sometimes.
My final #rust solution runs very quickly and is reasonably clean.
#AoC #AoC2025 #AdventOfCode2025 #RustLang

@mgorny@social.treehouse.systems
2025-11-13 13:27:48

< ionen> I feel like I'm updating uv/uv-build more often than I use it and it takes like 10000x longer to build than the package I use it for
Who would have thought that the #RustLang fad will make people force others to install humongous tools that don't bring any benefit to them.
#Python #PEP517

@beeb@hachyderm.io
2025-12-08 15:41:16
Content warning: Advent of Code 2025 Day 8

A cool graph problem today in #AdventOfCode
Nothing special here, I leveraged the `petgraph` #rust crate which I love! Calculating all pairs' distances (squared) and joining the pairs that are closest with an edge.
Only thing I wish I had more time to implement would be the graph traversal algo during sub-net aggregation, but swamped with work at the moment.
#AoC #AoC2025 #AdventOfCode2025 #RustLang

@beeb@hachyderm.io
2025-12-07 10:33:10
Content warning: Advent of Code 2025 Day 7

Today's puzzle in #AdventOfCode was another grid puzzle, where I again represented the entities as a sparse set.
Part 1 was relatively straightforward, a simplified BFS-like process allowed to construct the beams going through the system.
For part 2, additionally to gathering where a beam was present, I added metadata about how many paths were going through each position, adding them up and splitting them as required. Summing the paths for the last row gave the required result.
#AoC #AoC2025 #AdventOfCode2025 #RustLang #rust

@mgorny@social.treehouse.systems
2025-11-28 02:53:54

"Do not introduce #NIH #RustLang dependencies in your #Python package when there's no performance, security or any other benefit to it, and it just limits portability and creates more work for packagers" challenge.
Difficulty: impossible.
#packaging

@beeb@hachyderm.io
2025-12-06 10:08:23
Content warning: Advent of Code 2025 Day 6

Today's #AdventOfCode problem was more about parsing than about complex logic, but it was fun!
I opted to keep the parsing with winnow simple and do most of it by hand from the raw characters, to exercise my #rust iterators a bit.
#AoC #AoC2025 #AdventOfCode2025 #RustLang

@beeb@hachyderm.io
2025-12-05 15:42:57
Content warning: Advent of Code 2025 Day 5

Another easy challenge in today's #AdventOfCode puzzle.
Part 1 is straightforward, and for part 2, the trick was to sort the list of ID ranges first, which made the merging pretty easy.
#AoC #AoC2025 #AdventOfCode2025 #rust #RustLang

@mgorny@social.treehouse.systems
2025-10-24 02:24:26

Who would have thought that creating a programming language for rapidly developing, deploying and abandoning lots of packages would have lead to this…
"Forking confusing: Vulnerable Rust crate exposes #uv #Python packager"
#RustLang #security

@beeb@hachyderm.io
2025-12-04 07:25:52
Content warning: Advent of Code 2025 Day 4

Didn't feel like thinking too much for today's problem of #AdventOfCode, so my solution is quite naive and runs in a few tens of milliseconds for part 2 (thanks, #RustLang!).
I went for a HashSet for the grid just because it made looking up neighbours simpler at the edges, probably also not the most performant solution, but gets better as the grid becomes sparser.
#AoC #AoC2025 #AdventOfCode2025 #rust

@beeb@hachyderm.io
2025-12-03 06:53:11
Content warning: Advent of Code 2025 Day 3

Super happy with my solution for today's #AdventOfCode problem!
It initially took me a little bit of time to find a suitable strategy, but it all clicked when I noticed that the left-most selected digit had the most significance in the final value. Thus, I maximized the value of that left-most digit, leaving enough digits on the right side to be able to pick the required total number of batteries in the bank.
The solution is relatively short and sweet:
#AdventOfCode2025 #AoC #AoC2025 #RustLang #rust

@beeb@hachyderm.io
2025-12-02 10:28:58
Content warning: Advent of Code 2025 Day 2

Today's #AdventOfCode problem was fun! I kept a different implementation for part 1 vs part 2 as they both run relatively fast.
For part 1, I iterated over all IDs (the ranges are quite small) and split them in half mathematically (no string representation) to compare both halves.
For part 2, I instead generated all interestings IDs (mathematically again) up to a length of 10 digits (the max in my input) and checked if any of the ranges contained them.
#AoC #AoC2025 #AdventOfCode2025 #RustLang #rust

@beeb@hachyderm.io
2025-10-18 19:56:12

New article on the blog!
This time, it's about how I optimized an algorithm which turns byte offsets into line/column numbers and UTF-16 offsets.
Most of the performance improvement came from the use of SIMD to efficiently count ASCII characters.
#rust #RustLang #SIMD #optimization #blog