Hacker News new | past | comments | ask | show | jobs | submit | zx2c4's comments login

From the article: "It remains possible to put arbitrary bytes AFTER the parts of the shell script that get parsed & executed (like some Solaris patch files do). "


Why fork/copy&paste wireguard-go source code instead of using wireguard-go's existing netstack package? Couldn't you help improve instead?


I would be interested to learn from somebody with experience using both Bun and Deno: which one is actually the more compelling Node successor? Bun's website makes some impressive performance claims over Deno. Are these true in practice? And if so, why? Seems like Deno also has similar goals. Also, are there large philosophical differences between the two projects? Like Bun tries to reimplement the kitchen sink but Deno wants a new post-Node way of doing things? (Just guessing, no idea if that's true.)

Any seasoned users with time spent on both?


I’m not over the moon with it but I’m kind of interested to know why I need a Node successor at all. Both Bun and Deno are VC funded tools so I have base level suspicion around monetization and longevity.

It seems Bun’s major selling point is performance. I can’t say I’ve really run into massive performance concerns with Node. It isn’t earth shatteringly fast but I’m way more likely to run into IO constraints than Node speed issues.

Deno’s major selling point was that it was Node Done Right in many ways: better packaging, ES6 all the way, etc. (a pitch I was sold on!) but it seems they gave up trying to create a new ecosystem and instead are adding Node compatibility.

Alongside all of this I'm encouraged by a number of recent Node improvements like having its own test runner and built in .env support. So I’m struggling to see good reason to use either Bun or Deno. Even if I were to switch I'd need to make sure I have a concrete path back to Node should the new generation tool become unviable.


It is well explained in the blog article: https://bun.sh/blog/bun-v1.0#why-bun-exists

This is extremely compelling for frontend DX.


That kind of speaks to my point, though: a number of the features listed there (e.g. test runner, .env file support, watch mode) have either been recently added to Node or will be soon (and are available today as experimental flags).

The bundler stuff is certainly more compelling though the page doesn't specify what makes it better than esbuild except that it comes built-in... but that's where, for me, VC concerns raise their head. If I go all in on Bun bundler, what happens if the company switches their priority towards monetization and neglects the bundler? I'm going to have to unroll all the configuration work I will have done and go back to an external bundling library. And it's still not entirely clear what I gain!


If it delivers on the promise of solving the require vs import module nonsense that would be enough for me. Maybe node copies that too, but that's also a win imo.


Does Deno suffer from that in the first place? I don't know what that issue even is, so I'm just asking.


Getting VC funded HHVM vibes.

Not sure how they plan on monetizing.


Seems they both have similar plans: serverless hosting, continuous integration, etc. etc.

All valid ideas. But the involvement of VCs makes me wonder what kind of scale they're going to be expected to achieve and what will happen if they don't.


I'm super skeptical of the viability, much less the desirability, of language VM specific CI and hosting services..

Feels like an acquisition by Cloudflare/Vercel is a more likely exit scenario.. But then if we get an HHVM repeat and most of the benefits are just introduced into Node proper what's the real value to the aquirer? Aqui-hire? Deno has raised at least $25m though, and bun $7m..

I guess most startups fail so maybe there is just no answer.


Google is failing me - what's the VC spin on HHVM?


VC spin?

HipHop Virtual Machine was created over a decade ago to address serious performance issues with PHP. This spurred(lit a fire?) serious efforts to address the issues in PHP proper. Over a rather short period of time PHP became performant enough that HHVM was sunsetted.

I think the history here would call into question the viability of Bun as a monetary investment. It may end up a net good for the ecosystem , but if the major benefits can just be incorporated back into Node proper what are the ROI prospects?


Thanks for the clarification.

I thought you're original comment was saying something to the effect of "VCs funded HHVM, and this feels similar."

I'd only heard of HHVM in the context of Facebook, so I was surprised to read that (but I know Phabricator was another infrastructure company spun out of FB, so it seemed possible).


These tools are way too young for anyone to have actually spent a lot of time using them.

Bun is bundling everything and making it really fast, while also striving to maintain as much compatibility as possible with Node. It doesn't throw away the existing ecosystem.

Deno took on too much of an adversarial perspective towards the Node ecosystem and now they're working towards re-adding support.

So in terms of a successor, I'd say the only option is Bun because it's still trying to maintain compatibility with Node while innovating with new features.


Not a seasoned users, mostly played with Deno. To me Deno seems more oriented to be an alternative Node runtime with security as first principle and built-in support for Typescript, JSX with some tooling like linter. It's also based on V8. My best guess it's what Ryan Dahl wanted Node to be as an afterthought. Bun, technically speaking is based on Webkit, but can't really say why, seems a better all-in-on tool(also remember rome?) and not only a runtime. Also with compatibility with current frameworks out of box, Deno wasn't npm compatible some time ago and I wonder if it ever meant to be and not a pivotal change on the run


> technically speaking is based on Webkit, but can't really say why

Why Bun uses WebKit/JSC was described here:

> One of the reasons why Bun bet on JavaScriptCore instead of embracing the server-side V8 monoculture is because JavaScriptCore and WebKit/Safari are strongly tied together. This means that Bun can often use implementations of Web APIs from WebKit/Safari directly, without having to reimplement them. This is a great example of that.

via https://bun.sh/blog/bun-v0.7.1#messageport-messagechannel-ar...


It's known that Deno tacked on NPM support.

For new, from-scratch projects done by someone who doesn't know Node anyway, why not use Deno? I just started writing the server side of a mobile app with it, and I didn't even know JS, TS, or have any experience with routing frameworks. I had server-side queries working in a matter of days, and I don't claim to be fast at all.

The issues cited in the Bun PR, like the morass of modules and related performance problems, don't seem to exist in plain Deno. Or am I missing something? I don't anticipate ever integrating anything from NPM, so I'm actually disappointed (but understanding of the motivation) to see Deno hedge on the "fresh start" idea.


You’re unlikely to encounter any issues with Node in a small project. It’s possible though that you’ll need some module that is not working with Deno.


Thanks. If I can do CRUD and client authorization I should be OK…

I say now, anyway!


We're a full-stack TypeScript shop, and I manage ~50 internal libs and ~500K LOC of TS. Last month I tested out both Deno and Bun as alternative runtimes for us. TLDR: for any semi-complex codebase we have, Bun almost always works, Deno almost never works. We now run all our tests in both Node.js and Bun, and gave up on trying to make Deno happen.


What were your "semi-complex" codebases written in and for? Were they testing native Deno, or its integration of NPM packages?

I have never used Node and am creating a new project from scratch, so I don't know how worried to be about your commentary.


The "semi-complex" code is legacy code, aka revenue code. Started with plain JS in CJS on Node 12 and evolved to strict TS/ESM on Node 20. A lot of cruft built up from that multi-year evolution.

These days, if you're authoring from scratch, just write idiomatic TS in ESM, and you'll be fine. Even if targeting only Node, prefer to use Web standards (e.g., fetch, Request/Response, WebCrypto, Web Streams, URL, AbortController) as Node is migrating in that direction, and standard-compliant code will give you optionality in runtimes (Bun/Node/Workers).


Thanks for the reply! I'm just writing TS code that utilizes Deno/Oak and their MySQL support, to present a REST-style API. I don't know enough to say whether these depart from the standards you're recommending. If they do, I don't know how I would do routing and API support using only the things you mentioned. I'm a one-man band writing both a mobile app and the server to support it. I also know very little about scaling, which I anticipate hiring outside expertise on.

I want to invest my time wisely and learn portable techniques, but I realize the scope of my ignorance may exceed what you can address in a comment forum!


I have the luxury of toying with tech because the business around it is relatively successful. Engineering deep-dives are a lagging indicator of success (your own or your employer's) and almost never a leading one. All those "we did X/Y/Z with cutting-edge stuff" blog posts are overwhelmingly written by people who don't need to worry about bringing in money to pay for the time spent on that stuff.

Choose the tech stack that allows you to rapidly experiment in building something other people will give you money to use. That means choosing DX and iteration speed over runtime speed. That means using whatever gives you the most joy, so you're incentivized to build more often. That means something high-level so you don't waste time re-building components your customers don't care about, so you spend fewer hours on invisible, undifferentiated, but complex and time-consuming stuff.

If you're most effective with JS, Node is fine. Bun is fine. Deno is fine (for greenfield). One is super stable, battle-tested, and has 10x more contributors and 100x more libraries than the other two (most of them are trash). This maturity gap may not matter at all or may break your startup if you must re-implement something complex or continuously spend hours understanding and battling your runtime with minimal information on the web from others who encountered the same problem before. The same goes for your prod infrastructure, mobile app architecture, business ops, infosec, etc. Choose boring technology https://boringtechnology.club


Thanks for that. I'm in the middle situation, in that I'm somewhat in a hurry but not desperate (yet). So far I've been pretty encouraged by how quickly I've gotten something working with Deno; the main reason I went with it over PHP 8 is that I wanted to learn JS/TS. Second, the author's goals of addressing Node shortcomings and providing a cleaner import mechanism resonated with me. Thus far it hasn't annoyed me, which is a miracle because I'm easily annoyed. I think sifting through a vast collection of libraries (mostly junk, as you say) would annoy the shit out of me but more importantly waste valuable time.

I learned that problems that seem simple and solved apparently often aren't, regardless of how many blog posts and HN posts there are about the framework of the week. I needed to define an API, so I did so using OpenAPI. While the idea and standard seems mostly sound, the tooling (from editing to code generation) is absolute trash. I wasted soooo much time trying to make it work. Should I ever use it again, I'm writing my own tools. But right now I do just need to get stuff done.


If you don't mind sharing, what are some of the issues you've had with Bun so far?


  1. Missing `node:http2`
  2. Missing `node:test`, so it's more difficult to execute the same test files within Bun as we do via Node. I wrote a custom Bun loader to mock parts of `node:test`.
  3. Vite and ESLint do not work.
  4. Still occasionally segfaults, and it's difficult to find out why/where.
  5. Surprisingly, some code runs slower in Bun than in Node. For example, generating JWE with symmetric encryption. But this might be WebCrypto vs OpenSSL.
  6. Subtle differences between WebKit and V8 (e.g., how they handle dates).


Have you tried since v0.7? Vite support was supposedly added then


So it has, thanks for pointing that out. I goofed as I actually actually meant to write Vitest, which remains broken in v1.0.


I am annoyed with the bombastic claims behind bun.

I wasted a day trying to get vite to work when they first announced it. Really excited about not needing >1gb of ram to compile a react project... Boggles my mind that react bundling uses more RAM than compiling linux.

It is still unable compile http://chatcraft.org due to some problem with wasm plugin.

They also said that bunx --bun option was a pre-1.0 workaround, and didn't keep that promise.

Performance-wise their claims are suspect, safari js engine was always better at startup and memory use at the expense of a relatively weak JIT. They paired that up with a ton of stuff reimplemented in native code to make their cli and hello world workflows fast. This means people will be in for a perf surprise when they start bottlenecking in JS hotpaths.


And you're right to be skeptical. With performance, so much depends on your actual code and program-specific bottlenecks. The difference in runtime speed between JSC and V8 is minimal, so a lot of Bun optimization must be in the gaps between your code and the core JS engine or in startup time (e.g., running `bun install` or `bun test`).

In my benchmarks, our actual runtime performance of long-running JS code is ~25% faster under Bun than under Node. However, sometimes Bun is ~25% slower - notably with tasks that require binary processing (e.g, fflate, sharp) or encryption (e.g., jose). We're committed to JS and will be constrained by its performance for a long time, so a "free" 10-30% speed up at runtime is worth the effort, but it's not a 10x slam dunk like the benchmarks on Bun's homepage imply.


I haven't been able to get any work code working in Bun yet. All my personal/pet projects work fine, though. Speed is impressive when it works.

I did raise issues with repros for it only wasn't able to try to fix the issues myself. Building Bun is not working for me


If I recall correctly, Bun doesn’t support Windows, unlike Node/Deno.

Edit: sounds like this is changing. Thanks for the correction!


It has experimental support as of this release: https://bun.sh/blog/bun-v1.0#bun-more-thing


Interesting! The original link has no Windows binaries, so I assumed nothing had changed.


The link has been changed to the Bun 1.0 blog post which specifically mentions experimental/incomplete Windows support.


Deno wanted to be different but never did enough to force its way. Maybe if they had 10x the funding to rewrite the ecosystem. Now it's in limbo.

Bun aims to be a better replacement to Node. There's less to consider so it's just a matter of if it's compatible enough and faster / better to warrant the switch. A lot easier to swallow.


There's plenty to consider if you don't care about Node compatibility. From what I've read (including in this thread and on the Bun PR page), Node seems pretty messy, with modules coming from different sources in different ways. In Deno you just import with a URL.

I know very little about JS and TS and "modules," but from a newcomer that's how it all looks. I'm happy to have any further insight!


Does Bun support url imports for module loading?


I was curious about this too, whether Bun supports URL module imports. Skimmed through the documentation a few times, and I believe it does not.

But, the command `bun install` supports NPM and custom registries, as well as Git and .tgz URLs.

https://bun.sh/docs/cli/install#git-dependencies


I think you can achieve this via a bun plugin


Deno wanted a post-Node way but they have gone back on their original ambitions (which never resonated with me, to be frank) and now have a pretty limited compatbility whereas Bun has full compatibility with Node.


Per their own docs, Bun is not fully Node compatible [0]. In my experience, even for APIs its docs claim full-compatibility has some sharp edges. That said, Bun's node-compat story is better than Deno's.

While Node's performance story keeps improving release over release [1].

[0] https://archive.is/NCzRQ

[1] https://twitter.com/lemire/status/1699459534190698999



Sounds like you have a handy script to paste here... :)


I love the initiative, of course. How could I not? The idea of folks casually taking a dip in this city is really nice. I spend a lot of time beside the Seine - writing code on my laptop, even! - and being able to dangle my legs in sounds nice.

But... No matter what they say about bacteria measurements and other high quality quantitative indicators, there will still be swimming bags of potato chips and cigarette cartons and beer cans and receipts, and all the other junk Parisians tend to toss in there, even the occasional Vélib' bicycle. The thought of going for a nice swim only to whack my foot on a rusted underwater bicycle gear and then leave the water with a sandwich wrapper clinging to my back isn't very appealing. So I wonder how this will be managed, and how separated the three proposed swimming spots will be.

With that said, I went swimming in the Ohio River as a child, and I guess I'm still alive, so ¯ \ _ ( ツ ) _ / ¯


Hopefully this introduces pressure to actually get littering taken more seriously. If there are communities who want to swim, but feel uncomfortable about it, those communities can begin to pressure the government to deal with those problems.

Given that the article mentions that there will be officially held races/ marathons, I suspect that there will be a lot of money being put into keeping the water clean and safe. It seems like the city has been very invested in improving the water quality of the Seine and I expect that to continue with the additional pressure of human swimmers.


> there will still be swimming bags of potato chips and cigarette cartons and beer cans and receipts, and all the other junk Parisians tend to toss in there

Time to enforce littering fines.

Seriously, as a French person living in Belgium, I am disgusted with how little of a shit people give about keeping their own city clean.

If we start enforcing littering fines a bit more in western europe, this shit will stop within a couple of years. It's 100% cultural and this is something we absolutely have to change in our culture.


I think most people do care about keeping their city clean, at least in western Europe. The problem is that it's enough for a very small fraction of the people to ruin it for everybody else. Besides, I'm not sure if littering fines work. I'm all for it, but the risk to get caught is incredibly low. I mean, 700000 persons driving without driving licence in France, bikes get stolen like there's no tomorrow, I could go on and on... nobody cares about fines.


Western Europe has always been cleaner than both Eastern Europe, and the US, but things have been backsliding.

Things have recently changed for the worse. eg. I was in Paris, and I could see a stark contrast between now and 10 years ago. Also, parts of Italy seem to be backsliding, and then you have parts of Croatia that look better than many western parts.

Ps. In the US, NYC and SF are pretty 'dirty' overall, but then you have mid tier cities such as Miami, Boston, D.C., that are and feel very clean overall.


As much as I hate it, the real way to achieve the level of compliance you describe is through surveillance, akin to what China does or what Black Mirror depicts.


Isn't this statement disproved by places like Japan or other cities where there isn't China-tier surveillance but also littering isn't really bad?


I’ve never really understood the Japanese system. Public trash cans are essentially nonexistent.


Me neither, but it works. Japanese cities, even Tokyo, are SO much cleaner than cities in Europe, it's ridiculous. (They do have public trash cans in every convenience store, by the way.)


I will be downvoted but the obvious truth is that Japan has way less Moroccans and Algerians.


No, because people in different places behave differently, for whatever reason.


Culture is the reason. Japanese people have a more collectivist instead of individualist society, which promotes a shared sense of ownership in society. (At least, this is what they taught me in my Japanese courses in college)

Changing culture is hard. But, some cultural shifts have been brought about by public awareness campaigns, protests, etc.


Singapore made that cultural shift within a generation.


Corporal punishment sure is effective at controlling a populace.


You are not going to bring about a Japanese or Scandinavian or whatever other “model” culture anywhere within a reasonable amount of time.


What makes it harder is the naysayers. Change is more likely when people think it is possible.


Why not assess a fine to the original manufacturer of the litter (their logo is all over it), then use the proceeds to fund ongoing cleanup. Brands that are able to court responsible end users will find an edge in the market so will be compelled to use their marketing arms to raise awareness of the issue, perhaps even going so far as to fund their own cleanup efforts or incentivized packaging return.


Mac Donald's would go bankrupt overnight, at least in France. It's crazy how much Mac Donald's garbage are all over the place.


Is that a pro or a con?


Come on, dystopians.

How about some education and trusting people to act as grown-ups?

(Disclaimer - I live in Sweden)


The average person is reasonable and could probably be trusted to do the right thing. It's the 50% below average whom I'm worried about. You'll probably find a Pareto-like distribution on littering, i.e. ~80% of the litter is produced by ~20% of the people.


Another example that comes to mind is graffitis. My city is full of them. It takes seconds to make one, and hours to remove it. A few dozens of people could make a lot of damage within a few months.


Which is why it is not analoguous to litter.


That is just one model.

Another model is thinking of people as a part of a herd. If noone around you dumps garbage in the river, you are less likely to do it yourself.

You just need to create that positive spiral.


Yeah I don't think surveillance is the way. Greatly increased fines and making police actually care about catching people would be a good start.


The only way (in any endeavour really) to truly achieve success is to get people on your side.

Make them realize they live in a beautiful city and that they are a part of it.

May take some time, maybe even decades of barely measurable results. But i believe it is the only method that works in the long run.


What do you propose? Do you think people aren't currently told that littering is bad and then simply trusted (like adults) not to do it?



I don't think this is the only way. I spent a couple of weeks in Rwanda last summer and was stunned by how clean the streets are both in Kigali and in the countryside.

I heard several years ago the picture was similar to neighboring countries (not good). This indicates that the cleanup is possible without introducing total surveillance.


I really don't think that's necessary. Just by having reasonable proximity to Public trashcans radically reduces littering.

Some level of perceived enforcement is required, but in reality it just needs to be a sign with a high fine on it. And finally some level of public funded cleanup groups and you can get pretty far with keeping spaces clean.


People are much less likely to litter in a pristine park than in a park already filled with litter.


Or you just make it cultural like Japan.


people swim in the Danube in Vienna, so it doesn't sound impossible


You forgot dead animals and syringes


And between 20 and 50 dead people every year.


"It's like the ocean, but cleaner"


I doubt that, actually.


Seems that this could be addressed separately with better enforcement for littering/dumping?

People there don't regularly assault people on the street, brandish firearms, or drive vehicles without number plates. There is a possibility for law enforcement to set social expectations around dumping such that people don't actually do it out of fear of serious legal consequences.


How you imagine this? Police don't have free resources already and it is hard to catch a person throwing a bottle in a river in the moment. Video surveillance and face recognition may work but sounds dystopian.

In my observation a mix of culture and working cleaning services is a better predictor of clean streets than fines. It matters a lot if people want to live in a clean environment or they don't care. I have an empathy gap here and it's hard to understand why but I see that some people either don't mind garbage lying around or too lazy to carry it to a place where it can be disposed (nearest litter bin if they exist in this area or home if not).


Size is the only difference to swimming in the ocean or a lake, unlike lakes though, rivers flow and move the trash away


I love this project. Super simple to interface with, accomplishes the task very well, reliable, good documentation. It's hard to think of better design and execution for this type of utility.

I use it to get notifications of the CI running on build.wireguard.com, which took less than a minute to get working. Sometimes I'll use it for random one-off notifications, like when a command finishes running or some shell script sleep-loop scraper finds what it was waiting for. It's the nicest thing I've had for that kind of thing since mytelephonenumber@txt.att.net.


Thank you for saying that Jason; it means a lot coming from you.

I remember when you sent me that email months ago it was super cool for me. The creator of WireGuard emailing meee? whoa! Anyway. Thanks again for the kind words.


Yes! Very excited by this. We developed this together out-of-tree, and it's been available in ports (FreeBSD's package system) for a while now. This here is about moving it into the FreeBSD base system, so that it'll now be developed and improved alongside the rest of the operating system. Terrific step forward.



I too really loved Fireworks (and Dreamweaver) back in the Macromedia days. As a kid then, it was really very intuitive to do all sorts of odd creative projects easily.

Riding on nostalgia fumes, I went searching for screenshots and in the process amusingly found: https://askubuntu.com/a/244128 - a Linux user still running Fireworks 8 in WINE. I'm almost tempted to try the same...


I just did, since I have WINE installed to run music software. It runs _perfectly_, although with early 2000s era UX conventions (i.e., very small fonts, some pixelated). Edits seem very fast, although it is hard to say on my hardware (Ryzen 7). As a curio, it's a fun experiment, but being a bit less nostalgic and more realistic now, I'd quicker reach for GIMP or Krita on Linux (on the Mac, I use Pixelmator Pro and Affinity Designer for the semi-advanced editing I need)... Although I do love this thing.

FYI, the download of version 8 was available to use as a 30-day trial, which seems legal enough today, if only for experimentation, and I actually have a license of MX someplace from my G4 Mac days.


Those two pieces of software were undoubtedly the thing that got me into websites, which led to building computers, which led to my current career.

Incredible stuff.


I actually do that myself. I also use Fireworks 8 on windows when possible. I am yet to find a software that actually replaces it.


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

Search: