HNHacker News
TopNewBestAskShowJobs

williamvds

324 karma · joined November 4, 2019

Contact: hn@williamvds.me
submissionscomments
williamvds··on Framework Laptop 16
Grey market key resellers, apparently using volume licensing. It's a roll of the dice whether they'll stay valid, possibly because the same key is resold repeatedly, or Microsoft blacklists them.
williamvds··on Mozilla.ai: Investing in Trustworthy AI
Of course, we can trust the megacorps to keep our best interests at heart. It's a well known fact they always consider the long-term effects of their business practices and don't try to extract as much rent as possible from everyone for themselves and their shareholders.

The issue now is, due to the huge cost of training models, the forefront of AI is largely dominated by a small number of corporations with enough capital. They are already using it to extract even more capital, by selling use of these models which are trained on other people's work, largely uncompensated and without consent.

So yeah, people are rightfully miffed about that, and don't want this tech solely in the hands of and benefit of this lot.

williamvds··on Vivaldi co-founder: Advertisers 'stole the internet from us'
This is the kicker when it comes to the advertising industry. Advertisers pride themselves on slurping up all the personal information they can get their hands on, telling their customers it will help make their advertisements more effective. But anyone who uses the internet (without an adblocker) can tell just how poorly implemented, targeted, and ineffective those ads often are. On top of it being incredibly difficult to measure advertising effectiveness. It very much feels like a whole multibillion dollar industry (which created several megacorporations) is selling a whole load of bullshit, and causing great harm to a lot of people in order to justify it.
williamvds··on Nix-Powered Development with OCaml
I've got a simple use case: reproducibly building a random derivation from someone's Git repo.

If they haven't pinned nixpkgs, I have no idea at what point it _was_ building successfully. It's just dumb luck whether my system's channel is a compatible nixpkgs.

If it's pinned, great, I can use that pin until I'm bothered to bring it back to mainline. At that point I'll override the nixpkgs input and bear the cost of updating and maintaining it.

Flakes make managing pins those easier, through a nice(r) CLI, and a standard format for them.

williamvds··on TikTok banned on EU executive staff devices
You'd think any trust would have been proven misplaced by now[0].

I do hope European countries continue reclaiming their privacy from the USA. Let us just hope it is with truly secure systems rather than their own backdoored ones.

[0] https://www.reuters.com/world/europe/us-security-agency-spie...

williamvds··on Hundreds of changes made to latest editions of Roald Dahl's books
In case you don't realize it, your behavior in this thread is patronizing (telling people how they should behave), degrading (not directly talking to the commenter), and from a clear place of closed-mindedness (writing as if teaching truths to an AI, not discussing).

Your lack of empathy makes me assume you haven't been through similar experiences as the commenter you're "replying", either because you're not visibly far off "normal", or lucky enough to have grown up in an environment which was supportive of you.

Any case, the earlier commenter is not assuming cis people are terrible and transphobic and whatever. It is a matter of trust and risk. You can generally trust other LGBT people to be accepting since they've been through the same problems as you, and of course, because they share the same differences.

So it makes sense to group together, it's safer in groups, and sometimes mentally healthier than falling in to a pit of depression feeling forced to behave or a appear a different way to how you want to.

You'll be making constant calculations on whether it's safe to show public displays of affection with your partner, or simply appear an act like you want to. The fears are exaggerated of course (we are all creatures of caution), but not unfounded, depending on where you live.

So yes, short-term, it's nice to escape to a place where you don't have to do that. Long-term, it's healthier to not autosegregate, both for the queer and non-queer person. It helps normalise things. But I won't put that on every queer person, to each their own.

williamvds··on Ask HN: Is anyone successfully self-hosting Firefox Sync?
Another option is to find a Nixpkgs commit which does contain the version of a package that you want. You can pin and import it as a Flake input, and use the old version of the package provided.

So in its own way, Nix and Nixpkgs do serve the purpose of software preservation, as long as you have the full commit history for Nixpkgs.

Preservation doesn't imply maintenance however. It's fair for Nixpkgs to delete packages that are no longer supported, as that's a burden on the limited number of maintainers.

By recreating the package and module in my own Flake, I've taken on responsibility for maintaining it myself, and not adding any work to the Nixpkgs maintainers.

NixOS modules in particular aren't easy to extend, so I ended up copying it entirely. And to be honest, the thought of using an old version of Nixpkgs didn't cross my mind while setting up syncserver. Hopefully it's easier to maintain with poetry2nix now that I've got the package working.

williamvds··on Ask HN: Is anyone successfully self-hosting Firefox Sync?
The flake starts at this level: https://git.sr.ht/~williamvds/config/tree/master/item/nix

Struggle is a good way to put it! I feel I hit one of Nix's pain points here: packaging software whose dependencies are largely missing from Nixpkgs. On top of that, it was a Python app, and the state of Python packaging is quite a mess.

I also feel it Nix was the right choice. My journey was rather harsh, but I do believe in its approach.

williamvds··on Ask HN: Is anyone successfully self-hosting Firefox Sync?
I briefly considered it, but there are some big problems:

- The new replacement package, syncserver-rs, has already been added to Nixpkgs, along with a NixOS module [0]

- Python 2 and the package itself are no longer supported, meaning...

- support in Nixpkgs is pretty rough - dependencies have been updated such that they no longer support Python 2, or have been removed outright, meaning...

- syncserver has already been removed from Nixpkgs

- in order to avoid the problem of unsupported dependencies, I delegated dependency resolution to a community project, poetry2nix[1]. Even so, it was a nightmare to get working, lots of hacks and workarounds were needed

Of course, my repo is public, so anyone is welcome to use the Flake within. If they do, I'd suggest dropping me a line so I don't do anything drastic to the package or module.

[0] https://github.com/NixOS/nixpkgs/pull/176835

[1] https://github.com/nix-community/poetry2nix

williamvds··on Ask HN: Is anyone successfully self-hosting Firefox Sync?
Good point, I'll update the comment to indicate syncserver is now unmaintained.

Of course, everything self-hosted is at my own risk etc. And official support is a luxury in this kind of FOSS, I generally don't count on it.

But since it works for me, it may be worth sharing the details.

williamvds··on Ask HN: Is anyone successfully self-hosting Firefox Sync?
I've self-hosted the original Firefox syncserver[0] for a couple of years now. It's a now unmaintained Python 2 + gunicorn web app.

It still uses the Firefox identities service, since I haven't bothered to try setting that one up myself. That means I need a Firefox/Mozilla account even with a self-hosted sync server, which isn't ideal.

Note that Mozilla do provide a script to delete all your data from their servers[1], in case you were using Firefox sync before going self-hosted.

I originally went through the setup instructions manually. Now I've created a Nix package[2] and NixOS module for it[3], which was an adventure by itself. I can now easily reproduce the setup, which I did while migrating my webserver to a different provider.

As for why I didn't try syncstorage-rs, it's rather petty, but the old syncserver was working well for me, and it doesn't yet support SQLite.

[0] https://github.com/mozilla-services/syncserver

[1] https://github.com/mozilla-services/syncserver#removing-mozi...

[2] https://git.sr.ht/~williamvds/config/tree/master/item/nix/pk...

[3] https://git.sr.ht/~williamvds/config/tree/master/item/nix/mo...

williamvds··on Show HN: Chrome extension to close Zoom/Notion tabs after launching desktop app
If I had to guess the parent commenter's rationale, they probably want people to boycott usage of such Electron apps. In the hopes that these companies would stop making them and pushing them onto their users.
williamvds··on Show HN: Chrome extension to close Zoom/Notion tabs after launching desktop app
Zoom is an Electron app, meaning it effectively bundles Google Chrome, meaning it should work in any modern browser.

My commom thought when I have to use such apps is: why can't I just use this in the browser?

In some cases it's somewhat reasonable, perhaps you need global hotkeys for some reason.

In other cases the rationale it not clear. Worse, some inexplicably remove features from the web app that are available in the bundled Electron app.

I'd much rather leave these apps in my browser sandbox, than give them greater access to my system than they truly need.

williamvds··on Pip and cargo are not the same
Last time I used Poetry, I got frustrated at how long updating the lock file (i.e. resolving dependencies) took. Adding the debug flag showed it was spending most of its time combing through each version of the setuptools package, oldest to newest, to pick the most recent compatible version.

I was surprised it didn't do any caching, or possibly try binary search, though the latter could be rather imprecise.

Sure, cargo being written in Rust might give the dependency resolver a nice baseline speed boost, but optimisations matter too.

williamvds··on What if writing tests was a joyful experience?
Perhaps Functional Programming Language
williamvds··on Underappreciated challenges with Python packaging
Have you checked out the manual?

https://nixos.org/manual/nixpkgs/stable/#python

Particularly section 17.27.1.2. Developing with Python. Combine that with a generic guide on using Flakes and that should get you started

williamvds··on LearnCPP: Website devoted to teaching you how to program in C++
This is a good idea. Most modern languages have their own build tool which handle most of these things, so this requires some separate learning with C++.

Some ideas for a curriculum:

Context

- C++ as a standard, compilers as implementations

- a build tool's role in handling compilation and linking

- compilers having limited abilities, having limited warnings and analysis by default

Build tools

- evolution: e.g. make -> autotools, cmake, meson

- focus on meson as the build tool of choice (personally I'd avoid CMake since it has a lot of legacy baggage)

Testing

- gtest/gmock

- catch

- designing for testing

Analysis tools

- why you should care: security, catching bugs

- cranking up built-in compiler warnings to reasonable standards

- external tools like clang-tidy, cppcheck

- sanitizers: address sanitizer, leak, thread, etc.

- fuzzing

Dependency management (probably the toughest, since it's still a mess)

- history: usually just relying on system packages, or installing libraries globally from source

- Conan (probably the best option for simple dependencies that's actually catching on)

- CMake external projects, Git submodules

- Docker

- Nix (if you're feeling adventurous)

williamvds··on Ask HN: Is Vim still worth learning?
My main selling point is no longer feeling like you're fighting your text editor. Once it's muscle memory you focus very little on the act of editing, just on what you're writing.

With more advanced stuff like macros and substitutions, tedious reorganisation/refactoring becomes much faster.

And you can slap on IDE-like features with language servers and the like. It isn't as powerful as an IDE, but it will also be much less complex. Or use a Vim plugin for your IDE and accept the tradeoff: losing Vim features for more IDE features.

It takes a while to learn the editing model and hence get a return on your investment, so keep that in mind.

williamvds··on Britain is sleepwalking into censorship?
When I bought a throwaway GiffGaff SIM while I was waiting months for BT to set up my broadband, it had content blocking on by default. They wanted me to send a picture of my driver's license to lift the restrictions.

I'm not sure what I'm more disgusted by: the fact I need to give away my identity to have unfiltered (except the outright blocked stuff) access to the internet, or that I caved and gave it to them anyway.

I guess I should be happy proof of identity wasn't required to buy or activate the SIM in the first place.

williamvds··on NixOS 22.11 “Raccoon”
You may be interested in Flakes[0], which locks your nixpkgs (and other "inputs") to a specific known version.

Obligatory disclaimer, they're still in beta, but everyone's using them anyway. There's some ongoing work[1] before they're officially released.

[0] https://nixos.wiki/wiki/Flakes [1] https://www.youtube.com/watch?v=JE-vLFMTXxM

williamvds··on NixOS 22.11 “Raccoon”
Definitely up there for the top Nix benefits - truly atomic OS upgrades.

It's a shame this isn't explicitly highlighted on nixos.org, it's only implied in the "Is the previous version better? Roll back anytime."[0] section, when it's true for both packages and your entire system's config.

[0] https://nixos.org/explore.html

williamvds··on Why it’s hard to buy deodorant in Manhattan
I get the impression America is uniquely vulnerable among the wealthiest nations. Private healthcare providers, a defanged health regulator, and rampant corporate bribery/advertising. Purdue salespeople lobbied doctors directly to prescribe their opioids to patients, while Purdue suppressed knowledge their incredibly addictive nature, and later offloaded blame to the addicts they largely created.

Here's a long overview of the Sackler family and their involvement in creating the opioid epidemic https://www.youtube.com/watch?v=3-dptkIZ7tI

williamvds··on Zuckerberg's leaked email on VR strategy (2015)
Wholly agree on the immersion: a decent VR game, even if janky, has a great advantage in immersion by actually feeling _present_ in whatever virtual world you're in.

Two examples I'd add: VTOL VR, somewhere closer to the Sim genre but simplified for VR controllers. I've played a few flight (combat) games before, but the combat is heart-pumping unlike anything else. Another more popular one is VRChat and similar, where there are desktop versions but you definitely feel like you're missing something without the VR aspect. Emoting, gesturing, and actually "touching" others in VR is easy. If you're in desktop mode, you're mostly limited to standing nearby and talking.

williamvds··on Why are glasses so expensive? The industry prefers to keep that blurry (2019)
I've worn glasses since I was a kid, when you're entitled to a free frame from the cheaper range at Boots (a local retailer) (also, thanks, NHS). I remember struggling to find a design that I liked decent around that price range. As soon as you went out into the price ranges that weren't covered, you got a lot more nicer looking ones. At the time I was buying new frames and lenses every few years so I went with the cheap ones.

My current pair were about £30 from Aliexpress, a gorgeous rimless set with anti-glare lenses included. Needless to say I won't be buying from local retailers anymore.

I'm sure here in the UK we're also affected by the Luxottica monopoly in the US, especially when it comes to designer brands.

williamvds··on EU Voice
Forgive me if I'm mistaken, I've never used mastodon, but I expect part of the "federated" bit means being able to "follow" users from other Mastodon instances, including EU Voice. So you'd need just one account on a Mastodon instances to follow every EU government/institution announcements on EU Voice. If not on Mastodon, RSS feeds still exist.
williamvds··on EU Voice
It's quite sensible really, why would you leave a method of disseminating official statements vulnerable to the whims of a private American corporation? Discussion still can and will be held on platforms not directly controlled by governments.
williamvds··on The bosses who silently nudge out workers
If by law or employment contract, a company must pay compensation after a dismissal, there is now an incentive for companies to "force out" employees by making them resign by their own hand. It's quite clear this is what happened in this situation. Such "constructive dismissal" is therefore a method of avoiding their legal obligations to their (former) employees, and so the practice should be - and often is - banned.

In any case, it should not be "a privilege" to be treated humanely by employers, it should be a right.

williamvds··on Aerc – a pretty good (terminal) email client
I initially tried neomutt before moving to aerc and haven't looked back since. My memory of neomutt is pretty hazy, but I feel aerc has a much simpler setup process (it has built-in SMTP support) and a less steep learning curve. aerc's defaults feel more sane, particularly as a Vim user.

For reference, my setup is having offlineimap sync mail to/from my local maildir. aerc fills the rest of gaps with viewing, composing, and sending mail.

williamvds··on Cppfront, Herb Sutter's proposal for a new C++ syntax
From a C/C++ programmer's POV those may look like GOTO labels, I agree. The proposed syntax is probably a consequence of a modern trend in using := for declaration and assignment.

    x := 5
Where you can optionally insert the type between the colon and equals, otherwise it is deduced

    x : int = 5
williamvds··on On Aging Alone (2021)
Short story idea:

An elderly person living isolated with their best friend. All amenities are delivered autonomously, so we only see these two the entire time. The friend starts acting strangely over time, as if he's developing the early stages of dementia. Slowly hint that the best friend is in fact an AI of some sort, but the protagonist has lived with them so long that they have forgotten. The protagonist eventually remembers and opens up the AI's control panel to fix them. The AI suddenly disappears or powers off. Protagonist looks at the control panel again:

  Suspicious activity detected on your device. Your Google ElderCare MyAI™ account has been permanently suspended. All of your device data will be deleted shortly - Google cares about your privacy.
  Please note this suspension is non-appealable.
  Have a good day.
← PreviousPage 2 of 3Next →