HNHacker News
TopNewBestAskShowJobs

harg

394 karma · joined January 19, 2017

submissionscomments
harg··on Batteries Not Included, or Required, for These Smart Home Sensors
There already exists "kinetic" switches for lights etc whose switch contains some passive electronics that when actuated produces enough energy to emit a radio signal that can be read by a relay module. They're pretty handy as you can basically place the switch anywhere you want without the need for the wires to be there. The relay can live in the light fitting or somewhere else convenient.

There's probably no reason why these kinetic switches can't also be used for detecting other events like doors opening/closing etc. I feel like a radio signal is a bit more reliable and easier to detect than high frequency sound.

I also think calling these a "sensor" is a bit of a stretch. They detect events but have no knowledge of the current state of the thing they're sensing. E.g. the can detect a door opening/closing, but have no idea if the door is open or closed at a given time

harg··on IPv6 traffic crosses the 50% mark
Interesting to see Spain having such low IPv6 adoption. Perhaps that's exacerbated the issues caused there by blocking IPs during football matches that we've seen mentioned in recent HN posts.
harg··on IPv6 traffic crosses the 50% mark
Are you with SFR? I also seem to only have a static IPv4 (I don't pay for it, but it's never changed in the lifetime of the connection). I asked for an IPv6 but they said it was not possible/difficult.
harg··on jj – the CLI for Jujutsu
I believe the full docs page does indicate that there are binaries to install via popular package managers [1]

[1]: https://docs.jj-vcs.dev/latest/install-and-setup/

harg··on Cross-Site Request Forgery
The other replies answer this question, but it’s worth mentioning the public suffix list which contains a list of domain suffixes that have subdomains that are controlled by different people. E.g github.io, wordpress.com

Browser use this list to prevent cookie shared between sites using the suffixes on the list. E.g evil.github.io will not receive cookies from nice.github.io, or any other .github.io origin, regardless of the SameSite attribute

harg··on United Airlines grounds flights after system meltdown
Some of United's own aircraft are over 30 years old [1]. If you can rely on a well-maintained 30+ year-old aircraft to fly you halfway accross the world I think you can rely on a similar-aged car to drive across the country.

[1]: https://www.planespotters.net/airframe/boeing-767-300-n641ua...

harg··on Emailing a one-time code is worse than passwords
No, because unlike a password you never provide the private key for a passkey to the site you’re logging into, which is how many password breaches occur.
harg··on PHP 8.5 adds pipe operator
Or putting `|> dbg()` at the end and let it print the value at every step of the chain
harg··on xAI to pay telegram $300M to integrate Grok into the chat app
It's not clear text by default, it's just not end-to-end encrypted. Messages are still encrypted between client and server.

I agree about considering alternatives though.

harg··on Hacking a Smart Home Device (2024)
I wonder if it would be possible to figure out which pins are connected to what on the device's board and just flash the thing completely with ESPHome and write a custom yaml config for it, rather than adapting the existing vendor firmware.
harg··on I got a heat pump and my energy bill went up
You get more heat out of using a given quantity of gas to generate electricity which is used to to power a heat pump than you do by burning the gas directly for heat, even when considering generation and transmission losses etc.

Given that even during a time of low output from renewables we still only rely on 53% gas for electricity generation it's still much more beneficial environmentally to use a heat pump.

The monetary cost is another story though, and I agree we do need to work on weaning ourselves off gas.

harg··on UK to finish with coal power after 142 years
Hinckley point C is under construction in the uk and on track for 2026 opening

Edit: potentially delayed by some years

harg··on Demystifying Web Push Notifications
It's a shame that some sites are abusing this potentially useful feature to try and increase engagement on their site.

The correct (IMO) way to use this is to request permission after a user initiates it. E.g. clicking a button somewhere in the UI that says "Enable notifications" whilst being in some context where it makes sense to potentially want to enable them.

This is how the web share API works. Calling `navigator.share()` without user interaction will fail as it requires "transient activation"[2]

[1]: https://developer.mozilla.org/en-US/docs/Web/API/Web_Share_A... [2]: https://developer.mozilla.org/en-US/docs/Glossary/Transient_...

harg··on Ask HN: I’m an FCC Commissioner proposing regulation of IoT security updates
I don't think customers not caring is a valid reason to not do this. Compromised IoT devices don't only cause harm to their owners, but also external networks and the internet as a whole.

A compromised doorbell, or lightbulb etc can be used as part of a botnet to perform DDoS attacks or other nasty activities.

An analogy is like saying we shouldn't work on reducing the pollution emmitted by motor vehicles because the users of these vehicles don't care about how much pollution they cause and would buy them regardless. It's the negative externalities that we need to consider.

harg··on SMS traffic pumping fraud
> SMS is the only second factor that works for people without smartphones.

That's not correct. Many password managers have TOTP authentication features built in.

There's also increasing support for security keys (e.g. yubikey) with many websites.

Passkeys are also on the rise.

harg··on Uber posts first quarterly net profit
A few years ago it seemed everyone in London used Uber the whole time to get around. It was pretty cheap and convenient.

Nowadays very few people I know seem to use Uber (and the equivalents) on even an occasional basis. It's a lot more expensive than it used to be and you just can't rely on it any more.

I tried to get one last month for the first time in ages (from a not particularly out-of-way location) and no driver was around to accept my booking. It took over an hour of trying and I eventually managed to get a Bolt. It was a painful experience.

In a way it's a good thing - I don't think it's sustainable to have everyone be driven around in private. vehicles in European cities, especially when there's often very good public transit available. There was a point when Uber usage was simply a lazy habit for people. Although I accept that for some people and situations it is the best option (disabled, lots of luggage etc)

harg··on Show HN: An interactive map showing live wind farm generation in Great Britain
Solar is pretty popular in the UK. Panels have reduced in cost per watt and energy bills have increased so much that it makes it worthwhile for many homes and businesses.

We do get the occasional sunny day contrary to popular belief, but even on cloudy days it's possible to generate a decent amount of energy.

We also have very long days in summer which can make for a decent amount of kWh/day (although the opposite is true in winter)

harg··on Ask HN: How do I stop card testing attacks on my Stripe account?
Are you sure this is how it’s being done? My understanding of stripe checkout is that you need the secret key to create a checkout session.
harg··on Shutting down nuclear power could increase air pollution: study
Perhaps, but by an amount that is negligible when compared with fossil fuels:

https://ourworldindata.org/grapher/death-rates-from-energy-p...

harg··on Barilla passive cooker
no, because we're only comparing the energy required to cook the pasta; not the whole lifecycle.
harg··on 60% of home compostable plastic doesn’t fully break down
I think the motivation behind compostable plastic is to reduce the amount of micro plastics ending up in the environment rather than CO2 emissions.

That said, burning non-compostable plastic (with appropriate emissions control) does seem like an appropriate way of disposing of it, and generating some energy in the process.

harg··on Ask HN: So you moved off Heroku, where did you go?
How come you compile your app on your deployment platform? I know Heroku does this, but wouldn't it be easier to compile your Rust app on a beefy CI server and then just ship a binary or container image to your deployment infra where you can size the server according to runtime load.

E.g. I use Fly.io for one of my apps. I build a container image as part of CI on Github Actions and then just push that image to Fly as part of a deploy. Fly never deals with a build step (although it can do that as well).

$5 is very cheap for the Hetzner server you describe though.

harg··on Hydrogen production from the air
All that may be true, and I'm not disputing any of it. But all energy sources and storage methods have their drawbacks. They're not necessarily a reason to something out. I'm sure Hydrogen will play a role in certain areas (e.g aviation and steel production). The tech is still young so there's bound to be significant developments coming.
harg··on Hydrogen production from the air
H2 may well be a more potent GHG when compared to CO2, but it's tendency to remain in the atmosphere for a long time is a factor than shouldn't be ignored and doesn't seem to be mentioned by your first citation. I.e. H2 may be 16x more potent than CO2 but if it reacts away within hours/days/[<16th of the time that CO2 stays around] then its overall contribution to warming will be less than CO2. (I don't know what this figure is, but I believe Hydrogen is pretty reactive so doesn't tend to stick around that long)

From your second citation:

> The evidence base relating to non-GHG emissions from end-use in heating applications is almost non-existent

It then says that a single study:

> suggests there is potential for up to six times higher point NOx emissions compared with natural gas".

and that it could be significantly reduced with catalytic converters.

The points you raise are not nearly as unequivocal as you make them out to be. I also don't feel like Hydrogen is going to solve all of our problems - it has many problems that needs to be overcome. But it could well play a role in certain areas when it comes to getting off fossil fuels, so studies into more efficient production of it will surely be valuable.

harg··on A generically typed pipe function in TypeScript
I agree. This is what fp-ts's pipe[1] function does. It also has flow[2], which is basically a reversed compose.

[1]: https://gcanti.github.io/fp-ts/modules/function.ts.html#pipe

[2]: https://gcanti.github.io/fp-ts/modules/function.ts.html#flow

harg··on Best radios to use in an emergency (2021)
Even if used on the unlicensed bands it’s still illegal to transmit in those frequencies without a license as the UV5R doesn’t comply with the restrictions of license free radios. I.e it exceeds the max allowed power and has a detachable antenna.

However, there’s nothing illegal about using the uv5r to receive. And in reality if you only use it on the pmr446 frequencies you’re very unlikely to get busted.

harg··on New EU rules on car speed limiters coming into force
> How often do your seatbelt warning give out false positives?

Never, in any car I’ve ever been in, have I seen a false positive seatbelt warning.

harg··on Upptime/upptime: Uptime monitor and status page powered by GitHub
Generally it’ll be used for monitoring uptime of another project. So even if that falls under “maintaining” it wouldn’t be for the project “in the repository”, unless you somehow combine upptime into the repo of the project you’re monitoring. But that could get very messy.
harg··on In praise of the humble Sheffield stand
At least in the UK, many of the sheffield stands are made of fairly thick-walled steel and 50mm outer diameter. It would take quite a bit of time and effort to cut one with any hand tool. A solid design would be complete overkill and make them really expensive.

That said, some do pop every now and then up that seem to be quite flimsy, often having been bent down to a 45 deg angle by a careless motorist.

harg··on Next.js Layouts RFC: Nested routes and layouts, designed for Server Components
There's nothing stopping you from wiring the Next.js backend up to your databases and external APIs and for simple apps it's likely quite a nice solution. But if your backend consists of complex business logic and needs to talk to lots of different services it can be a lot cleaner to have better distinction between the backend part of your app and the frontend, and just use Next.js' backend for data fetching for the UI.

You can also not use Next.js without a Node.js runtime at all and just compile your whole app to static files to be served by a static file server like S3, nginx, etc. The advantage of this over CRA is that you get statically-rendered html (as well as normal client-rendered React interactivity) which is good for SEO and FCP[1]

[1]: https://web.dev/fcp/

Page 1 of 4Next →