HNHacker News
TopNewBestAskShowJobs

flysand7

193 karma · joined October 20, 2023

Low-level programmer, like C and stuff
submissionscomments
flysand7··on Have I Been Pwned 2.0
Oh that's what it was! I actually didn't think much of it until you pointed it out. At a glance looked like some random arrangement of squares
flysand7··on Show HN: Sshsync – CLI tool to run shell commands across multiple remote servers
I'm curious what happens with output. Is it one line per each computer you've connected to or does it get merged until it diverges, kinda like in that Rick and Morty episode with timeline splits?
flysand7··on State of the Art PFAS [pdf]
There's been a recent Veritasium video about worldwide PFAS contamination, which TBH kinda scared me and got me thinking about where all waste goes, like at the end. I guess there's really nowhere but our planet that we can dump this stuff. If we were a little bit smarter maybe we could find ways to preprocess it into something safer for our environment, or like idk just send cargo rockets outside of the solar system or straight into the sun
flysand7··on Experts have it easy (2024)
100%, debugging is an absolute joy, especially with niche systems-level kinda of bugs that simply can not be debugged with simple printf's.

I had a friend once asking me to help debug a weird issue over discord. We went through some obvious things like are there any other threads running or is there something obviously wrong with the code. We didn't find anything so we went on to the best part -- trying to figure out the root cause from the panic. Checked the pointer values, wrote them down, checked where the TLS is, wrote that down to. At that point I forgot how Windows had TLS arranged, so I pulled up some docs, while the other guy fiddled around with the debugger. I found the TLS layout, and the debugger we used didn't have any kind of TLS debugging enabled, so we had to pull up PE spec to do some calculations on where the addresses could end up and sure enough the answer came -- we had a TLS corruption. Turns out he used a C bindings library that had a typo that overwrote the TLS and was messing with his variables.

Debugging is such a joy when it feels like Sherlock Holmes movies.

(*) For anyone who thinks might be misreading this, TLS means thread-local storage, not transport layer security. I'm sure I've had my share of wrong search results because of this too.

flysand7··on How to have the browser pick a contrasting color in CSS
Sadly, doesn't work on firefox yet :(
flysand7··on Thoughts on thinking
Mostly anime. Surprisingly, not that much, I think somewhere in the ballpark of 100 titles. In the beginning I was also watching some grammar tutorials on YouTube to get started with grammar quicker (Otherwise convergence on solution would be too slow).

Contrary to what I said I actually did use dictionaries, but the point I was trying to make is rather than memorizing phrases in advance, I used it to translate something I thought I heard.

flysand7··on Thoughts on thinking
Another case in point is that memorizing vocabularies and grammar, although could seem like an efficient way to learn a language, is incredibly unrewarding. I've been learning japanese from scratch, using only real speech to absorb new words, without using dictionaries and anything else much. The first feeling of reward came immediately when I learned that "arigatou" means thanks (although I terribly misheard how the word sounded, but hey, at least I heard it). Then after 6 month, when I could catch and understand some simple phrases. After 6-7 years I can understand about 80% of any given speech, which is still far, but I gotta say it was a good experience.

With LLM's giving you ready-made answers I feel like it's the same. It's not as rewarding because you haven't obtained the answer yourself. Although it did feel rewarding when I was interrogating an LLM about how CSRF works and it said I asked a great question when I asked whether it only applies to forms because it seems like fetch has a different kind of browser protection.

flysand7··on Getting AI to write good SQL
Having written more SQL than any other programming language by now, every time I've tried to use AI to write the query for me, I'd spend way more time getting the output right than if I'd just written it myself.

As a quick aside there's one thing I wish SQL had that would make writing queries so much faster. At work we're using a DSL that has one operator that automatically generates joins from foreign key columns, just like

    credit.CLIENT->NAME
And you got clients table automatically joined into the query. Having to write ten to twenty joins for every query is by far the worst thing, everything else about writing SQL is not that bad.
flysand7··on Show HN: acmsg (automated commit message generator)
You are talking about the commit message body, right, not just the header? Because for me it's something similar, but:

Header: Contains "What" and the scope of the changes, as short as possible Body: Contains "Why" and the full explanation of the change

flysand7··on It Awaits Your Experiments
This reminds me of "I'm Humanity" by Yakushimaru Etsuko, which was also etched onto a DNA of a bacteria. I love that song.

Also see https://ars.electronica.art/aeblog/en/2018/05/30/im-humanity...

flysand7··on A Rust Documentation Ecosystem Review
There's no downvote button for me, I had no idea HN had downvotes
flysand7··on Odin, a pragmatic C alternative with a Go flavour
I see yeah, a lot of people might prefer most of these (exclude maybe private by default and privating via underscoring).
flysand7··on Odin, a pragmatic C alternative with a Go flavour
Well, you are right, these are big features of Go, but I think the design philosophy is the other half of the language that makes it what it is.
flysand7··on Odin, a Pragmatic C Alternative with a Go Flavour
I remember times before Odin banned conditional imports. Those were different times, I miss them
flysand7··on Odin, a pragmatic C alternative with a Go flavour
Yeah, it's not safety as an absolute term, more like "safer than C". Which, to be honest, anything with bounds checking is safer than C.
flysand7··on Odin, a pragmatic C alternative with a Go flavour
"go flavour" refers to the similarity in the design philosophy, and some of the features. That said, it's still not Go.

For example, "errors as values" is a point that Odin makes, but it does make it in a slightly different light from Go. Whereas Go has an `error` type that encompasses all errors, Odin does not. Instead, it treats some types (booleans, enums, unions) as "special", in that they support things like `or_return`, which are typically your error propagation statements. Oh yeah, `or_return` is another big point, it does simplify a lot of `if err != nil { return err }` type of code.

And another big similarity to Go is the declaration syntax. It was inspired by one of Rob Pike's (iirc) comments on twitter about how they should have used a different syntax for Go instead.

From personal experience though, there are some things in Odin that I wish Go had. Its features play along together so nice, and it's so satisfying having three different language features come together in a nice logically-coherent simple way. That said, I don't think Odin is capable of replacing Go. Things like server-side logic and lightweight threads are probably where Go still excels at and beats Odin.

For systems-level programming I'd pick Odin though.

flysand7··on Odin, a pragmatic C alternative with a Go flavour
I'm kinda curious, you mind sharing some of the things you thought you didn't like?
flysand7··on Show HN: TextQuery – Query CSV, JSON, XLSX Files with SQL
Is it just me, or the images on the website aren't loading? Using firefox, from what I searched it seems like it could be just a firefox issue. The cdn links are https bt when navigating there manually it says the connection is not private.
flysand7··on Show HN: TextQuery – Query CSV, JSON, XLSX Files with SQL
For a lot of files where you would want to perform a quick one-time analysis, I don't think it's worth starting up a new database, and write scripts that parse the file from the source format and import it into the database. The one time I did it for postgres it took me maybe 2-4 hours to finish the script and start looking at the data. Next time it would be maybe an hour, but it's still a time.

So I guess I can see how not having to do the conversion for quick one-time analysis could be beneficial.

flysand7··on I'd rather read the prompt
Write a troll response in the style of Hacker News troll who wants to troll the Hacker news users who just read the article titled "I'd rather read the prompt". Make it ironic
flysand7··on Show HN: MP3 File Editor for Bulk Processing
In a change log simply stating "bug fixes" is not enough, because as a user, it's not clear whether or not any of those bugs that you have fixed has affected me. This might be my personal opinion though, I'm not sure, but when some software releases an update that says "fixed the issue where X goes wrong because of Y" and that specific thing has been annoying me for a few months, it kinda makes me happy in that moment, because I know I can expect the next update to suck a little less. Might be something to consider, but at least writing down the scope of the bug would be already better.
flysand7··on Spain is about to face the challenge of a "black start"
Oh man, this reminds me of factorio. When you miscalculate your power needs and your generators eat up the fuel that isn't being produced enough. I've had to make a bootstrapping mechanisms and power switches for some of my powerplants to ensure I can get it back up in case it goes down and I can then re-enable my factory bit by bit.
flysand7··on Show HN: An interactive demo of QR codes' error correction
It's surprising how much data you need to corrupt while still being able to read the QR code, that's what I'd take out from this. The demo is interesting in that respect, but I do think it's somewhat incomplete.

It seems to be missing some explanations regarding how the code is structured and how it performs error correction. I feel like there's little point in interacting with a system you don't understand or not trying to understand. And I also think there are cool ways to make those things interactive as well. Pick an image, then explain what the little squares in the corners are for and provide little interactivity to see how they affect the decoding. Then move on to the error correction. This step-by-step style of interactivity may be better, I'd think about that.

As for what is there, the first thing I don't like here is icons. The four icons in the lower-right corner (result data, format info, ..) are hard to distinguish, and are hard to correlate with the "history" tab. I'd probably either make them slightly different color, or actually simplifying these icons further might be a better option, just because they're so small.

But yeah it is pretty hard to tell what I'm interacting with, unfortunately. I don't know pretty much nothing about QR codes, and I don't know what the different kinds of errors are, what "EC" stands for etc.

UI should probably be rethought as well, because before I was writing the comment I had no idea I could switch a brush. Hell, I had no idea I was changing colors (the cursor covered half the space of the pixels, so I couldn't tell)

The idea's cool though, good work

flysand7··on Getting forked by Microsoft
If a guy comes begging for money out of rolls royce, I guess they either are pretty bad at begging or have a pretty bad sense of humor. I guess I wouldn't give money to them, it doesn't seem like it'll help them regardless.
flysand7··on Show HN: A Standalone/GitHub CLI Extension to Preview GitHub Flavored Markdown
I'm assuming it's because the project isn't meant to "Render" markdown, but provide a preview that works offline. That includes hot reloading when the original file changes, which you can't really do with just a client-side library.

If it was a JS library in addition to providing you a webpage with js in it, it would also need to provide you with a server with a hot reload, and we're back to CLI.

They are using goldmark library with some extensions[0] to render markdown. And there's also GitHub API for rendering markdown[1] if you're curious.

References:

[0]: https://github.com/thiagokokada/gh-gfm-preview/blob/main/int...

[1]: https://docs.github.com/en/rest/markdown?apiVersion=2022-11-...

flysand7··on Albert Einstein's theory of relativity in words of four letters or less
Folks, just for these kinds of websites I made an extension that trims the body of the text to 80 characters. I don't have a way to pay to get it on google's or firefox's extension marketplace, so you'd have to install it from source.

https://github.com/flysand7/breader

flysand7··on A recent study suggests that insects branched out from crustaceans
Shrimp are mostly tasteless though, aren't they? If you bite into a shrimp and really pay attention to the taste, you'd notice that it's not really a "taste" that you're feeling, but mostly the soft texture giving the illusion of tastiness.
flysand7··on Garfield Minus Garfield
Alok Kanojia vs Kok Alonojia (aka Dr.K interviews himself)

https://www.youtube.com/watch?v=hXG2h3RWTPE&pp=ygUGI2RrYWl0

flysand7··on Garfield Minus Garfield
♩ Don't cry, I am just a fish
flysand7··on Kermit Font
I absolutely love the font. Reminds me of an old encyclopedia I read as a kid. It had 10 chapters, each one discussing a specific theme, like history or physics, and the only thing I remember about it now is its design. Specifically the colors of the chapters. They were memorable. This font is quite similar in its aesthetics, in that I think that might be the only thing I'd remember if I was reading e.g. a book written with it.

Also representing prosody was an interesting idea. Never thought how much more information you could transmit through text by including pitch and loudness information. Not so useful for timing, I believe, because you mostly still speak at 1 syllable per time unit, but sometimes you do slow down.

← PreviousPage 2 of 4Next →