HNHacker News
TopNewBestAskShowJobs

collinmanderson

2,545 karma · joined September 26, 2014

submissionscomments
collinmanderson··on We pwned X, Vercel, Cursor, and Discord through a supply-chain attack
Generally code execution within browser/client-side javascript sandbox is just "XSS".

RCE usually implies server-side code execution (or breaking out of browser sandbox).

collinmanderson··on We pwned X, Vercel, Cursor, and Discord through a supply-chain attack
> But you can use an `img` tag (`<img src="evil.svg">`) and that'll basically Just Work

That doesn't help too much if evil.svg is hosted on the same domain (with default "Content-Type: image/svg+xml" header), because attacker can send a direct link to the file.

collinmanderson··on Tell HN: HN was down
Yes. It's hard to explain the experience of hosting a website since 2023.

A crazy amount of really dumb bots loading every url on the website in a full headless browser, with default Chrome user-agent string. All different ip addresses, various countries and ASNs.

These crawlers are completely automated and simply crawl _everything_ and don't care at all if there's value in what they're crawling or if there's duplicate content, etc.

There's no attempt at efficiency, just blindly crawl the entire internet 24/7. Every page load (1 per second or more?) is from a different ip address.

collinmanderson··on Announcing the Beta release of ty
I've always assumed it was something like:

ruff - "RUst Formatter".

ty - "TYpe checker"

uv - "Unified python packaging Versioner"? or "UniVersal python packaging"

collinmanderson··on Announcing the Beta release of ty
Thanks.

I really need better generics support before ty becomes useful. Currently decorators just make all return types unknown. I need something this to work:

    _F = TypeVar("_F", bound=Callable[..., Any])
    def my_decorator(*args: str) -> Callable[[_F], _F]: ...
Also, I use a lot of TypedDicts and there's not much support yet.
collinmanderson··on Microsoft has a problem: lack of demand for its AI products
> worst thing they've shipped since Internet Explorer

IE6 was a really good browser when it shipped in 2001, especially compared to Netscape 6.

The problem was it didn't improve for the next 5 years.

collinmanderson··on It’s time to free JavaScript (2024)
I like it. JSON’s father.
collinmanderson··on Django 6
Yes. I'm still maintaining a Django site that I helped get live in 2007. I started learning Django in 2006.
collinmanderson··on I want to build a chip fab in Canada
> I want to build a chip fab in Canada. Here's the plan:

> We need to raise ~$350 million to purchase a world-class extreme ultraviolet (EUV) lithography machine from ASML. Then, we get the machine installed and can start producing chips for cell phones, laptops, TVs, etc. If you want to join the party, check out the HN thread.

Based on this thread: https://news.ycombinator.com/item?id=46151810

collinmanderson··on The RAM shortage comes for us all
I'll happily invest $100 into this project in exchange for stock. let me know.
collinmanderson··on IBM CEO says there is 'no way' spending on AI data centers will pay off
I think it's also worth comparing to the CO2 impact of consuming meat, especially beef, which is pretty high.

(It's the training, not the inference, that's the biggest energy usage.)

collinmanderson··on IBM CEO says there is 'no way' spending on AI data centers will pay off
> I also have it document and summarise its own work.

Could you share some of your prompts or CLAUDE.md? I'm still learning what works.

collinmanderson··on It’s time to free JavaScript (2024)
The last time this was brought up, "WebScript" was mentioned as a possible alternative name. (Like WebAssembly, WebSockets, WebRTC, etc.)

https://news.ycombinator.com/item?id=45297066

collinmanderson··on Show HN: Explore what the browser exposes about you
https://coveryourtracks.eff.org/ is less detailed but shows the individual uniqueness of each attribute.
collinmanderson··on Shai-Hulud Returns: Over 300 NPM Packages Infected
> prefer the oldest version satisfying the given constraints

The problem is there's no metadata for which versions fix security bugs, and therefore which previous versions are now insecure.

collinmanderson··on Shai-Hulud Returns: Over 300 NPM Packages Infected
For Python's uv, I think the closest thing to a cooldown is something like:

    uv lock --exclude-newer $(date --iso -d "24 hours ago")
uv is considering a native relative date:

https://github.com/astral-sh/uv/issues/14992

collinmanderson··on The privacy nightmare of browser fingerprinting
> If I have a process that randomly installs and deletes wacky fonts, I'm unique at any given time

Technically for fonts, there’s no API for listing installed fonts, so trackers have to check each font by name. Likely they won’t be checking super obscure font names.

That method might help for other signals though.

collinmanderson··on Cloudflare Global Network experiencing issues
> If you have a site with valuable content the LLM crawlers hound you to no end.

The site doesn't even need to have valuable content. Any content at all.

collinmanderson··on Vine reboot called Divine has launched
The key point: AI content is banned.
collinmanderson··on Uv is the best thing to happen to the Python ecosystem in a decade
Does the conda package manager have the same issue?
collinmanderson··on Uv is the best thing to happen to the Python ecosystem in a decade
It handles CUDA version for PyTorch: https://docs.astral.sh/uv/guides/integration/pytorch/#instal...
collinmanderson··on Uv is the best thing to happen to the Python ecosystem in a decade
> AI/ML

The Machine-Learning world, especially "Google Brain" research team figured out that NumPy was an awesome piece of software for dealing with large arrays of numbers and matrix multiplication. They built "TensorFlow" on top of it around 2015 which became very popular. Facebook followed suit and released PyTorch in 2016.

IPython/Jupiter notebooks (for Julia, Python and R) from 2015 were another factor, also adopted by the AI/ML community.

The alternative data-science languages at the time were Mathematica, MATLAB, SAS, Fortran, Julia, R, etc, but Python probably won because it was general purpose and open source.

I suspect Python would not have survived the 2/3 split very well if it wasn't for AI/ML adopting Python as its main language.

> when the tooling was so inferior

Since 2012, Conda/Anaconda has been the go-to installer in the SciPy/NumPy world which also solves a lot of problems that uv solves.

collinmanderson··on Uv is the best thing to happen to the Python ecosystem in a decade
> I can only conclude, that the author of the article, and perhaps even the organization they work in, is unaware of other tools that did the job long before uv. If they really value reproducibility that much, how come they didn't look into the matter before? Things much have been really hastily stitched together, if no one ever looked at existing tooling before, and only now they make things reproducible.

Yes, Poetry has had lock files for years, and pyenv has been able to manage installations, but uv is "an incredibly powerful simplification" that makes it easy to do everything really well with just one tool.

collinmanderson··on Uv is the best thing to happen to the Python ecosystem in a decade
Sorry, you're right I should have said "plain venv", as in the program.

`uv run` will also sync the environment to be sure it exists and meets the correct specifications.

But yes, it's optional. You can also just do `uv sync` to sync the environment and then activate it like normal.

Or use `uv venv`, `uv pip` commands and just take the speed advantage.

collinmanderson··on Uv is the best thing to happen to the Python ecosystem in a decade
I agree that the speed improvements are inexplicable, as in I can't convince you in writing. "uv is fast!!!" doesn't do it justice. You kinda just have to experience it for yourself.

If you haven't spent 5 minutes trying it out, you don't know what you're missing.

If you're worried about getting addicted like everyone else, I could see that as a valid reason to never try it in the first place.

collinmanderson··on Uv is the best thing to happen to the Python ecosystem in a decade
The best pitch deck is spending 5 minutes playing with uv and trying out installing the dependencies for your project.

It’s hard to demonstrate the speed difference in a pitch deck.

collinmanderson··on Uv is the best thing to happen to the Python ecosystem in a decade
> I don’t really get that uv solves all these problems ve never encountered. Just make a venv and use it seems to work fine.

For me package installation is way, way faster with uv, and I appreciate not needing to activate the virtual environment.

collinmanderson··on Uv is the best thing to happen to the Python ecosystem in a decade
They plan on making money by running private package registries, rather than making money on the client. https://astral.sh/pyx
collinmanderson··on Uv is the best thing to happen to the Python ecosystem in a decade
What would you suggested as a recommend method of installation in 2025?

You can `pip install uv` or manually download and extract the right uv-*.tar.gz file from github: https://github.com/astral-sh/uv/releases

collinmanderson··on Uv is the best thing to happen to the Python ecosystem in a decade
I'm waiting for ty to get TypedDict checking. https://github.com/astral-sh/ty/issues/154
← PreviousPage 3 of 32Next →