News for hackers. Stuff that matters.

pasxizeis

Re:Is your Postgres migration safe or not safe? on Saturday September 26, 2026 @02:07PM (#49859016)
I built pglockanalyze for the purpose of a actually seeing in action what locks your migrations will acquire: https://github.com/agis/pglockanalyze
Re:Ask HN: What Are You Working On? (April 2026) on Monday April 13, 2026 @12:09AM (#47747494)
As a means to learn about both WebAssembly and Rust, I started writing a WebAssembly binary decoder (i.e. a parser for `.wasm` files) from scratch.

Recently it hit v3 spec conformance. (I'm executing the upstream spec test suite.)

I don't plan to make it a highly-performant decoder for use in production environments, but rather one that can be used for educational purposes, easy to read and/or debugging issues with modules. That's why I decided not to offer a streaming API, and why I'll be focusing on things like good errors, good code docs etc.

https://github.com/agis/wadec

P.S. I'm new to the language so any feedback is more than welcome.

Re:Watgo – A WebAssembly Toolkit for Go on Saturday April 11, 2026 @12:50AM (#47727510)
I followed the same testing approach when writing a Wasm binary parser (technically, a decoder)[0].

It was pretty helpful having the official spec suite available and a major boost of confidence that your parser is compliant.

Nevertheless, it was my own tests that found a regression in the latest published version of the spec[1], which shows how important it is to have a variety of implementations.

[0] https://github.com/agis/wadec

[1] https://github.com/WebAssembly/spec/issues/2066

Re:Notes on Writing WASM on Sunday March 08, 2026 @10:55AM (#47297827)
Tangential: I decided to write a Wasm parser (more precisely, a decoder the the Wasm binary format) from scratch, as a means to learn both Wasm and Rust[0].

It was the first time I was writing this sort of thing, but I found the spec very clear and well-written.

Fun fact: I was surprised when the test from a toy parser surfaced a real regression in version 3 of the spec[1], released roughly 4 months before.

[0] https://github.com/agis/wadec

[1] https://github.com/WebAssembly/spec/issues/2066

Re:Ask HN: What Are You Working On? (February 2026) on Monday February 09, 2026 @06:05AM (#46943943)
Slowly but steadily implementing support for version 3 of the Wasm specification in my wasm parser (written from scratch): https://github.com/agis/wadec
Re:Ask HN: What Are You Working On? (January 2026) on Sunday January 11, 2026 @02:58PM (#46579348)
Writing a WebAssembly module parser from scratch, focusing on good diagnostics/errors and DX.

Currently it's fully-conformant to v2.0 of the spec, while I'm working towards implementing the recently released 3.0 version.

https://github.com/agis/wadec

Re:Ask HN: What did you learn in 2025? on Monday January 05, 2026 @03:59AM (#46496657)
I started learning Rust more actively and then WebAssembly, via building https://github.com/agis/wadec.

I plan to continue doing that in 2026.

Re:Tell HN: Happy New Year on Wednesday December 31, 2025 @09:13AM (#46444198)
Happy new year from Greece!
I plan to continue building the hobby project I started (a Wasm module parser[1]) by implementing version 3 of the WebAssembly specification and eventually implementing the Validation phase.

[1] https://github.com/agis/wadec

Show HN: Wasm decoder with focus on helpful errors/diagnostics

https://github.com/agis/wadec

Hey everyone! I started writing a decoder from scratch for WebAssembly modules (i.e. a parser for `.wasm` files).The primary motivation was to learn both WebAssembly _and_ a new language. However it turned out to be a very fun project, and I think there is space for a decoder with helpful error messages, that can serve as a good debugging tool or for educational purposes.A sample output can be...

( Read More... | no comments | 2 points | on HN )
Re:Ask HN: What Are You Working On? (December 2025) on Monday December 15, 2025 @12:57AM (#46270933)
I'd say jump straight to the specification (maybe v2, which is simpler).

But I occasionally saw one or two articles around where they explain how the binary format works, which could be a good introduction before jumping to the spec.

Re:Ask HN: What Are You Working On? (December 2025) on Sunday December 14, 2025 @03:13PM (#46266389)
As a means to learn about both WebAssembly and Rust, I started writing a WebAssembly binary decoder (i.e. a parser for `.wasm` files) from scratch.

Recently it hit v2.0 spec conformance. 3.0 is next on the roadmap. (I'm executing it against the upstream spec test suite.)

I don't plan to make it a highly-performant decoder for use in production environments, but rather one that can be used for educational purposes, easy to read and/or debugging issues with modules. That's why I decided not to offer a streaming API, and why I'll be focusing on things like good errors, good code docs etc.

https://github.com/agis/wadec

P.S. I'm new to the language so any feedback is more than welcome.

Re:Compiling Ruby to Machine Language on Monday November 17, 2025 @04:01PM (#45958228)
Really happy to see Pat keeping it up! His Ruby under a Microscope book but also his blog posts are amazing.
Re:Ask HN: What Are You Working On? (Nov 2025) on Monday November 10, 2025 @07:56AM (#45875498)
As a means to get into WebAssembly and Rust, I started writing a binary decoder (i.e. a parser for `.wasm` files) from scratch.

Recently it hit v2.0 spec conformance. 3.0 is next on the roadmap. (I'm executing it against the upstream spec test suite.)

My aim is probably not for it to become a highly-performant decoder for use in production environments, but rather one that can be used for educational purposes and/or debugging issues with existing modules. That's why I decided not to bother with offering a streaming API, and why I'll be focusing on things like good errors, good docs etc.

https://github.com/agis/wadec

P.S. I'm new to the language so any feedback is more than welcome.

Re:I Love OCaml on Friday November 07, 2025 @12:11PM (#45848548)
As a Rust newbie and seasoned Go dev, I'm pretty interested to knownwhere would people experienced in both OCaml and Haskell, would put it in the spectrum.
Re:Show HN: WebAudio Data-Driven audio engine on Monday November 03, 2025 @04:39PM (#45804776)
Amazing work!

Where would you suggest someone to start if they wanted to get familiar with the codebase?

Also, what are the next steps for the project?

Re:Ask HN: What Are You Working On? (October 2025) on Monday October 13, 2025 @12:55AM (#45564793)
As a means to get into WebAssembly, I started writing a WebAssembly binary decoder (i.e. a parser for `.wasm` files) from scratch.

Recently I started executing the upstream spec tests against it, as a means to increase spec conformance. It's non-streaming, which is a non-starter for many use cases, but I'm hoping to provide a streaming API later down the road. Also, the errors interface are still very much WIP.

All that said, it's getting close to a fully-conformant one and it's been a really fun project.

https://github.com/agis/wadec

P.S. I'm new to the language so any feedback is more than welcome.

Re:Ask HN: What are you working on? (September 2025) on Tuesday September 30, 2025 @03:05AM (#45422731)
Started writing a WebAssembly binary decoder, as a means to learn both more about wasm and Rust: https://github.com/agis/wadec.
Re:Ask HN: What are you working on this weekend? on Saturday August 09, 2025 @12:15PM (#44847722)
A CLI tool to make reasoning about Postgres locks a bit easier.

Given a database[1] and a set of DDL statements/migrations you want to check, pglockanalyze will open a transaction, execute the statements, read the pg_locks view to analyze the locks they acquire and rollback (or commit, depending on the flags you passed) the transaction. Then, it will output the results for each statement.

I think there's merit in this idea, that said it's very much an experiment so there could be flaws and/or corner cases that this strategy won't work well for.

It's meant to act as a complement, not a replacement, to things like static analysis and the official Postgres docs.

https://github.com/agis/pglockanalyze

[1] typically an ephemeral database spawned by your CI pipeline

Re:Ask HN: What are you working on? (July 2025) on Monday July 28, 2025 @03:34AM (#44708212)
A CLI tool to make reasoning about Postgres locks a bit easier.

Given a database[1] and a set of DDL statements/migrations you want to check, pglockanalyze will open a transaction, execute the statements, read the pg_locks view to analyze the locks they acquire and rollback (or commit, depending on the flags you passed) the transaction. Then, it will output the results for each statement.

I think there's merit in this idea, that said it's very much an experiment so there could be flaws and/or corner cases that this strategy won't work well for.

It's meant to act as a complement, not a replacement, to things like static analysis and the official Postgres docs.

https://github.com/agis/pglockanalyze

[1] typically an ephemeral database spawned by your CI pipeline

Show HN: pglockanalyze - See the locks your Postgres migrations will acquire

https://github.com/agis/pglockanalyze

Hello! I created this tool to make reasoning about Postgres locks a bit easier.Given a database[1] and a set of DDL statements/migrations you want to check, pglockanalyze will open a transaction, execute the statements, read the pg_locks view to analyze the locks they acquire and rollback (or commit, depending on the flags you passed) the transaction. Then, it will output the results for each...

( Read More... | no comments | 4 points | on HN )
Re:Ask HN: What are you working on? (May 2025) on Monday May 26, 2025 @05:33AM (#44095621)
A "Postgres lock diagnostics" tool for migrations. We've been bitten a few times, by seemingly innocent migrations that ended up acquiring locks we did not expect (yes, RTFM).

So I thought: what if, when you opened the PR, you had a tool that actually executed your migrations, saw what locks they acquired (in runtime) and then reported it as a comment to your PR? This would provide you with yet another data point you could use to reason about whether your migration is safe to deploy or not. For example:

    ALTER TABLE users ADD COLUMN email TEXT:
      acquired AccessExclusiveLock on relation `users`
It does this by opening a transaction, executing the statement, and observing the `pg_locks` view from _a different_ connection before the initial transaction is rolled bac (or committed, depending in the flags you passed). The idea is to be able to use it as a CLI, as a library or with a ready-made GitHub Action (which will take care of commenting in your PR).

It's in early-stage and very much a PoC yet, but I think there's merit in the idea.

https://github.com/agis/pglockanalyze

P.S. Also, an excuse to learn Rust - so any feedback from Rust ppl more than welcome

Re:Pglocks.org on Sunday May 18, 2025 @08:00AM (#44020680)
Shameless plug: I wrote a tool[1] that executes a given migration against a test database (e.g. in your CI) and reports back what locks it acquired.

The rationale being to have a "lock diagnostics report" commented in your PR's migration file.

It's a prototype and has quite some rough edges and missing functionality, but feedback is more than welcome.

[1] https://github.com/agis/pglockanalyze

Not sure what happened here, but this track[1] at around the 55th second, is suddenly (and unexpectedly) cut off and another, totally unrelated (different artist, different genre) starts playing. The original track is from a Greek hardcore hip-hop group.

First time encountering this in a streaming platform so I found it interesting to share.

[1] https://open.spotify.com/track/4YPTB10Kzq7TMPrL5qHFVk?si=B8i...

Re:Stress does turn hair gray, and it’s reversible on Thursday June 24, 2021 @08:13AM (#27616417)
> Almost a year and a half later, after leaving that job, I took the pandemic to really focus on my stress levels and be happier (I am).

Do you mind sharing any particular advice on how to do this?

I think OP is talking about long-term holders while you are talking about traders.

Older »