Better HN
topnewbestaskshowjobs
Log inSign up

lucgommans

975 karma · joined Aug 2, 2013 (13y ago) · 175 submissions

https://lucgommans.nl
Submissions

comment 1w ago · link · parent

This was shared in a Signal community about Android. I had no idea that this is not just an open standard but something Google goes around trying to get implemented by governments. This project tries to make it possible for open source OSes to send your location when you call 112 or your local emergency number

2.

CipherAML: Advanced Mobile Location for emergency services without Google(github.com ↗)

1 points · by lucgommans · 1w ago · 1 comment

comment 3mo ago · link · parent

I was recently recommended https://api.transitous.org (it's a webapp despite the domain). It can do things like "someone can pick me up on the far side and I don't mind walking 30 minutes at the start at 6 km/h, what's the optimal route to take?"

Revolutionary! Finally I don't have to look on a map to find all stations in walking/cycling/driving distance and then route to/from every possible combination of start and end station manually to see what busses and trains run there. And repeat the process with each schedule change in each involved country. Every other transport app that I know of will try to keep you within a few hundred metres of a bus stop or train station at all times and say "there exists no route" before telling you to cycle 10 minutes or from which station you have the shortest remaining distance by taxi or whatever

comment 3mo ago · link · parent

> The problem I have most of all with the routing is that it seems to default to my location as either the From or To value (whichever is the one I haven't selected). Once that's been chosen it's not immediately clear how to change it

Yeah this is an oft-asked question at least for OsmAnd, but I was recently corrected on this myself: so long as you don't press 'start' on the route, you can always change the from position freely and it won't flip back to your current location. You can close the navigation window (back button, swipe it away, or tap on the map) to get the map view back in full-screen for further browsing and selecting another point that you want as departure point, waypoint, or (subsequent) destination. Rinse and repeat until you have the route figured out with all the waypoints :)

I use this a lot for planning mapping routes. Another protip is to go into the waypoints view and on the top right you can do traveling salesman sorting to get the shortest way that visits all waypoints

CoMaps/OrganicMaps I don't know; I'm one of those who grew up with OsmAnd and got used to having all those features

comment 3mo ago · link · parent

Another alternative to geoIP could be WiFi-based location detection (comparing which WiFis are near you to a database). https://beacondb.net aims to replace Mozilla's shut-down location services, with public data releases once a proper anonymisation scheme has been figured out to avoid another Mozilla event. Google and Apple apparently also have usable back-ends: afaik it's not documented or meant for public use so ymmv, but the reverse engineered API is apparently super stable and not requiring any auth.

In case you have a second device where you'd like location, or ever don't have the USB GNSS receiver on you or something :)

comment 3mo ago · link · parent

Figure 1c from the paper[1] looked like it would make a great desktop background, but the resolution on the web is mediocre and there is this dashed rectangle to indicate the extent of the d-f subimages. In the PDF, the rectangle is drawn on top as a separate object so you can easily extract the underlying object!

Here are the figure 1 a-c images, lossless as they are in the PDF, having cropped a few transparent pixels for each one: https://lucgommans.nl/tmp/doi_10.1038_s41586-026-10871-3_fig... https://lucgommans.nl/tmp/doi_10.1038_s41586-026-10871-3_fig... https://lucgommans.nl/tmp/doi_10.1038_s41586-026-10871-3_fig...

edit: supplementary video 2 has a panel similar to figure 1b in 10% higher resolution, screenshot: https://lucgommans.nl/tmp/doi_10.1038_s41586-026-10871-3_sup...

[1] https://www.nature.com/articles/s41586-026-10871-3.pdf

comment 11mo ago · link · parent

> would love to see more tooling to lint and sanitize them before deployment

Sanitisation is one of two possible defences, the other being script execution controls or sandboxing. E.g., if you serve vector images on a web server, set a Content Security Policy header¹ for all your images that simply denies all scripting. You can also run it from a dummy domain ('origin') with nothing valuable on it (like how domains such as googleusercontent.com and githubusercontent.com are being used)

For sanitisation, DOMPurify² is the only widely used and tested library that I know of. It could use more bindings for other languages but, if you can call into it, it can go in your deployment pipeline. (Disclosure: I've worked with some of the people at Cure53, but not on this project)

You can also combine the approaches for defence in depth

¹ https://developer.mozilla.org/en-US/docs/Web/HTTP/Guides/CSP

² https://github.com/cure53/DOMPurify

comment 12mo ago · link · parent

The website has no open data license so this isn't usable for OSM, even if we wanted to. I just meant to propose collaborating on an existing platform where we already have a lot of data about physical features, rather than erecting an ephemeral platform for this special purpose

comment 12mo ago · link · parent

More than 200 hotels already on this website. Wouldn't this be much more useful as an OpenStreetMap tag so people can find and share these good/bad hotels in whatever front-end they like?

There does not seem to be a tag for it yet. That there are apparently hundreds of instances, and it being definitely something you'd want to select for, makes me think it's a good fit for OSM. Currently, hotels can already have tags like phone number, reception opening hours, WiFi fees, etc. It might even be a good fit for the toilets:* namespace, since this has overlap with toilets in (semi-)public spaces offering different levels of privacy

comment 1y ago · link · parent

Or if you need records other than A/AAAA, like MX for delivering email: https://anyz.one

e.g. 10.2.3.4.anyz.one will refer the recursive resolver to query 10.2.3.4 for the answer to the query. You can also buy a domain and configure it to do that, but this is quicker

Disclosure: I wrote anyzone

comment 1y ago · link · parent

List: https://en.wikipedia.org/wiki/List_of_organizations_with_.in...

(Not real affiliation but still: I added a domain to that page at some point)

comment 1y ago · link · parent

> It’s been difficult to remove [old JPEG] from its perch. [...] the formats AVIF and HEIC, each developed by standards bodies, have largely outpaced [JPEG]

I'm currently sticking to JPEG because, last time I tried, JPEG came out as the best format. Referencing my memory at https://chaos.social/@luc/113615076328300784

- JPEG has two advantages on slow connections: the dimensions are either stored up front so the layout doesn't jump, or maybe the renderer is better; and it loads a less-sharp version first and progressively gets sharper

- JPEG was way faster when compressing and decompressing

- on the particular photo I wanted to optimise in this instance, JPEG was also simply the best quality for a given filesize which really surprised me after 32 years of potential innovation

Regarding AVIF, my n=1 experience was that it "makes smooth gradients where jpeg degrades to blotchy pixels, but at decent quality levels, jpeg preserves the grain that makes the photo look real". Gradients instead of ugliness at really small sizes can be perfect for your use-case, but note that it's also ~80 times slower at compression (80s vs. <1s)

JpegXL isn't widely in browsers yet so I couldn't use it

> These days, the [JPEG] format is similar to MP3

The difference with mp3 is that Opus is either a bit better or much better, but it's always noticeably better.

You can save ~half the storage space. For speech (audio books) I use 40kbps, and for music maybe 128kbps which is probably overkill. And I delete the originals without even checking anymore if it really sounds the same, I noticed that I simply can't tell the original apart in a blind test, no matter what expensive headset setup I try

TFA attributes it to a simple "they were first" advantage, but I think this is why "Why JPEGs still rule the web": no file format is better than JPEG in the same way as Opus is better than MP3; in that you don't have to think about it anymore and it's always a win in either filesize or quality

That said, Opus is also annoyingly hard to get into people's minds, but I've done it and you also see major platforms from compress-once-serve-continuously video (e.g. Youtube) to VoIP (e.g. Whatsapp) switching over for all their audio applications

comment 1y ago · link · parent

Was wondering what you meant so I looked up "the innerhtml problem" and the top result indeed does list quite a few issues with appending to innerHTML that can be easily avoided. For anyone else interested: https://stackoverflow.com/a/33995479/1201863

comment 1y ago · link · parent

I knew changing innerHTML had some side effects, but this answer shows just how many corner cases it causes and offers a drop-in replacement at least for appending. Thought other developers on this site would also be interested to learn this

15.

Why is appending to the innerHTML property bad?(stackoverflow.com ↗)

4 points · by lucgommans · 1y ago · 2 comments

comment 1y ago · link · parent

Taken to an extreme without formatting, sure, but what ranges have that many digits in human-readable situations? And if there are those exception situations, you can word around it for that case ("285368760800±45691" or "45'691 years after 285'368'737'954")

Genuinely trying to think of an examples, since e.g. books aren't ever that long and search results don't have that many pages (that you'd all read and refer back to). A salary range, perhaps, can get into the seven digits in extreme cases (not that you care about any individual digit when you make a lifetime's worth of money in a bit more than a year): "Prospective salary is 2'423'000 to 2'432'000" seems to convey the relevant info as well as "Prospective salary is 2'423'000 to 9'000" does (except that I wouldn't understand the latter and ask what this second number means, but that's plausibly attributable to me as an individual not being used to it)

comment 1y ago · link · parent

I really like alternativeto. It's not always good: sometimes there are simply no good alternatives, or the community hasn't voted for the ones I'd have voted for and so a good option is way, way down. But if I want to know alternatives, I go there directly, so I guess that's maybe why people block it from appearing in random search results? I found it puzzling to see a useful site blocked (especially when I haven't seen it appear much in search results, but then, I've also been using DDG primarily, which ranks things rather differently)

comment 1y ago · link · parent

I don't understand. Opening the page in a logged-out state, it looks the same to me (just that there are not buttons to pick whether you want to raise/lower/block a domain when you're logged out). What's the different view you mean?

comment 1y ago · link · parent

If only it was merely useless. I know its reputation but it had some information that MDN did not have, so I used it this once in recent years. Turned out, the information was simply wrong and so I made a wrong decision based on that. (It might have been about favicon format support in different browsers. Presumably it was Safari that never had support for vector graphics whereas w3schools listed it as such, and it's not like you can just download Safari to double check.) Regardless, what I'm sure about is that I alerted them to whatever the problem was, but for me it was the last nail in that coffin

comment 1y ago · link · parent

Is this meaning to grep for a double hyphen from standard in, or to mark the start of positional arguments and then grep for a hyphen? If you want both, it should be:

    $ python -m this | grep -- -- -
Which is just beautiful

(Your example causes the last hyphen to be grepped for, which happens to only match doubled-up ones because single ones don't occur in that text. The quotes/apostrophes do nothing because they're parsed by (ba)sh and so only the hyphens are passed to grep, not the quotes. The last hyphen can be omitted because reading from stdin is the default if neither filenames nor recursion options are passed.)

comment 1y ago · link · parent

It is usually clear that 2-3 thingies means a range of thingies, but I seem to remember there being situations where it could also have been a minus sign. Perhaps it was with placeholders, where 10-N could be either one. Problem is, iirc, the real minus sign is longer than the hyphen, looking like an en dash (the one meant for ranges) and so it defeats the purpose... hence I totally use hyphens as minus signs, but en dashes for ranges, which makes sense in my head because a range has a certain span/length whereas a minus sign is just a little mark to indicate that something is negative. I see lots of people/software use en dashes for ranges but the existence of a real minus sign is, from my perspective, mostly just noted in typographic resources, so I think this reflects most people's usages (for the people that care for these details)

I do like that the em dash is as long as it feels that broken-off thoughts should be

Not everything has to be functional, sometimes things can also just look nice for the sake of it

comment 1y ago · link · parent

Literally never seen this (wish I could grep all comments I've ever replied to) and I do not understand what makes you say that it's clearer when it's dropping information, making it relative rather than a fully qualified number

In speech, it's common, and misunderstandings are usually not a problem (if you're not monologuing on a recording) because someone will just ask; but in writing it looks like the range is the wrong way around. Maybe I expect more care in writing because the feedback loop is longer, or maybe it's just habit and I think it's wrong in writing because I never see it?

23.

Most promoted and blocked domains on Kagi(kagi.com ↗)

379 points · by lucgommans · 1y ago · 182 comments

comment 1y ago · link · parent

Contact method is in profile (or more directly: https://lucgommans.nl/email), though by now I can't edit the comment and thus link anymore so will have to post a new comment and kill the old link if we want to change it. Just let me know, all is fine by me

comment 1y ago · link · parent

Rehosted so it'll stay alive at least a few years: <https://lucgommans.nl/tmp/YYZ_Crash.mp3>. Let me know if you'd like something more permanent than my tmp dump folder, or a filename that gives credits or so! (BTW if you're editing clips, I can recommend exporting to Opus instead of ancient MP3: released in ~2012 so support is very good by now and it's like twice the quality at the same file size, probably even better for speech)

26.

Wireless laser power transmission: Recent progress and future challenges(sciencedirect.com ↗)

1 points · by lucgommans · 2y ago · discuss

27.

Llama's Legal Labyrinth(merlijn.sebrechts.be ↗)

5 points · by lucgommans · 2y ago · 1 comment

comment 2y ago · link · parent

I compared Shazam's, SoundHound's, and BeatFind's recognition library in August 2021. (And tried MusixMatch but it crashed on startup apparently.) Don't think I published it anywhere, these are my raw notes I found among saved chat messages. The format is starting to make more sense now that I'm putting it into a wider window than a chat screen, so I can recommend using a wide browser (94 characters per line should do it). Eyeing the song choices, it looks like I tried to find different genres and artist types (ccMixer/youtube celebrities, to indie, to established) but a larger sample size would obviously have been even better. Still, I hope it's one step up from adding another random opinion!

The conclusion appears to be that BeatFind and Shazam know the most songs, but are also somewhat complementary and all of the services had at least one song they uniquely recognised.

---

    Fun facts:
     * Night Driver (W) said "1 Shazams". I think I was the first person to ever Shazam that. Some of the most obscure things had hundreds, often thousands of shazams!
     * You know where they are taking the hobbits but none of the services do!

    ========

    - ABC = found the song
    - # = number of attempts
    - f = exceptionally fast matching (when it did match, might not be first attempt)
    - ~ = knew one of the songs

    BeatFind:     2B  C     1E    2G 2H  1I  2Jf 2Lf 4M 2Nf 2Of 1Pf 1Rf ~S 2T  1Uf 1Vf 1W 1Xf Y Z
    SoundHound: A 1B        1E 2F 1G 2H  2If     1L         2O  3P  2R     1Tf 2U
    Shazam:       1Bf    1D 1E 1F 1G 1Hf 1I  2J  1L  1M 4N  1O  1Pf 1Rf    1Tf 1Uf 1V  2W 1X  Y Z
    MusixMatch: crashes on startup, presumably it realizes it won't be able to show me ads

    missingno
    Shazam:     A C K Q S
    SoundHound: C D F J K M/N Q S V W X Y Z
    BeatFind:   A D F K Q

    non-universal finds (repeated letter = unique = counts double; slash means same artist so should be counted as one)
    Shazam:     DD F J M/N V X Y Z
    SoundHound: AA F
    BeatFind:   CC J M/N S V X Y Z

    A: Levan Polkka Epic Orchestral Cover version
    B: Pokémon red/blue soundtrack
    C: Mayhem (various songs, it seems either they have all or they have none)
    D: Art Now ft. Snowflake
    E: Hero's Choice
    F: Three Days Grace - Scared
    G: Syrian - Supernova
    H: The Explosion - Here I Am
    I: The Von Bondies - C'mon C'mon
    J: Frank Klepacki - Scouting (C&C TibSun)
    K: Conspiracy - Chaos Theory (demoscene)
    L: Cheshyre - Madness6 (remix) (Newgrounds ID 77998)
    M: Dimrain47 - Twilight Techno
    N: Dimrain47 - Cloud Control
    O: DragonForce - My Spirit Will Go On
    P: Yuki Kajiura - The First Town (SAO)
    Q: THEY'RE TAKING THE HOBBITS TO ISENGARD! THE HOBBITS- THE HOBBITS- TO ISENGARD! TO ISENGARD!
    R: Faithless - Insomnia
    S: Age of Empires 1 soundtrack
    T: Moulin Rouge - El Tango De Roxanne
    U: Van Canto - Master of Puppets
    V: Slack Bird - Jouni
    W: Floppytronic - Night Driver
    X: EgoSalad / Kitboga - Breathe in
    Y: Floppy Drive music: top 4 hits on yt: sweet dreams, imperial march, ghostbusters, beat it. Only ghostbusters was known to any
    Z: Obsidian Shell - Orphanage
---

Note that what I did not test/review introducing noise (like people talking through it) or filtering (like when you hear the music through a wall)

comment 2y ago · link · parent

I gave it some thought but it's hard to say. For most of the ones I missed and mentioned in sibling threads, I can think of people who'd be aware of them:

- Probably <ruby> and related tags are used in Japanese and other spheres with such a language feature

- <base> I knew of, I thought archive.org used it but apparently not currently. Probably if you work with archived or otherwise namespaced content, you can reasonably find this a very familiar element

- <track> if you're a media person, doesn't seem that outlandish

- <dfn> I knew of basically, but just couldn't recall the names for glossary tags

- <kbd> is used all the time on Superuser (in Markdown, where HTML is valid though of course they filter most of it)

- Some others that I didn't remember, like <template> and <article>, were just stupidity. I know these...

This leaves <del> and <ins>. There are enough diffing tools, but it's not as big a category of software people constantly work on, especially since this is only for browsers. I'd not be surprised if these are the most-forgotten elements

Or does anyone still use <map>? I saw it in the HTML tutorial (linked from a Dutch magazine) that got me into programming so I know of it and remembered while doing the quiz, but it's fairly far faded from my mind and I'm not sure anyone would ever use it when, if you want this sort of functionality, you'd probably want the versatility of JavaScript

comment 2y ago · link · parent

I tried the exact same three! Eventually gave up on that path, thinking "I could swear HTML had some way to have a glossary...", and of course seeing it does after revealing the answers
123456