For the best experience on desktop, install the Chrome extension to track your reading on news.ycombinator.com
Hacker Newsnew | past | comments | ask | show | jobs | submit | history | more GlitchMr's commentsregister

> `filepath.Clean()` is not called `filepath.Canonicalize()`

Canonicalization of a path is a different operation, as a name suggests it returns a canonical path to a resource. The idea being that if you happen to have two paths that refer to the same file (say, `/bin/sh` and `/usr/bin/sh`) then you should be able to pass those to path canonicalization function to get the same string for both. This is not what `filepath.Clean` does, so calling it `Canonicalize` would be confusing.

For example, in Rust the following program when run in Rust playground (https://play.rust-lang.org/?version=stable&mode=debug&editio...) will output /usr/bin/dash:

    fn main() -> std::io::Result<()> {
        println!("{}", std::fs::canonicalize("/bin/sh")?.display());
        Ok(())
    }
Meanwhile, Go's `Clean` function is only concerned about lexical processing and ignores the file system entirely and would return `/bin/sh` here, as none of rules `Clean` uses apply.


This is a fair point. To be clear, I wasn't suggesting Canonicalize as _the_ name, but as one potential candidate. As you've shown, it has some shortcomings. Perhaps Normalize is a better alternative (and also another candidate that I suggest), since "Normalization" is a commonly used term for converting to a standard/normal form.


Most of the JavaScript is two empty videos encoded in WebM or MP4, encoded using Base64 to be stored in plain text, and picked depending on what the web browser supports. Considering I doubt that video formats are designed with empty videos in mind, this is probably not too bad. As for why videos are here, they are a fallback in case web browser doesn't provide Screen Wake Lock API (in particular, Safari and Firefox don't).


The problem is that Nintendo is not consistent about NES palettes either. Their different emulators all have different palettes, https://emulation.gametechwiki.com/index.php/Famicom_color_p... goes as far as to suggest their latest emulator (the one that is part of Nintendo Switch Online service) has as many as 12 different palettes where the palette picked depends on a game. Nintendo did have NES-based arcade systems that used RGB, however the problem is that their color choices were really ugly.


Google, Facebook, Reddit, Amazon, TikTok. I entered main pages of those websites, and they tried reading pixels of an invisible canvas for whatever reason.


This is such a weird argument. Let's say those things are true (and I think they are reasonably true).

- When an EU citizen requests a US internet resource, they provide a US server with their IP address

- An IP address is PII (well, personal data as far GDPR is concerned, but that's a nitpick)

- The CIA could record that

I don't think how you would go to a conclusion from those that "it is illegal to provide any internet resource to anyone in the EU".

First, it's worth noting that GDPR only applies to companies that specifically target its services at individuals in the EU. Targeting means having an EU office, using an EU domain, providing EU languages such as Polish or allowing payments in EU currencies. If your service makes no effort to provide service specifically for European users there is no need to worry about GDPR - even if you are in the US.

Second, while US services targeting individuals in the EU are legally problematic, this doesn't affect other countries - so I see no reason to say "any" here. For example, a Japanese server is free to provide services at individuals in the EU provided they comply with GDPR as EU has an adequacy decision for Japan.

Also, I would like to point out you can replace US with North Korea in this argument. I think it would be ridiculous to say that if European Union were to disallow sending personal data to North Korea (including IP address) then it would mean that it's illegal to provide any internet resource to anyone in the EU.


> Targeting means having an EU office, using an EU domain, providing EU languages such as Polish or allowing payments in EU currencies.

Nope. There's only a single requirement: having EU users.


GDPR recital 23 says the following:

> In order to ensure that natural persons are not deprived of the protection to which they are entitled under this Regulation, the processing of personal data of data subjects who are in the Union by a controller or a processor not established in the Union should be subject to this Regulation where the processing activities are related to offering goods or services to such data subjects irrespective of whether connected to a payment. In order to determine whether such a controller or processor is offering goods or services to data subjects who are in the Union, it should be ascertained whether it is apparent that the controller or processor envisages offering services to data subjects in one or more Member States in the Union. Whereas the mere accessibility of the controller's, processor's or an intermediary's website in the Union, of an email address or of other contact details, or the use of a language generally used in the third country where the controller is established, is insufficient to ascertain such intention, factors such as the use of a language or a currency generally used in one or more Member States with the possibility of ordering goods and services in that other language, or the mentioning of customers or users who are in the Union, may make it apparent that the controller envisages offering goods or services to data subjects in the Union.


You don't have to play hard mode. No need to guess what you deduced already, you can make a guess that doesn't use your previous deductions.


Nintendo has a lot of money, a failure of a home console after Wii U probably would kill their home console division (no reason to continue making products if they all fail), but it wouldn't kill the company as a whole, in particular they would keep making handheld consoles.

Since Sony has entered home console market, Nintendo was essentially unable to compete with them. Nintendo 64, GameCube and Wii U weren't successful compared to PlayStation. Wii and Switch on the other hand succeeded by doing something completely different to what PlayStation did.


Unlike other ARM CPUs, M1 optionally supports x86 memory model, that said, it doesn't matter outside of x86 emulation.


Entrapment can only be committed by government agents.


Pretty nifty project. I'm curious what whitelist are you using, would it be possible to list allowed domains somewhere publicly.

One suggestion that I have is to remove w3schools.com from the whitelist. MDN is a much better source for information about web development.


Here's a pastebin of the list I made yesterday [0] in a format that allows uploading to your own instance of programmable search. I have updated a few things since (like removing w3schools :)).

[0] https://pastebin.com/qLC0wQ0t


Consider applying for YC's Summer 2026 batch! Applications are open till May 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search:

HN For You