1. 28

    That is a very reductionist view of what people use the web for. And I am saying this as someone who’s personal site pretty much matches everything prescribed except comments (which I still have).

    Btw, Medium, given as a positive example, is not in any way minimal and certainly not by metrics given in this article.

    1. 19

      Btw, Medium, given as a positive example, is not in any way minimal and certainly not by metrics given in this article.

      Chickenshit minimalism: https://medium.com/@mceglowski/chickenshit-minimalism-846fc1412524

      1. 13

        I wouldn’t say medium even gives the illusion of simplicity (For example, on the page you linked, try counting the visual elements that aren’t blog post). Medium seems to take a rather contrary approach to blogs, including all the random cruft you never even imagined existed, while leaving out the simple essentials like RSS feeds. I honestly have no idea how the author of the article came to suggest medium as an example of minimalism.

        1. 8

          Medium started with an illusion of simplicity and gradually got more and more complex.

          1. 3

            I agree with your overall point, but Medium does provide RSS feeds. They are linked in the <head> and always have the same URL structure. Any medium.com/@user has an RSS feed at medium.com/feed/@user. For Medium blogs hosted at custom URLs, the feed is available at /feed.

            I’m not affiliated with Medium. I have a lot of experience bugging webmasters of minimal websites to add feeds: https://github.com/issues?q=is:issue+author:tfausak+feed.

        2. 3

          That is a very reductionist view of what people use the web for.

          I wonder what Youtube, Google docs, Slack, and stuff would be in a minimal web.

          1. 19

            Useful.

            algernon hides

            1. 5

              YouTube, while not as good as it could be, is pretty minimalist if you disable all the advertising.

              I find google apps to be amazingly minimal, especially compared to Microsoft Office and LibreOffice.

              Minimalist Slack has been around for decades, it’s called IRC.

              1. 2

                It is still super slow then! At some point I was able to disable JS, install the Firefox “html5-video-everywhere” extension and watch videos that way. That was awesome fast and minimal. Tried it again a few days ago, but didn’t seem to work anymore.

                Edit: now I just “youtube-dl -f43 ” directly without going to YouTube and start watching immediately with VLC.

                1. 2

                  The youtube interface might look minimalist, but under the hood, it is everything but. Besides, I shouldn’t have to go to great lengths to disable all the useless stuff on it. It shouldn’t be the consumer’s job to strip away all the crap.

                2. 2

                  That seems to be of extreme bad faith though.

                  1. 11

                    In a minimal web, locally-running applications in browser sandboxes would be locally-running applications in non-browser sandboxes. There’s no particular reason any of these applications is in a browser at all, other than myopia.

                    1. 2

                      Distribution is dead-easy for websites. In theory, you have have non-browser-sandboxed apps with such easy distribution, but then what’s the point.

                      1. 3

                        Non-web-based locally-running client applications are also usually made downloadable via HTTP these days.

                        The point is that when an application is made with the appropriate tools for the job it’s doing, there’s less of a cognitive load on developers and less of a resource load on users. When you use a UI toolkit instead of creating a self-modifying rich text document, you have a lighter-weight, more reliable, more maintainable application.

                        1. 3

                          The power of “here’s a URL, you now have an app running without going through installation or whatnot” cannot be understated. I can give someone a copy of pseudo-Excel to edit a document we’re working together on, all through the magic of Google Sheet’s share links. Instantly

                          Granted, this is less of an advantage if you’re using something all the time, but without the web it would be harder to allow for multiple tools to co-exist in the same space. And am I supposed to have people download the Doodle application just to figure out when our group of 15 can go bowling?

                          1. 4

                            They are, in fact, downloading an application and running it locally.

                            That application can still be javascript; I just don’t see the point in making it perform DOM manipulation.

                            1. 3

                              As one who knows JavaScript pretty well, I don’t see the point of writing it in JavaScript, however.

                              1. 1

                                A lot of newer devs have a (probably unfounded) fear of picking up a new language, and a lot of those devs have only been trained in a handful (including JS). Even if moving away from JS isn’t actually a big deal, JS (as distinct from the browser ecosystem, to which it isn’t really totally tied) is not fundamentally that much worse than any other scripting language – you can do whatever you do in JS in python or lua or perl or ruby and it’ll come out looking almost the same unless you go out of your way to use particular facilities.

                                The thing that makes JS code look weird is all the markup manipulation, which looks strange in any language.

                                1. 3

                                  JS (as distinct from the browser ecosystem, to which it isn’t really totally tied) is not fundamentally that much worse than any other scripting language

                                  (a == b) !== (a === b)

                                  but only some times…

                                  1. 3

                                    Javascript has gotchas, just like any other organic scripting languages. It’s less consistent than python and lua but probably has fewer of these than perl or php.

                                    (And, just take a look at c++ if you want a faceful of gotchas & inconsistencies!)

                                    Not to say that, from a language design perspective, we shouldn’t prize consistency. Just to say that javascript is well within the normal range of goofiness for popular languages, and probably above average if you weigh by popularity and include C, C++, FORTRAN, and COBOL (all of which see a lot of underreported development).

                            2. 1

                              Web applications are expected to load progressively. And that because they are sandboxed, they are allowed to start instantly without asking you for permissions.

                              The same could be true of sandboxed desktop applications that you could stream from a website straight into some sort of sandboxed local VM that isn’t the web. Click a link, and the application immediately starts running on your desktop.

                            3. 1

                              I can’t argue with using the right tool for the job. People use Electron because there isn’t a flexible, good-looking, easy-to-use cross-platform UI kit. Damn the 500 mb of RAM usage for a chat app.

                              1. 4

                                There are several good-looking flexible easy to use cross-platform UI kits. GTK, WX, and QT come to mind.

                                If you remove the ‘good-looking’ constraint, then you also get TK, which is substantially easier to use for certain problem sets, substantially smaller, and substantially more cross-platform (in that it will run on fringe or legacy platforms that are no longer or were never supported by GTK or QT).

                                All of these have well-maintained bindings to all popular scripting languages.

                                1. 1

                                  QT apps can look reasonably good. I think webapps can look better, but I haven’t done extensive QT customization.

                                  The bigger issue is 1) hiring - easier to get JS devs than QT devs 2) there’s little financial incentive to reduce memory usage. Using other people’s RAM is “free” for a company, so they do it. If their customers are in US/EU/Japan, they can expect reasonably new machines so they don’t see it as an issue. They aren’t chasing the market in Nigeria, however large in population.

                                  1. 5

                                    Webapps are sort of the equivalent of doing something in QT but using nothing but the canvas widget (except a little more awkward because you also don’t have pixel positioning). Whatever can be done in a webapp can be done in a UI toolkit, but the most extreme experimental stuff involves not using actual widgets (just like doing it as a webapp would).

                                    Using QT doesn’t prevent you from writing in javascript. Just use NPM QT bindings. It means not using the DOM, but that’s a net win: it is faster to learn how to do something with a UI toolkit than to figure out how to do it through DOM manipulation, unless the thing that you’re doing is (at a fundamental level) literally displaying HTML.

                                    I don’t think memory use is really going to be the main factor in convincing corporations to leave Electron. It’s not something that’s limited to the third world: most people in the first world (even folks who are in the top half of income) don’t have computers that can run Electron apps very well – but for a lot of folks, there’s the sense that computers just run slow & there’s nothing that can be done about it.

                                    Instead, I think the main thing that’ll drive corporations toward more sustainable solutions is maintenance costs. It’s one thing to hire cheap web developers & have them build something, but over time keeping a hairball running is simply more difficult than keeping something that’s more modular running – particularly as the behavior of browsers with respect to the corner cases that web apps depend upon to continue acting like apps is prone to sudden (and difficult to model) change. Building on the back of HTML rendering means a red queen’s race against 3 major browsers, all of whom are changing their behaviors ahead of standards bodies; on the other hand, building on a UI library means you can specify a particular version as a dependency & also expect reasonable backwards-compatibility and gradual deprecation.

                                    (But, I don’t actually have a lot of confidence that corporations will be convinced to do the thing that, in the long run, will save them money. They need to be seen to have saved money in the much shorter term, & saying that you need to rearchitect something so that it costs less in maintenance over the course of the next six years isn’t very convincing to non-technical folks – or to technical folks who haven’t had the experience of trying to change the behavior of a hairball written and designed by somebody who left the company years ago.)

                                  2. 1

                                    I understand that these tools are maintained in a certain sense. But from an outsider’s perspective, they are absolutely not appealing compared to what you see in their competitors.

                                    I want to be extremely nice, because I think that the work done on these teams and projects is very laudable. But compare the wxPython docs with the Bootstrap documentation. I also spent a lot of time trying to figure out how to use Tk, and almost all resources …. felt outdated and incompatible with whatever toolset I had available.

                                    I think Qt is really good at this stuff, though you do have to marry its toolset for a lot of it (perhaps this has gotten better).

                                    The elephant in the room is that no native UI toolset (save maybe Apple’s stack?) is nowhere near as good as the diversity of options and breadth of tooling available in DOM-based solutions. Chrome dev tools is amazing, and even simple stuff like CSS animations gives a lot of options that would be a pain in most UI toolkits. Out of the box it has so much functionality, even if you’re working purely vanilla/“no library”. Though on this points things might have changed, jQuery basically is the optimal low-level UI library and I haven’t encountered native stuff that gives me the same sort of productivity.

                                    1. 3

                                      I dunno. How much of that is just familiarity? I find the bootstrap documentation so incomprehensible that I roll my own DOM manipulations rather than using it.

                                      TK is easy to use, but the documentation is tcl-centric and pretty unclear. QT is a bad example because it’s quite heavy-weight and slow (and you generally have to use QT’s versions of built-in types and do all sorts of similar stuff). I’m not trying to claim that existing cross-platform UI toolkits are great: I actually have a lot of complaints with all of them; it’s just that, in terms of ease of use, peformance, and consistency of behavior, they’re all far ahead of web tech.

                                      When it comes down to it, web tech means simulating a UI toolkit inside a complicated document rendering system inside a UI toolkit, with no pass-throughs, and even web tech toolkits intended for making UIs are really about manipulating markup and not actually oriented around placing widgets or orienting shapes in 2d space. Because determining how a piece of markup will look when rendered is complex and subject to a lot of variables not under the programmer’s control, any markup-manipulation-oriented system will make creating UIs intractably awkward and fragile – and while Google & others have thrown a great deal of code and effort at this problem (by exhaustively checking for corner cases, performing polyfills, and so on) and hidden most of that code from developers (who would have had to do all of that themselves ten years ago), it’s a battle that can’t be won.

                                      1. 5

                                        It annoys me greatly because it feels like nobody really cares about the conceptual damage incurred by simulating a UI toolkit inside a doument renderer inside a UI toolkit, instead preferring to chant “open web!” And then this broken conceptual basis propagates to other mediums (VR) simply because it’s familiar. I’d also argue the web as a medium is primarily intended for commerce and consumption, rather than creation.

                                        It feels like people care less about the intrinsic quality of what they’re doing and more about following whatever fad is around, especially if it involves tools pushed by megacorporations.

                                        1. 2

                                          Everything (down to the transistor level) is layers of crap hiding other layers of different crap, but web tech is up there with autotools in terms of having abstraction layers that are full of important holes that developers must be mindful of – to the point that, in my mind, rolling your own thing is almost always less work than learning and using the ‘correct’ tool.

                                          If consumer-grade CPUs were still doubling their clock speeds and cache sizes every 18 months at a stable price point and these toolkits properly hid the markup then it’d be a matter of whether or not you consider waste to be wrong on principle or if you’re balancing it with other domains, but neither of those things are true & so choosing web tech means you lose across the board in the short term and lose big across the board in the long term.

                      2. 1

                        Youtube would be a website where you click on a video and it plays. But it wouldn’t have ads and comments and thumbs up and share buttons and view counts and subscription buttons and notification buttons and autoplay and add-to-playlist.

                        Google docs would be a desktop program.

                        Slack would be IRC.

                        1. 1

                          What you’re describing is the video HTML5 tag, not a video sharing platform. Minimalism is good, I do agree, but don’t mix it with no features at all.

                          Google docs would be a desktop program.

                          This is another debate around why using the web for these kind of tasks, not the fact that it’s minimalist or not.

                    1. 9

                      Interesting observation from reddit

                      Some Rust practitioners are weird.

                      You have all those great approaches about correctness, and then you see here and there developers trying random explicitly unsafe hacks depending on internals of data types, that not even C++ developers would try.

                      I mean, when was the last time when you randomly tried to nuke the internal length of an C++ std::vector to speed things up, using simultaneously dangerous means and a complex reasoning (but probably undocumented, and maybe incorrect) justifying that there actually was no risk in your opinion?

                      And on top of that do it in, not in some kind of insane computation kernel trying to grab the last bit of perf, but in merely an HTTP library?

                      Well at least I’m happy this particular missed optim has been fixed. One less reason to resort to insane unsafe hacks.

                      (On a sidenote, it is sometimes better to only modify a variable in memory if it doesn’t already has the good value, but this would be mostly for scaling concurrent accesses of the same cacheline on multiple CPU, so this does not really apply here – and also sometimes compilers fuck you up by using a cmov but then it is a completely different story :p )

                      1. 10

                        that not even C++ developers would try.

                        I disagree with this. If anything, I suspect this idea has come from C++, where std::vector’s API contains functions to explicitly reduce the length without shrinking the capacity. This is partly to avoid invalidating iterators, but is also used to e.g. avoid unnecessary allocations when emptying a vector and immediately refilling it with a simply quantity of elements.

                      1. 28

                        By May 25, most corporates had just amended their Privacy Policy volumes and annoyed consumers were forced to clicked through to accept them without reading.

                        I don’t know why people find this so hard to understand, but the entire point of the GDPR is that you cannot comply with it simply by adding more terms to your Terms of Service for people to sign away their rights without reading. That’s not how it works.

                        In my opinion preoccupation with the nominal personal data, actually displaces real privacy. Who cares about privacy of their name and family name, or office held? Except to hide shady politicking and worse, majority of us are happy to consciously publicize it as much as possible. It’s wrong, impractical and disrespectful to assume the contrary.

                        There are dozens of situations when it’s actually socially undesirable to keep it private, yet it is zealously protected under the GDPR in exactly the same way as your shopping history or your family photos.

                        I do care about the privacy of my name and family name. Is my name public on the internet? Yes. If I wanted to make it not public, would I want to be able to do so? Yes. Simple as that, really.

                        Equally questionable are formal and bureaucratic prescriptions for better data protection — more documentation, privacy impact audits, formal training, etc.

                        Does anyone honestly believe that more paperwork will lead to more privacy? More security risks in handling of our data (say thousands of hand signed consents) are somewhat more likely, I’m afraid.

                        Why would formal training around data protection, auditing of privacy protection and documentation of efforts to comply with the GDPR lead to another other than more privacy?

                        Apart from the right to complain under the new rules and few marginal rights — which are primarily of interest to the corrupt and the criminal, like the right to be forgotten — the average data subject barely gained any new privacy through the GDPR.

                        Yeah okay, nothing interesting to read here. The right to be forgotten is certainly not ‘primarily of interest to the corrupt and the criminal’. What a great load of ‘if you have nothing to fear you have nothing to hide’ twaddle.

                        1. 2

                          By May 25, most corporates had just amended their Privacy Policy volumes and annoyed consumers were forced to clicked through to accept them without reading.

                          I don’t know why people find this so hard to understand, but the entire point of the GDPR is that you cannot comply with it simply by adding more terms to your Terms of Service for people to sign away their rights without reading. That’s not how it works.

                          Excuse me if I misunderstand, but isn’t it still the case that they can add terms to their privacy policy, then tell users to either check all the boxes or leave?

                          1. 15

                            That’s exactly what you can’t do — you can’t refuse service if a user says “no” to tracking (unless you can prove in court that the tracking is strictly required for the functioning of the service).

                            1. 2

                              An example of a site that doesn’t follow the rules you state at all:

                              If you do not agree with our new privacy policy (that haven’t really changed much) we absolutely respect that. Feel free to go to your user settings page and delete your account. Optionally, you can change your settings and/or user profile if that helps. If you miss any settings feel free to let us know. If you just miss-clicked you can always go back and agree to the policy. If you have more questions feel free to send an e-mail to support@{{domainName}} and we will do our very best help you out.

                              They’re relatively small though, so I hope they’re not representative of too many other companies.

                              1. 3

                                Then their privacy policy is invalid, and they’re committing a crime with every bit of data they collect.

                                To be allowed to collect userdata, you need consent, and under the GDPR consent is only valid if it has been given freely, without any advantage/disadvantage coming from giving/not giving consent. (except for functionality that directly requires the consent).

                              2. 1

                                Oh. I guess I’ve been doing privacy policy change dialogs wrong then 😅 I could’ve sworn lots of them wouldn’t let you continue until you accepted though.

                            2. 1

                              I don’t know why people find this so hard to understand, but the entire point of the GDPR is that you cannot comply with it simply by adding more terms to your Terms of Service for people to sign away their rights without reading. That’s not how it works.

                              Have the various aspects of GDPR been applied/tested in court yet?

                              1. 7

                                European civil law originals from Roman civil law, and is quite different from common law systems that originate from British law. Generally the law is quite specific and the intent is that the law will be applied as written rather than interpreted in the social and political context of the day in light of precedent, as is done in common law systems.

                                I don’t know if that’s the case with the GDPR to the extent that it’s true of say, German law or French law, but if it is, it doesn’t need to be ‘tested’ in court, it is what it is.

                                1. 1

                                  There are a few things which GDPR leaves open to interpretation, such as:

                                  • Maximum fines are specified, but we have yet to see what fines will be handed out for different levels of non-compliance.
                                  • How far the “legitimate interest” can be stretched.
                            1. 18

                              Didn’t systemd hard code 8.8.8.8 as well at some point?

                              It’s such a good thing that people are watching out for violations in free software.

                              1. 19

                                They use it as the default for the fallback if no DNS is configured. https://github.com/systemd/systemd/blob/master/meson_options.txt#L200

                                1. 2

                                  Which is quite reasonable.

                                  1. 9

                                    That depends on your individual situation. Some users might appreciate that the system ‘just works’ even if not configured properly. Other wouldn’t, for 2 reasons:

                                    1. Sending data a third party, especially one like google, without telling the user, is not ok in terms of privacy.
                                    2. If something is misconfigured but silently falls back to a default which appears to work (while actually behaving in a different manner to how the user intended), then it’s much more difficult for the user to know that it needs fixing, and often much more difficult for the user to fix.
                                2. 7

                                  2 people marked this as incorrect but the source code proving it is linked right there!

                                  1. 5

                                    You cannot imagine how many people mark comments they do not like as incorrect without even checking the sources, commenting or noticing that they are opinions!

                                    You shouldn’t care much: other might learn something from your comment anyway. At least an incorrect downvote make you double check the sources!

                                    1. 3

                                      Is it hard coded or is it a fallback default?

                                  1. 4
                                    1. Bring them in for a few days, see if they can set up the dev environment, assign them some bugs nobody else wants to fix, have them meet everyone.
                                    2. Pay them.
                                    3. Decide if you want to keep paying them.

                                    This is, of course, the obvious way to select people for any field, not just programming. The problem is that if you won’t do 6 then few candidates will want to do 5 (they can’t leave their job to come in for a few days) and companies seem allergic to 7 (which is essential for 6).

                                    1. 1

                                      In the UK, it’s pretty common for new employees to start with a period of ‘probation’ (typically a few months, though it can vary), during which the notice period is much shorter (e.g. a week’s notice, for both sides), so there’s less commitment until the employer and employee are satisfied that they’re a good match. I suspect some companies don’t take full advantage of probation (i.e. they think of it as a backup in case they make a hiring mistake, rather than an opportunity to try someone they’re not sure about after interview), but some do.

                                    1. 24

                                      As I read this I thought about my experiences with Diaspora and Mastodon. Pages like this one or this one (click “Get Started”, I couldn’t do a deep link because JavaScript) are, IMHO, a big part of the reason these services don’t take off. How can an average user be expected to choose from a basically random list of nodes? How can I, a reasonably “technical” person, even be expected to do so?

                                      So then why not host my own node? First, I don’t have time and most people I know don’t either. If I was 15 again I totally would because I had nothing better to do. I also don’t want to play tech support for a good chunk of my social network, and providing a service to someone has a tendency to make them view you as the tech support.

                                      Second, if I do that I’m now in charge of security for my data. As terrible as Twitter and Facebook are, they’re probably still a lot better at securing my data than I am (at the very least they probably patch their systems more often than I would). Even worse, if some non-technical person decides to bite the bullet and create a node for his/her friends, how secure do you think that’s going to be?

                                      Further, what are the odds that I, or whoever is maintaining the node, basically gets bored of it one day and kills the whole thing? Pretty damn high (maybe I and all my friends are assholes, though, so whatever).

                                      Anyway, this post really spoke to me because I’ve been trying to escape Evil companies for awhile now and “federated” just doesn’t seem to be the answer. I now believe that centralized is here to stay, but that we should start looking at the organizations that control the data instead of the technology. For example, if Facebook were an open non-profit with a charter that legally prevented certain kinds of data “sharing” and “harvesting” maybe I wouldn’t have any problem with it.

                                      1. 18

                                        How can an average user be expected to choose from a basically random list of nodes?

                                        How did they choose their email provider? Not be carefully weighing the technical options, surely. They chose whatever their friends or parents used, because with working federation it doesn’t matter.

                                        what are the odds that I, or whoever is maintaining the node, basically gets bored of it one day and kills the whole thing?

                                        Same as what happened with many early email providers: when they died, people switched to different ones and told their friends their new addresses.

                                        Really, all this argument of “what if federation isn’t a holy grail” is pointless because we all already use a federated system — email — and we know for a fact that it works for humans, despite all its flaws.

                                        1. 8

                                          How did they choose their email provider? Not be carefully weighing the technical options, surely. They chose whatever their friends or parents used, because with working federation it doesn’t matter.

                                          In contrast to mastodon instances - which are very alike - email providers have differentiated on the interface and guarantees they provide and market that. People react to that.

                                          1. 2

                                            In contrast to mastodon instances

                                            While this was largely true in the beginning, many Fediverse nodes now do market themselves based on default interface, additional features (e.g. running the GlitchSoc fork or something like it), or even using non-Mastodon software like Pleroma. I suspect this will only increase as additional implementations (Rustodon) and forks (#ForkTogether) take off and proliferate.

                                          2. 8

                                            How did they choose their email provider?

                                            I think federated apps like Mastodon are fundamentally different than email providers. Most email providers are sustainable businesses, they earn money with adds or paid plans or whatever and have their own emails servers and clients with specific features. Self-hosted email servers are a minority. Please tell if I wrong, but I don’t think one can easily earn money with a Mastodon instance.

                                            However I agree that both are federated.

                                            1. 1

                                              i don’t know if any nodes do this but you could charge for mastodon hosting

                                            2. 6

                                              You’re certainly not wrong, though I would argue that email, particularly as it was 20+ years ago when it went “mainstream”, is much simpler (for instance, it doesn’t require any long-term persistence or complicated access control) and therefore easier to federate successfully (in a way that humans can handle) than social networking.

                                              1. 1

                                                AP style social network federation also doesn’t require long-term persistence or complicated access control.

                                                1. 1

                                                  email is social networking. are there particular social networking features you had in mind?

                                                  1. 3

                                                    Yeah, I listed them in my comment… “long-term persistence or complicated access control”. Admittedly I didn’t go into much detail. Email is a very simple social network, there isn’t much “meat” to it, particularly as it existed when it became popular.

                                                    1. 1

                                                      email has very long term persistence, much longer than something like facebook because it’s much easier to make backups of your emails than to make backups of your facebook interactions.

                                                      i guess i don’t know what you mean by “complicated access control.”

                                                      1. 1

                                                        Email is basically fire and forget. You download it to your computer and then you’ve got it forever (modern email does more, but also includes more of the privacy / data issues that come with other social networks). But most users can’t easily give other people on-demand access to their emails, which is the case with Facebook, Twitter, etc. Email is really meant for private communication (possibly with a large group, but still private), Facebook and company are for private, semi-private, and even public communication, and they require a user to be able to easily retroactively grant or retract permissions. Email doesn’t handle these other use-cases (this isn’t a fault of email, it doesn’t try to).

                                                    2. 2

                                                      The ability for interested parties to interact without reply all. I can post a picture of a beautiful burrito, and people can comment or ignore at their leisure, and then reply to each other. I guess there’s some preposterous email solution where I mail out a link to an ad hoc mailing list with every update and various parties subscribe, but… meh.

                                                      1. 2

                                                        something that handles a feature like that need not be email per se, but it could have a very similar design, or be built on top of email. something like what you suggested wouldn’t seem preposterous if the clients were set up to facilitate that kind of use.

                                                  2. 3

                                                    In the case of Mastodon, which instance you pick does matter. Users can make posts that are only visible to others in the same instance. If you pick the “wrong” home instance, you’ll have to make another account in another instance to see the instance-private posts there. If you’re a new Mastodon user, you might not know that one instance is good for artists and another good for musicians, etc. In any case, this is as easily solvable problem by adding descriptions and user-provided reviews to each instance.

                                                  3. 2

                                                    These ‘which instance to join’ sites are completely useless, I wish they wouldn’t exist at all.

                                                    1. 1

                                                      Second, if I do that I’m now in charge of security for my data. As terrible as Twitter and Facebook are, they’re probably still a lot better at securing my data than I am

                                                      Setting a price tag on your datas doesn’t secure them. There are enough scams and hoaxes on Facebook to share your information with other companies that I have to disagree with you. And since those social networks are collecing more data than necessary, it is easier to lose data.

                                                      1. 2

                                                        Facebook and Twitter also present single valuable targets and are thus more likely to be targeted. A hundred mastodon instances may be individually less secure due to the operators having fewer resources or less experience, but compromising a single server won’t get you as much.

                                                        1. 2

                                                          That’s a good point, although Wordpress vulnerabilities are still a big deal even though there are tons of small servers. The server might not be a monolith, but if the software is then it’s only slightly more work to attack N instances.

                                                          1. 1

                                                            True, although it depends whether the vulnerabilities are in the application being served or in the web server or OS serving it.

                                                    1. 7

                                                      Interesting analysis!

                                                      Does the Github search API take forks into account? Assuming it doesn’t, this would skew the results towards popular packages with lots of forks. Whether this detracts from your conclusions is debatable. You could argue that a newcomer is more likely to look at popular packages.

                                                      1. 6

                                                        OK but the tag line is asinine. As a regular user of a Linux distribution it is actually impossible for me to take the time to do a full analysis on every package I install to get work done.

                                                        SOME level of trust has to be there or else the whole idea of a Linux distro can’t work.

                                                        1. 10

                                                          Well, AUR specifically isn’t part of the actual Arch distro. It’s no safer than the curl | bash invocations on github.

                                                          1. 4

                                                            But it makes your wonder if there is no middle-ground between the AUR and the community repository. Have a Git{Hub,Lab,ea} repository where the community can do pull requests for new packages and updates, but the pull requests are reviewed by trusted users or developers. And then build the packages on trusted infrastructure.

                                                            1. 9

                                                              This is how the OpenBSD ports tree works. Anyone can send a new port or an update to the ports@ mailing list. It then gets tested & committed by developers.

                                                              In this specific instance, I think what hurt Arch here is too good tooling. The community developed a lot of automation tools that boil down third party package installs to pressing enter a bunch of times - even with all the warnings present people stopped reviewing the packages. If I recall correctly, the main point of AUR was to gather community packages then promote the popular ones (by votes) to trusted repositories - essentially the promotion to trusted repos lost meaning as everyone can install yaourt/pacaur or $pkgmgr du jour and just go on with their life.

                                                            2. 2

                                                              It’s no safer than the curl | bash invocations on github.

                                                              Highly disagree. Using the AUR without any supporting tools like pacaur, you’re cloning into a git repository to retrieve the PKGBUILD and supporting files, so you have the opportunity to view them. With pacaur, you’re shown the PKGBUILD at first install so you can make sure nothing’s malicious, and then you’re shown diffs when the package version updates. That’s MUCH better than curl | bash already.

                                                              1. 1

                                                                Also, while you shouldn’t rely on others to spot malicious code, the fact that the malicious modifications were spotted and reverted after about 9 hours shows that the AUR is subject to at least slightly more scrutiny than random scripts from github or elsewhere are.

                                                                Admittedly, it doesn’t sound like this particular attack was very sophisticated or well hidden.

                                                          1. 3

                                                            It’s always a compromise. For a single function, a touchscreen is never as good as a dedicated hardware control. The touchscreen’s advantage is in its ability to represent different controls at different times. A lot of modern high tech devices combine physical controls with touchscreens in an attempt to balance functionality (doing one thing well) with flexibility (doing different things at different times). At one end of the scale, you have smartphones, where the need for versatility makes for heavy use of a touchscreen with only a few dedicated switches (volume, power, maybe camera). At the other end of the scale, in something like a car, functionality trumps flexibility, meaning at least the most important controls should have dedicated hardware.

                                                            In a slight reversal from a few years ago, when touchscreens were limited to high-end products, touchscreens can now be used to cut costs, either by replacing more costly dedicated controls, or by allowing a basic touchscreen terminal to be mass-produced then adapted for different products by running different software.

                                                            1. 5

                                                              It’s not so well known outside the francophone world, but French non-profit organisation framasoft host a wide range of free (libre) alternatives to various online services. They have an ongoing campaign to de-google-ify the internet: https://degooglisons-internet.org/.

                                                              1. 3

                                                                Another French service I happen to know: TeDomum

                                                              1. 0

                                                                Have you ever needed to publish an article in twitter?

                                                                1. 11

                                                                  Publishing on Twitter is great. You’re forced to make every 280 character tweet stand on its own and support your overall point. You have to be concise, organized, and direct. And everyone engaging is also forced to be concise. It’s a great medium.

                                                                  I don’t think this article worked out as a tweetstorm, but a lot of ideas do really well in that format.

                                                                  1. 2

                                                                    If you find that imposing a 280-character limit on your paragraphs improves your writing, then impose such a limit on yourself while writing. However, I don’t see any benefit to actually using twitter to deliver the content. Indeed, this article is interrupted part way through by a discussion of the limitations of twitter:

                                                                    Sadly, this one is too long for a tweet…

                                                                    As with any rule guiding writing style, it should be possible to break the rule occasionally.

                                                                    Personally, I do find that this article is rather disjointed in places, with sentences that should follow on from the previous sentence separated into their own paragraph instead.

                                                                    (There is also the risk that any discussion about the article gets distracted by people like us arguing about whether twitter is a good blogging platform instead of discussing the content.)

                                                                    1. 2

                                                                      If you know how to organise your thoughts and write well, you will do so.

                                                                      If you don’t, then you will instead just spew out useless deluge of words over multiple tweets.

                                                                      If you put garbage in a box and read it 280 chars at a time, you will still be reading garbage.

                                                                      1. 6

                                                                        Given I’ve never seen you write a technical article, post someone else’s technical article, or comment on the technical aspects of someone else’s submission, I’m going to guess you have no interest or experience in technical writing. Once you’ve done some of that you’ll see why twitter is such a good medium.

                                                                        I used to think the same way you did about this, until I began writing myself.

                                                                        1. 2

                                                                          This is appeal to authority.

                                                                          If your experience in technical writing shows you why what you used to think and what I now think is wrong, then why don’t you use your experience in said technical writing to write an explanation of why I am wrong instead of using secondary heuristics to explain why I must be wrong.

                                                                          Once you’ve done some of that you’ll see why twitter is such a good medium.

                                                                          Whenever I wanted to learn something technical, I look for an online article or a tutorial, or if more indepth, a text-book.

                                                                          Should I instead start searching on twitter for a tweet chain?

                                                                  1. 6

                                                                    I find that the combination of points 2 (evolving) & 3 (old enough to have established body of literature) is actually rather a bad thing, as there is an enormous amount of outdated literature. Some of it will teach you to write old-school code that will not be welcome in a modern C++ codebase. The rest of it will devote 80% to writing elaborate constructs to implement features which are now part of the language.

                                                                    1. 3

                                                                      I found that, too. It was especially jarring since part of point 2 is that different C++ versions can behave differently with the same code – even if that situation is rare, that knowledge makes any legacy documentation suspect.

                                                                    1. 3

                                                                      One problem with std::optional, at least at the moment, while it’s relatively new, is that std is opinionated, so you often won’t find library functions that work with a std::optional-based codebase.

                                                                      For example, parsing an integer from a string is a classic example of a function which might not succeed. So it would make sense to use std::optional to store the result. However, the standard library provides int stoi(const std::string& str, std::size_t* pos = 0, int base = 10) and friends, which signal failure by throwing exceptions.

                                                                      So, in theory, std::optional provides an alternative way to handle failure, somewhat like some haskell or rust code might, making the possibility of failure explicit in the type, and thus forcing you to explicitly handle it or pass it on. However, (unless a library exists which I’m not aware of?) you may need to reimplement large parts of the standard library to make them fit.

                                                                      1. 3

                                                                        Right. “This is a feature of the standard library!” means something entirely different in C++ than in other programming languages.

                                                                        1. 2

                                                                          Can you make it much less of a headache by defining a generic function that takes a lambda, calls it in a try/catch, returns the successful value from the try branch, returns nullopt from the catch?

                                                                          1. 1

                                                                            There are any number of workarounds, that obfuscate the code to varying degrees. This same situation arose with Optional in java 8, it’s there, but not really, so a lot of places you’d like to use it you have to go through similar contortions. The other problem is if interacting with different teams writing different parts of the app; everyone has to be on the same page or you’ll end up wrapping/unwrapping optional all over. And libraries. In the end I found optionals were a lot of trouble for very little gain.

                                                                            1. 1

                                                                              I did wonder about that. However, blindly catching all different exceptions and effectively discarding the information about which exception it was seems unwise. Of course you could keep the information while still using sum types, but then you don’t really want std::optional, you want an either type which can hold either a valid value or an error code. I’m not sure whether the standard library has one of these or whether you’d have to roll your own.

                                                                              1. 1

                                                                                blindly catching all different exceptions and effectively discarding the information about which exception it was seems unwise

                                                                                Sure, I wouldn’t be very happy with a blind try/catch around something like a database access or RPC call. Just if the thing you’re wrapping is something really boring like (say) parsing a string into an integer, the exception if it goes wrong isn’t going to be very interesting anyway.

                                                                          1. 2

                                                                            I wonder how this can get out of its current catch 22 situation where the main thing that makes it interesting is the easy access to a wide range of packages in a central repository, but having a wide range of packages available depends on having a wide range of people interested.

                                                                            At the moment, their crates.io equivalent, cppget.org, has only 24 packages (mostly build2 itself and a few example packages), and it’s not clear if there’s any infrastructure for users to submit their own packages. They also face the additional issue that unlike cargo, build2 has come much later in the life of C++, so it probably needs a strategy to make existing, widely used, libraries available in the repository.

                                                                            Yes, it can be used with a local repository, but at least for open source dependencies, the nice thing about cargo is that you tell it you want to depend on foo >= 1.0 and it does everything else for you. This experience is also very important for people who just want to try it out for the first time.

                                                                            1. 12

                                                                              Output should be simple to parse and compose

                                                                              No JSON, please.

                                                                              Yes, every tool should have a custom format that needs a badly cobbled together parser (in awk or whatever) that will break once the format is changed slighly or the output accidentally contains a space. No, jq doesn’t exist, can’t be fitted into Unix pipelines and we will be stuck with sed and awk until the end of times, occasionally trying to solve the worst failures with find -print0 and xargs -0.

                                                                              1. 11

                                                                                JSON replaces these problems with different ones. Different tools will use different constructs inside JSON (named lists, unnamed ones, different layouts and nesting strategies).

                                                                                In a JSON shell tool world you will have to spend time parsing and re-arranging JSON data between tools; as well as constructing it manually as inputs. I think that would end up being just as hacky as the horrid stuff we do today (let’s not mention IFS and quoting abuse :D).


                                                                                Sidestory: several months back I had a co-worker who wanted me to make some code that parsed his data stream and did something with it (I think it was plotting related IIRC).

                                                                                Me: “Could I have these numbers in one-record-per-row plaintext format please?”

                                                                                Co: “Can I send them to you in JSON instead?”

                                                                                Me: “Sure. What will be the format inside the JSON?”

                                                                                Co: “…. it’ll just be JSON.”

                                                                                Me: “But it what form? Will there be a list? Name of the elements inside it?”

                                                                                Co: “…”

                                                                                Me: “Can you write me an example JSON message and send it to me, that might be easier.”

                                                                                Co: “Why do you need that, it’ll be in JSON?”

                                                                                Grrr :P


                                                                                Anyway, JSON is a format, but you still need a format inside this format. Element names, overall structures. Using JSON does not make every tool use the same format, that’s strictly impossible. One tool’s stage1.input-file is different to another tool’s output-file.[5].filename; especially if those tools are for different tasks.

                                                                                1. 3

                                                                                  I think that would end up being just as hacky as the horrid stuff we do today (let’s not mention IFS and quoting abuse :D).

                                                                                  Except that standardized, popular formats like JSON get the side effect of tool ecosystems to solve most problems they can bring. Autogenerators, transformers, and so on come with this if it’s a data format. We usually don’t get this if it’s random people creating formats for their own use. We have to fully customize the part handling the format rather than adapt an existing one.

                                                                                  1. 2

                                                                                    Still, even XML that had the best tooling I have used so far for a general purpose format (XSLT and XSD in primis), was unable to handle partial results.

                                                                                    The issue is probably due to their history, as a representation of a complete document / data structure.

                                                                                    Even s-expressions (the simplest format of the family) have the same issue.

                                                                                    Now we should also note that pipelines can be created on the fly, even from binary data manipulations. So a single dictated format would probably pose too restrictions, if you want the system to actually enforce and validate it.

                                                                                    1. 2

                                                                                      “Still, even XML”

                                                                                      XML and its ecosystem were extremely complex. I used s-expressions with partial results in the past. You just have to structure the data to make it easy to get a piece at a time. I can’t recall the details right now. Another I used trying to balance efficiency, flexibility, and complexity was XDR. Too bad it didn’t get more attention.

                                                                                      “So a single dictated format would probably pose too restrictions, if you want the system to actually enforce and validate it.”

                                                                                      The L4 family usually handles that by standardizing on an interface, description language with all of it auto-generated. Works well enough for them. Camkes is an example.

                                                                                      1. 3

                                                                                        XML and its ecosystem were extremely complex.

                                                                                        It is coherent, powerful and flexible.

                                                                                        One might argue that it’s too flexible or too powerful, so that you can solve any of the problems it solves with simpler custom languages. And I would agree to a large extent.

                                                                                        But, for example, XHTML was a perfect use case. Indeed to do what I did back then with XLST now people use Javascript, which is less coherent and way more powerful, and in no way simpler.

                                                                                        The L4 family usually handles that by standardizing on an interface, description language with all of it auto-generated.

                                                                                        Yes but they generate OS modules that are composed at build time.

                                                                                        Pipelines are integrated on the fly.

                                                                                        I really like strongly typed and standard formats but the tradeoff here is about composability.

                                                                                        UNIX turned every communication into byte streams.

                                                                                        Bytes byte at times, but they are standard, after all! Their interpretation is not, but that’s what provides the flexibility.

                                                                                        1. 4

                                                                                          Indeed to do what I did back then with XLST now people use Javascript, which is less coherent and way more powerful, and in no way simpler.

                                                                                          While I am definitely not a proponent of JavaScript, computations in XSLT are incredibly verbose and convoluted, mainly because XSLT for some reason needs to be XML and XML is just a poor syntax for actual programming.

                                                                                          That and the fact that while my transformations worked fine with xsltproc but did just nothing in browsers without any decent way to debug the problem made me put away XSLT as an esolang — lot of fun for an afternoon, not what I would use to actually get things done.

                                                                                          That said, I’d take XML output from Unix tools and some kind of jq-like processor any day over manually parsing text out of byte streams.

                                                                                          1. 2

                                                                                            I loved it when I did HTML wanting something more flexible that machines could handle. XHTML was my use case as well. Once I was a better programmer, I realized it was probably an overkill standard that could’ve been something simpler with a series of tools each doing their little job. Maybe even different formats for different kinds of things. W3C ended up creating a bunch of those anyway.

                                                                                            “Pipelines are integrated on the fly.”

                                                                                            Maybe put it in the OS like a JIT. Far as bytestreams, that mostly what XDR did. They were just minimally-structured, byte streams. Just tie the data types, layouts, and so on to whatever language the OS or platform uses the most.

                                                                                    2. 3

                                                                                      JSON replaces these problems with different ones. Different tools will use different constructs inside JSON (named lists, unnamed ones, different layouts and nesting strategies).

                                                                                      This is true, but but it does not mean heaving some kind of common interchange format does not improve things. So yes, it does not tell you what the data will contain (but “custom text format, possibly tab separated” is, again, not better). I know the problem, since I often work with JSON that contains or misses things. But the problem is not to not use JSON but rather have specifications. JSON has a number of possible schema formats which puts it at a big advantage of most custom formats.

                                                                                      The other alternative is of course something like ProtoBuf, because it forces the use of proto files, which is at least some kind of specification. That throws away the human readability, which I didn’t want to suggest to a Unix crowd.

                                                                                      Thinking about it, an established binary interchange format with schemas and a transport is in some ways reminiscent of COM & CORBA in the nineties.

                                                                                    3. 7

                                                                                      will break once the format is changed slighly

                                                                                      Doesn’t this happens with json too?
                                                                                      A slight change in the key names or turning a string to a listof strings and the recipient won’t be able to handle the input anyway.

                                                                                      the output accidentally contains a space.

                                                                                      Or the output accidentally contact a comma: depending on the parser, the behaviour will change.

                                                                                      No, jq doesn’t exis…

                                                                                      Jq is great, but I would not say JSON should be the default output when you want composable programs.

                                                                                      For example JSON root is always a whole object and this won’t work for streams that get produced slowly.

                                                                                      1. 5

                                                                                        will break once the format is changed slighly

                                                                                        Doesn’t this happens with json too?

                                                                                        Using a whitespace separated table such as suggested in the article is somewhat vulnerable to continuing to appear to work after the format has changed while actually misinterpreting the data (e.g. if you inserted a new column at the beginning, your pipeline could happily continue, since all it needs is at least two columns with numbers in). Json is more likely to either continue working correctly and ignore the new column or fail with an error. Arguably it is the key-value aspect that’s helpful here, not specifically json. As you point out, there are other issues with using json in a pipeline.

                                                                                      2. 3

                                                                                        On the other hand, most Unix tools use tabular format or key value format. I do agree though that the lack of guidelines makes it annoying to compose.

                                                                                        1. 2

                                                                                          Hands up everybody that has to write parsers for zpool status and its load-bearing whitespaces to do ZFS health monitoring.

                                                                                          1. 2

                                                                                            In my day-to-day work, there are times when I wish some tools would produce JSON and other times when I wish a JSON output was just textual (as recommended in the article). Ideally, tools should be able to produce different kinds of outputs, and I find libxo (mentioned by @apy) very interesting.

                                                                                            1. 2

                                                                                              I spent very little time thinking about this after reading your comment and wonder how, for example, the core utils would look like if they accepted/returned JSON as well as plain text.

                                                                                              A priori we have this awful problem of making everyone understand every one else’s input and output schemas, but that might not be necessary. For any tool that expects a file as input, we make it accept any JSON object that contains the key-value pair "file": "something". For tools that expect multiple files, have them take an array of such objects. Tools that return files, like ls for example, can then return whatever they want in their JSON objects, as long as those objects contain "file": "something". Then we should get to keep chaining pipes of stuff together without having to write ungodly amounts jq between them.

                                                                                              I have no idea how much people have tried doing this or anything similar. Is there prior art?

                                                                                              1. 9

                                                                                                In FreeBSD we have libxo which a lot of the CLI programs are getting support for. This lets the program print its output and it can be translated to JSON, HTML, or other output forms automatically. So that would allow people to experiment with various formats (although it doesn’t handle reading in the output).

                                                                                                But as @Shamar points out, one problem with JSON is that you need to parse the whole thing before you can do much with it. One can hack around it but then they are kind of abusing JSON.

                                                                                                1. 2

                                                                                                  That looks like a fantastic tool, thanks for writing about it. Is there a concerted effort in FreeBSD (or other communities) to use libxo more?

                                                                                                  1. 1

                                                                                                    FreeBSD definitely has a concerted effort to use it, I’m not sure about elsewhere. For a simple example, you can check out wc:

                                                                                                    apy@bsdell ~> wc -l --libxo=dtrt dmesg.log
                                                                                                         238 dmesg.log
                                                                                                    apy@bsdell ~> wc -l --libxo=json dmesg.log
                                                                                                    {"wc": {"file": [{"lines":238,"filename":"dmesg.log"}]}
                                                                                                    }
                                                                                                    
                                                                                              2. 1

                                                                                                powershell uses objects for its pipelines, i think it even runs on linux nowaday.

                                                                                                i like json, but for shell pipelining it’s not ideal:

                                                                                                • the unstructured nature of the classic output is a core feature. you can easily mangle it in ways the programs author never assumed, and that makes it powerful.

                                                                                                • with line based records you can parse incomplete (as in the process is not finished) data more easily. you just have to split after a newline. with json, technically you can’t begin using the data until a (sub)object is completely parsed. using half-parsed objects seems not so wise.

                                                                                                • if you output json, you probably have to keep the structure of the object tree which you generated in memory, like “currently i’m in a list in an object in a list”. thats not ideal sometimes (one doesn’t have to use real serialization all the time, but it’s nicer than to just print the correct tokens at the right places).

                                                                                                • json is “java script object notation”. not everything is ideally represented as an object. thats why relational databases are still in use.

                                                                                                edit: be nicer ;)