564 points · by andreafeletto · 4y ago · 167 comments
Why? Well...
// test 64: more attribute tests
// attributes of the <object> element
var obj1 = document.createElement('object');
obj1.setAttribute('data', 'test.html');
// ...
assert(obj1.data.match(/^http:/), "object.data isn't absolute");
See that "http" in test 64? Turns out you'll get a score of 100/100 if you use the http version of the URL instead of HTTPS.https://twitter.com/OrphisFlo/status/1508954585993461763 http://wpt.live/acid/acid3/test.html
Test 35 requires root elements to not match :first-child, and the spec was changed to specify that they should match: https://bugzilla.mozilla.org/show_bug.cgi?id=1300374
I wonder if it could be pulled out as a portable library. Having another competitive browser engine would be a good thing.
As someone who has also been attempting to write a browser (engine) in my spare time --- but these guys are far ahead of me --- this is great to see.
Sure, it's good to have more options but, the deploy base of browsers like Chrome are massive and IE6 only lost its position by being careless and stop evolving (and lets not forget it took years), which is something that is not happening with Chrome.
Just to make clear, this is not specifically directed to you or your project, which is a great thing to do independently of the outcome. I'm saying this more as in a general perspective as we are pretty much sitted on the state-of-the-art of browser engines and its hard to see something else taking over except for a "game reset" scenario (outside of the web).
https://github.com/SerenityOS/serenity/blob/master/Meta/Lago...
This may be useful for devs who want to entirely ditch the STL in favor of a much cleaner and ergonomic library.
I can see this analogy as:
"Don't do your math homework. Instead, find hard math problems in real life to solve."
But note that it doesn't mean that the browser interprets modern CSS correctly.
Wikipedia's Acid3 page says:
> By April 2017, the updated specifications had diverged from the test such that the latest versions of Google Chrome, Safari and Mozilla Firefox no longer pass the test as written. Hickson acknowledges that some aspects of the test were controversial and has written that the test "no longer reflects the consensus of the Web standards it purports to test, especially when it comes to issues affecting mobile browsers".
Strangly, my Safari on iPad just achieved 100/100. a minute ago it achieved 97/100.
Does anyone know what's up with it? Are there timing dependencies? What are the divergences in modern specifications?
I'm joking of course. The things /I/ want [1] seem to take forever to get proper support.
-- Andreas Kling on this progress: (https://www.youtube.com/watch?v=Xa5_tW_eovM)
I get this is his passion project, but part of me wonders what he could accomplish working on the rough edges of linux.
I've watched/listened to more than a few of his videos. Something that he has expressed on more than one occasion is an appreciation for the kind of deep vertical integration that he saw at Apple because they control the entire stack. He's going for something in that direction in Serenity and it, for example, means that they're not taking on low-level dependencies on other projects.
Anyway, this is perhaps a roundabout way of saying that I don't think he'd be all that interested in hacking on Linux - a project that very much goes against that kind of integration.
Andreas: Well, I don’t know that I ever had a real direction with it. But in the beginning, I remember feeling kind of frustrated with finding myself using Linux again and thinking it’s nice to be back on Linux. Everything is snappy. And the developer experience is really great, but I sure do miss having the source code for everything.
Adam: This is a fascinating distinction to draw.
Linux is open source. Everyone has access to the code. But if you listen to episode 70 with Joey Hess talking about Debian, making changes can be a bureaucratic process. And that’s just for one distribution. There are hundreds of Linux distributions. Even if it’s a one line change, it could take years to get that upstreamed and spread into various Linux distributions. If you listen to episode 67 about Zig, that was one of Andrew’s motivations behind creating Zig.
But meanwhile, Andreas has another strategy at Apple. Everything was in one place, and everything was built internally.
Andreas: And when you’re in that environment, it’s extremely powerful.
The "problem" with Serenity OS is that yes, now Andreas will have all the power he wants and can get that one line change without the bureaucratic process. But what about when some random user comes along and wants to change the code? They better start programming on Tranquility OS.
No, I'm sorry. This is a very, very bad reason to start a new project from scratch. If you want to avoid bureaucracy then it's not hard to create yet another Linux or BSD distribution, countless people have done it. Once your project grows larger you will find bureaucracy creeping back in again because you have to make some of the same decisions. Do I accept breaking change A versus breaking change B? How do I force people to test a patch across thousands of machines at once before accepting it? How do we reach consensus on subjective things like fonts and icons? And so on.
These projects have plenty of other reasons to exist, it's not like they don't. This is just a poor explanation for why they exist. I hope nobody mentions this nonsense again in an interview.
There probably are hundreds of linux distributions exactly because people do not want to wait years for their change to ship, so they create their own project ...
That kind of sustained and focused work compounds over time and you just get better and better I guess. Reading stories like his makes me think I'm probably in the wrong industry because I don't enjoy coding that much and definitely have a ton of other things I'd rather do.
You're fine. Comparing yourself to Andreas Kling vis-a-vis coding is like saying you're going to stop playing the guitar because you're not Jimi Hendrix. Andreas Kling, while impressive and inspiring, is not normal.
Most people, myself included, don't want to do any one thing for 80+ hours a week. That's okay. If you enjoy working as programmer, just keep on trukin' and don't worry about what others are doing.
SerenityOS is an amazing accomplishment but it's just a hobby project without massive resources like major projects have.
Most real world apps have tons of devs that don't do 60 hours, the modern dev process just doesn't need it, unless you're doing large things entirely done by small teams.
> ... marriage between the aesthetic of late-1990s productivity software and the power-user accessibility of late-2000s *nix
> ... a system by us, for us, based on the things we like
Come on, just say you want back your Win98/Win2K look'n feel ;)
While I personally like my windows less decorated and more Mac OS-like, I'm quite impressed by the determination and progress of the SerenityOS team. Are there app porting guidelines, or maybe POSIX/LSB, X Windows, or other compat statements?
Andreas also uploaded 2 videos on his youtube channel of him porting Diablo and Duke Nukem to SerenityOS
There's no X server and we don't want to have WindowServer support the X protocol as a standard feature. If you're porting a GUI app, your best bet is SDL2, for which we have a battle-tested well-working port. However, you can just as well port an X server that talks to WindowServer or the video hardware directly, it's just that that doesn't currently exist. But I think such a thing would be perfectly accepted as a port.
Sidenote: If you want less decorated windows, there's System 7-like themes and other minimalistic ones. Or make your own :^)
[1] https://github.com/SerenityOS/serenity/tree/master/Ports
My biggest complaint about modern browsers is that I can't load a web page in less than 64 MiB, which is more than my entire computer had when I was running Netscape 3. The browsers are better now, but not in ways that necessarily use more memory.
At this stage, we're primarily focusing on correctness and compatibility, and performance is mostly a luxury. It's an area I look forward to eventually dealing with though, as it used to be my full-time job at Apple years ago and I have many fun ideas. :^)
I think of memory usage as being more about correctness than performance, though I know that isn't how most people see it. Trying to run a 512MiB process on a 64MiB computer, or a 512GiB process on a 64GiB computer, is just never going to run at a usable speed. Broken software is the limit as latency approaches infinity.
Moreover, I've never seen someone take software that needed 1 GiB to run and modify it incrementally into software that could run in 1 MiB, though I have seen the opposite.
We can definitely shave a couple of megabytes off of it with some effort, but supporting the contemporary web on a 4MB budget seems infeasible.
The pages you look at also have gotten ‘better’ in ways that necessarily use more memory. I don’t think you regularly loaded megabytes of JavaScript.
Finally, your browser usage likely has gotten ‘better’ in ways that necessarily use more memory. I guess you have more tabs open than you ever had in that 64 MiB.
As for JS, on most pages the only benefit of those megabytes of JavaScript is that I need to use uBlock Origin and/or Reader Mode to read what I'm actually interested in, the page jumps around at random while I'm trying to read it, Twitter tries to extort me into logging in, DoubleClick and reCaptcha can fingerprint my GPU, etc. Also, a megabyte of minified JS might reasonably compile down into a megabyte of bytecode or 4 MiB of native code, not 64 MiB or 128 MiB. JS's execution model is kind of inherently memory-hungry, though.
64 MiB is for one tab.
Serenity OS: Interview - https://news.ycombinator.com/item?id=30214371 - Feb 2022 (52 comments)
SerenityOS demo at Handmade Seattle 2021 [video] - https://news.ycombinator.com/item?id=29270776 - Nov 2021 (180 comments)
SerenityOS: Year 3 in Review - https://news.ycombinator.com/item?id=28817599 - Oct 2021 (46 comments)
Not-a-Linux distro review: SerenityOS is a Unix-y love letter to the ‘90s - https://news.ycombinator.com/item?id=28219800 - Aug 2021 (113 comments)
SerenityOS: Graphical Unix-like operating system with classic 90s UI - https://news.ycombinator.com/item?id=28206840 - Aug 2021 (129 comments)
I quit my job to focus on SerenityOS full time - https://news.ycombinator.com/item?id=27317655 - May 2021 (249 comments)
SerenityOS: Writing a Full Chain Exploit - https://news.ycombinator.com/item?id=26115141 - Feb 2021 (9 comments)
SerenityOS: A love letter to '90s user interfaces with a Unix-like core - https://news.ycombinator.com/item?id=23911180 - July 2020 (1 comment)
SerenityOS Update (April 2020) - https://news.ycombinator.com/item?id=23037581 - April 2020 (1 comment)
Introduction to SerenityOS Programming - https://news.ycombinator.com/item?id=22479132 - March 2020 (43 comments)
Pledge() and Unveil() in SerenityOS - https://news.ycombinator.com/item?id=22116914 - Jan 2020 (28 comments)
CTF writeup: First published SerenityOS kernel exploit - https://news.ycombinator.com/item?id=21918351 - Dec 2019 (2 comments)
SerenityOS: From Zero to HTML in a Year - https://news.ycombinator.com/item?id=21212294 - Oct 2019 (52 comments)
Serenity OS update (August 2019) [video] - https://news.ycombinator.com/item?id=20851356 - Sept 2019 (2 comments)
SerenityOS – a graphical Unix-like OS for x86, with 90s aesthetics - https://news.ycombinator.com/item?id=19986126 - May 2019 (179 comments)
Serenity OS Demo (April 2019) - https://news.ycombinator.com/item?id=19813417 - May 2019 (1 comment)
Serenity: x86 Unix-like operating system for IBM PC-compatibles - https://news.ycombinator.com/item?id=19537807 - March 2019 (83 comments)
But let's be a bit realistic, how long can we expect this to be a reliable daily driver on real machines and not stuck on a VM? It has taken more than a decade for one of them to even run reliably on several PCs and everyone is still waiting for another to not be ridden on a VM and actually run directly on real hardware. That is me not even talking about the apps there.
But if I have to choose one that will achieve all of that in the shortest time, then it would be Fuchsia wouldn't it?
Fuchsia is in a similar situation. Google may start pushing Fuchsia on some limited set of hardware, but I don't see a reason for them to start writing drivers for anything other than hardware from Google or Google partners.
Now, I could see SerenityOS as an option inside of something like Qubes OS. Here, the hardware is abstracted so you could run it on whatever. There may be some limited security through obscurity benefit to running an OS so far off the beaten path.
Like you, I'm dumbfounded by the achievement of Serenity OS. According to the Readme, Serenity OS is "a system by us, for us, based on the things we like." I don't know that making Serinity OS a daily driver for anyone who isn't interested in hacking on it is an actual goal for Andreas.
My main goal is to make a system for myself to use. I'm not particularly interested in working on stuff that doesn't affect my own use cases.
However, SerenityOS is not a one-man project. There are hundreds of other developers, all with their own individual goals, each putting their time and effort into making the system into something they would like to see as well.
I have no idea what will come out of this in the long run, but it's the most fun I've ever had, so I'm just gonna keep going and see what happens. :^)
I see it more as art honestly, even if it does end up having good utility, it will very much always be an encapsulation of this guys passion and expression.
Don't get too poisoned by the business world! Computers dont need to be just efficiency machines.
Edit: originally commented on uploading frequency but looks like they only do once a month
Serenity OS: Interview - https://news.ycombinator.com/item?id=30214371 - Feb 2022 (52 comments)
Someone mentioned BoksOS. That one is explicitly using Zig and made a conference demo [1] too.
There is ample evidence that even very excellent developers and teams can't avoid the footguns of c++ and that leads issues down the line.
If we just look at the browser, they seem to make much faster progress than Servo, but there is no doubt it will have security flaws.
Or alternately, that the community that SerenityOS has built and the joy they find in tinkering matters more than their technical foundations, in terms of getting something built that works and is maintained/maintainable. Servo looks like it could have been a technically better browser engine, but it seems the window for it becoming relevant is closing, while the future looks bright for SerenityOS's Browser. (I wonder how different things would be if Servo had reached the point where it was easy to run inside of a browser, in terms of dogfooding and getting people excited about it.)
What I would like to see is SerenityOS's joy and welcoming, vibrant community using better technology (in terms of security, if nothing else). Zig seems like a candidate for this, although people may debate its security features and technical merits. I'd love to see more projects like these.
Use after free, double free, invalid stack RW, uninitialized data, race conditions, etc. They're all possible to be found in Zig programs, because the language doesn't provide assurances against them.
> If we just look at the browser, they seem to make much faster progress than Servo, but there is no doubt it will have security flaws.
Servo was supposed to be the promise of better security in a new browser thanks to Rust. Unfortunately in reality that was just either hype or it was just slow moving progress or perhaps both.
But yes the SerenityOS browser seems to be moving faster than servo whilst sacrificing security.
By then we would be just still running Windows / macOS on our ARM desktops / laptops, Fuchsia on our phones, tablets and chromebooks, Linux still stuck on the server and everything else stuck in a VM or simply abandoned.
And here's a Quote Tweet chain as I was posting progress updates from 99/100 all the way back to 50/100: https://twitter.com/awesomekling/status/1507135024461721605
And then incremental rebuilds (when I go and pull the latest changes once in a while to see what's new) take anywhere between 1-10 minutes, depending on what changed exactly. YMMV.
For an entire operating system, it's pretty cool already! I wonder if C++20 modules will take it down some more, it's been mentioned a few times as something to investigate.
Acid1 and Acid3 are good now, but Acid2 still needs some work on CSS tables and miscellaneous little things.
And what language(s) do they use?
AFAICS most of the OS is in C++ with lower-level stuff in C.
> Acid3, in particular, contains some controversial tests and no longer reflects the consensus of the Web standards it purports to test, especially when it comes to issues affecting mobile browsers. The tests remain available for historical purposes and for use by browser vendors. It would be inappropriate, however, to use them as part of a certification process, especially for mobile browsers.
Source: http://www.acidtests.org/