Threads for mbrock

    1. 5

      A Common Lisp implementation with a runtime supporting green threads (think Erlang or Go). I never figured out how to finish because I never really started, and I get headaches thinking about bootstrapping or the future GC. One day maybe.

      1. 4

        I started something you might find somehow interesting, a Common Lisp-ish language implementation with delimited continuations, written in Zig to run in WebAssembly, with also a prototype structural editor… It integrates with JS promises via continuations. It’s very inefficient and incomplete but one of my favorite projects ever. It has a GC but nowadays you’d want to use native Wasm GC like Guile Scheme does.

        https://github.com/mbrock/wisp

        1. 1

          You could always build it on top of Go, or Erlang. There’s been a few lisps on Go, but I’ve always wanted to see something like linj, in Go.

          1. 1
            1. 1

              Infortunately it shares the same issues as Erlang (the disastrous tooling), and is even more niche.

          2. 3

            I think that always strikes me as interesting when I see comptime is how the uses feel exactly like Lisp macros. Like all the enum generation, type generation, etc? Yeah, I’d use macros for that. Obviously, I am not getting static types in doing so, but you get the point. The fact that comptime uses a subset of Zig to work? That’s just macros. Macros. Macros. Macros. It’s so good to see it. :)

            1. 4

              Yeah! There is a significant difference, because Zig comptime functions are not working with ASTs in the way Lisp macros do, although the type generation is a little bit like that. You can think about comptime functions in the same way as ordinary runtime functions, semantically. They don’t have access to inspect their arguments as expressions, they can’t cause an argument with side effects to be evaluated twice, etc. So they are limited compared to Lisp macros, but they also don’t introduce funky new semantics that make the language harder to reason about at a glance.

            2. 7

              How will you ensure that you can still build zig from sources in the future?

              1. 27

                By forever maintaining two implementations of the compiler - one in C, one in Zig. This way you will always be able to bootstrap from source in three steps:

                1. Use system C compiler to build C implementation from source. We call this stage1. stage1 is only capable of outputting C code.
                2. Use stage1 to build the Zig implementation to .c code. Use system C compiler to build from this .c code. We call this stage2.
                3. Use stage2 to build the Zig implementation again. The output is our final zig binary to ship to the user. At this point, if you build the Zig implementation again, you get back the same binary.

                https://github.com/ziglang/zig-bootstrap

                1. 7

                  I’m curious, is there some reason you don’t instead write a backend for the Zig implementation of the compiler to output C code? That seems like it would be easier than maintaining an entirely separate compiler. What am I missing?

                  1. 2

                    That is the current plan as far as I’m aware

                    1. 1

                      The above post says they wanted two separate compilers, one written in C and one in Zig. I’m wondering why they just have one compiler written in Zig that can also output C code as a target. Have it compile itself to C, zip up the C code, and now you have a bootstrap compiler that can build on any system with a C compiler.

                      1. 2

                        In the above linked Zig Roadmap video, Andrew explains that their current plan is halfway between what you are saying and what was said above. They plan to have the Zig compiler output ‘ugly’ C, then they will manually clean up those C files and version control them, and as they add new features to the Zig source, they will port those features to the C codebase.

                        1. 2

                          I just watched this talk and learned a bit more. It does seem like the plan is to use the C backend to compile the Zig compiler to C. What interests me though is there will be a manual cleanup process and then two separate codebases will be maintained. I’m curious why an auto-generated C compiler wouldn’t be good enough for bootstrapping without manual cleanup.

                          1. 7

                            Generated source code usually isn’t considered to be acceptable from an auditing/chain of trust point of view. Don’t expect the C code generated by the Zig compiler’s C backend to be normal readable C, expect something closer to minified js in style but without the minification aspect. Downloading a tarball of such generated C source should be considered equivalent to downloading an opaque binary to start the bootstrapping process.

                            Being able to trust a compiler toolchain is extremely important from a security perspective, and the Zig project believes that this extra work is worth it.

                            1. 2

                              That makes a lot of sense! Thank you for the clear and detailed response :)

                            2. 2

                              It would work fine, but it wouldn’t be legitimate as a bootstrappable build because the build would rely on a big auto-generated artifact. An auto-generated artifact isn’t source code. The question is: what do you need to build Zig, other than source code?

                              It could be reasonable to write and maintain a relatively simple Zig interpreter that’s just good enough to run the Zig compiler, if the interpreter is written in a language that builds cleanly from C… like Lua, or JavaScript using Fabrice Bellard’s QuickJS.

                              1. 1

                                Except that you can’t bootstrap C, so you’re back where you started?

                                1. 2

                                  The issue is not to be completely free of all bootstrap seeds. The issue is to avoid making new ones. C is the most widely accepted and practical bootstrap target. What do you think is a better alternative?

                                  1. 1

                                    C isn’t necessarily a bad choice today, but I think it needs to be explicitly acknowledged in this kind of discussion. C isn’t better at being bootstrapped than Zig, many just happen to have chosen it in their seed.

                                    A C compiler written in Zig or Rust to allow bootstrapping old code without encouraging new C code to be written could be a great project, for example.

                        2. 1

                          Or do like Golang. For bootstrap you need to:

                          1. Build Go 1.4 (the last one made in C)
                          2. Build the latest Go using the compiler from step 1
                          3. Build the latest Go using the compiler from step 2
                        3. 3

                          Build the Zig compiler to Wasm, then run it to cross-compile the new compiler. Wasm is forever.

                          1. 11

                            I certainly hope that’s true, but in reality wasm has existed for 5 years and C has existed for 50.

                            1. 2

                              The issue is building from maintained source code with a widely accepted bootstrapping base, like a C compiler.

                              The Zig plan is to compile the compiler to C using its own C backend, once, and then refactor that output into something to maintain as source code. This compiler would only need to have the C backend.

                              1. 1

                                I mean, if it is, then it should have the time to grow some much needed features.

                                https://dl.acm.org/doi/10.1145/3426422.3426978

                              2. 1

                                It’s okay if you don’t know because it’s not your language, but is this how Go works? I know there’s some kind of C bootstrap involved.

                                1. 4

                                  The Go compiler used to be written in C. Around 1.4 they switched to a Go compiler written in Go. If you were setting up an entirely new platform (and not use cross compiling), i believe the recommended steps are still get a C compiler working, build Go 1.4, then update from 1.4 to latest.

                              3. 2

                                How do we build C compilers from source?

                                1. 3

                                  Bootstrapping a C compiler is usually much easier than bootstrapping a chain of some-other-language compilers.

                                  1. 4

                                    Only if you accept a c compiler in your bootstrap seed and don’t accept a some-other-language compiler in your seed.

                                    1. 3

                                      Theoretically. But from a practical point of view? Yes, there are systems like Redox (Rust), but in most cases the C compiler is an inevitable piece of the puzzle (the bootstrapping chain) when building an operating system. And in such cases, I would (when focused on simplicity) rather prefer a language that depends just on C (that I already have) instead of a sequence of previous versions of its own compilers. (and I say that as someone, who does most of his work in Java – which is terrible from the bootstrapping point-of-view)

                                      However, I do not object much against the dependence on previous versions of your compiler. It is often the way to go, because you want to write your compiler in a higher language instead of some old-school C and because you create a language and you believe in its qualities, you use it also for writing the compiler. What I do not understand is why someone (not this particular case, I saw this pattern before many times) present the “self-hosted” as an advantage…

                                      1. 2

                                        The self-hosted Zig compiler provides much faster compile times and is easier to hack, allowing language development to move forward. In theory the gains could be done in a different language, but some of the kind of optimizations used are exactly the kind of thing Zig is good at. See this talk for some examples: https://media.handmade-seattle.com/practical-data-oriented-design/.

                                      2. 1

                                        But you could make a C compiler (or a C interpreter) from scratch relatively easily.

                                2. 6

                                  Fennel being loadable from Lua, and Lua being written in ANSI C makes an interesting combination for anyone wanting to write bootstrappable software in a functional style.

                                  1. 4

                                    Aren’t many LISPs written in C?

                                    1. 9

                                      Indeed but Lua is insanely portable. They have taken great pains to depend only on what is guaranteed by C89: there are no endian dependencies, no assumptions about struct layout, etc.

                                      1. 5

                                        Yes but it’s unusual to have no dependencies beyond a C89 compiler and libc.

                                        1. 2

                                          I’m pretty sure Janst can be built with just a C compiler. And several of the numerous dialects of Scheme.

                                        2. 3

                                          Some, but most are written in Lisp, maybe or maybe not with a C core for runtime. Bootstrapping is occasionally a bit of a headache.

                                          1. 3

                                            Most LISPs are not what I’d consider Functional. They’d support it, sure, and functions are first class, but they don’t emphasize immutability and bottom-up-creation and side-effect limiting like what I think of with functional languages.

                                            1. 4

                                              Absolutely true. I’ve never understood why LISP gets associated with functional. The syntax seems like it would lead that direction, but in practise most LISPs are very low level.

                                              1. 2

                                                Back when lisps were new, the fact that it was even possible to do functional programming at all was considered unique and novel. Having access to lambda was considered a very advanced feature. Nowadays if your language doesn’t even have closures, no one will really take it seriously, so whatever association lisp-in-general has with FP should probably be thought of as historical.

                                                1. 3

                                                  When lisps were new, they frequently lacked lexical closures. See the ‘upwards funarg problem’.

                                                  1. 1

                                                    I may be a heretic here but I actually think lexical closures are bad, and a poor substitute for currying/partial application.

                                                    1. 4

                                                      You’ll hate Fennel then! Probably shouldn’t use it. Closures are more central to Fennel than any other language I know.

                                                      1. 1

                                                        More than other lisps?

                                                        1. 2

                                                          I haven’t used every lisp, but …

                                                          • much more than: Emacs Lisp, Common Lisp, Hy, LFE
                                                          • a fair bit more than: Clojure
                                                          • a little more than: Racket, Scheme (mostly due to the module system which is mostly closures)

                                                          Fennel has partial, but not currying, since it’s on a runtime where argument count for a function isn’t determinable.

                                                      2. 1

                                                        What is the difference between lexical closures and currying/partial application?

                                                        1. 2

                                                          With a lexical closure every term that is closed over now has to live as long as the execution of that closure, with no explicit annotation of anything about the sharing.

                                                          When a human reads the program they have to remember if this is a by-value or by-name binding.

                                                          If you want a type system that incorporates lifespans or ownership, then again you need some default rule to describe the relationship between outer and inner code, which the programmer has to remember and cannot alter.

                                                          By contrast, if all such sharing happens via a function call (which is to say with explicit parameter passing and type annotation) then the writing programmer can make explicit what the sharing regime is, and the reader can apply the same rules that apply when they read any other function call.

                                                          Obviously, you can do absolutely amazing things with lexical closures, but you can also do all those things with non-closing functions and partial application.

                                                          I guess I’m saying that explicit is better than implicit.

                                                          1. 2

                                                            When a human reads the program they have to remember if this is a by-value or by-name binding.

                                                            This is less an argument against closures and more an argument for making your language have consistent and sensible argument passing semantics. It’s not a problem in Fennel because the distinction between pass-by-value and pass-by-name is irrelevant.

                                                            If you want a type system that incorporates lifespans or ownership, then again you need some default rule to describe the relationship between outer and inner code, which the programmer has to remember and cannot alter.

                                                            Again, there are plenty of contexts where this is true, but none of this is the slightest bit relevant here.

                                                            1. 2

                                                              Thanks for the response, but this didn’t address the question I had.

                                                  2. 1

                                                    Yeah my knowledge is somewhat stale but at least back in the day only the very core functions were in C and the majority of the image was LISP.

                                                    There was also a lot on top of that core that use a foreign function interface to layer in functions from C-land like UI libraries and the like.

                                                  3. 3

                                                    Fennel & Lua seem like a great duo to be aware of. I’ve also recently learned about Fabrice Bellard’s QuickJS which is interesting for similar reasons as a simple & embeddable pure C implementation of ES2020.

                                                  4. 15

                                                    There are circumstances in which modeling a computer system as a set of immutable artifacts is useful, definitely. But the thing is that a computer system is actually stateful and mutable! That’s the reality. Nix is a useful approach for specific, narrow, use cases. It’s not a panacea.

                                                    1. 21

                                                      NixOS isn’t saying the whole system has to be immutable. It’s an immutable base where your operating systems, applications, and configuration live. You then layer on top your mutable user space.

                                                      1. 1

                                                        The operating system, applications, and configuration are all mutable, though — outside of the narrow context of provisioned servers in purpose-driven organizations.

                                                        1. 2

                                                          Are they though? The configuration is mutable whether it’s windows, Ubuntu or nixos. That’s not taken away. Same for home directories. But the system has been effectively immutable in many ways for a long time. Packages are installed in transactions and removed as a unit anyway. If an Ubuntu system for example got a read-only /usr that automatically unlocks / relocks during dpkg runs - how long would it take a typical non-provisioned-server user to notice?

                                                          1. 1

                                                            Maybe I understand it incorrectly. My understanding is that if I install something with Nix that normally would put a config file at /etc/something.conf, I can’t actually edit /etc/something.conf. Am I wrong?

                                                            1. 2

                                                              You have 2 options. Either 1) do that configuration in nix and then your /etc/something.conf is a symlink to the generated file in /nix/store/… , Or 2) remove the symlink and edit /etc/something.conf as a usual file.

                                                          2. 1

                                                            Nix supports these use cases fairly way in my experience, but it could be better and simpler imo.

                                                        2. 8

                                                          Nix-the-package-manager is not concerned with modelling computer systems at all. It’s all about building software and managing dependencies in a principled, repeatable, generational system. It can run side-by-side with other package managers, is generally self-contained, and is a pretty small piece of software relative to e.g. Aptitude et. al.

                                                          NixPkgs the package set provides a huge set of recipes for packaging all kinds of software, and includes all kinds of utilities for modelling computer systems. Not as immutable artifacts, but as consistent configuration sets. The really cool thing is that i can build (and even cross-compile) any set of software (including a full OS config) and push it peer-to-peer to 1..N machines out in the world, atomically switch to that new software whenever I like, and roll it back if it didn’t work.

                                                          NixOS the realization of a your specific configuration, via the module system. By default it provides a mostly-readonly /etc/ symlink tree and that’s about it. When installing nixos you’re encouraged to customize everything else. you can have a tmpfs backing the filesystem root, some people use ZFS snapshots that rollback on every reboot, and other people leave it completely mutable. All your state lives in /var/ as it always has, /tmp is used by software of all types, and home directories are the same chaotic mutable mess they always have been.

                                                          Nix is a useful approach for specific, narrow, use cases

                                                          This is like saying “GCC is a useful approach for specific, narrow, use cases”. Nix is like a higher-order compiler. It compiles software packages, and links them together into software systems.

                                                          1. 1

                                                            it provides a mostly-readonly /etc/ symlink tree . . .

                                                            This is kind of my point, maybe? As an owner of a computer system that has an /etc directory, it’s important that I can just… edit the files in there, arbitrarily and directly, and observe their effects. I understand the value of enforcing reproducibility and repeatability and all that! But those things aren’t free. They have costs, and those costs are substantial — IMO only justified in narrow circumstances, almost all of which exist in profit- or purpose-driven organizations.

                                                            1. 3

                                                              The experience is similar on NixOS. On a GNU/Linux system with systemd, you might want to do:

                                                              # nano /etc/foo.conf
                                                              # systemctl restart foo
                                                              

                                                              NixOS also has a workflow for editing files in /etc and restarting services:

                                                              # nano /etc/nixos/configuration.nix
                                                              # nixos-rebuild switch
                                                              

                                                              The ability to rollback is free. Reproducibility is as expensive as version-controlling /etc, but thus optional.

                                                              1. 2

                                                                Nah, I run NixOS on several of my own personal machines running software only I use. It’s really cool and useful that I can programmatically specify (and version-control) the state of my Linux system, including the contents of /etc files.

                                                                There is value in being able to edit and experiment with your configuration files directly, although I’m not too concerned if this is /etc/ssh/ssh_conf or the /etc/nix/configuration.nix that generates it. NixOS needs better documentation and perhaps abstractions for a lot of things, one of which is how to easily create overlays in the nix language that let you extend the default methods of configuration with custom ones.

                                                                1. 2

                                                                  I guess i should clarify that the symlink tree in /etc isn’t read-only, but the symlinks point to files in /nix/store/ which are readonly.

                                                                  Nothing stopping you deleting the symlink and putting your own config file there, or mounting an overlayfs over /etc and editing files that way.

                                                                  enforcing reproducibility and repeatability certainly isn’t free, and it’s a choice to take on that level of rigor, but it’s also not particularly hard. It can also really help when you finally fix the issue you’ve been debugging for half a day and have to figure out what changes you made actually fixed the problem.

                                                                  The benefits also compound over time. If you’ve been using the same laptop for 3 years, and want to move to a laptop, how do you bring all your ad-hoc configuration changes with you? is it safe to copy all files in /etc/ across installs? If you have a nix configuration, you only need to copy or git-clone that config onto a new machine and nixos-rebuild will build out a fresh install exactly the way you like it.

                                                                  I don’t think these costs are substantial enough to be only justified in narrow circumstances. Personally, running NixOS has actually saved me more time that it’s cost me. I fully respect that it may not be the same tradeoff to you, but I’m quite happy to invest some time up-front in a technology that will save me more much time down the line.

                                                                2. 1

                                                                  I think it would probably help if the Nix community could find a better naming convention. As it is, it feels like watching old Smurfs cartoons, where every other word they say is “Smurf” but it smurfs different smurfs every smurf they smurf it means different things every time they say it. Then there wouldn’t be a need to break down multiple different things “Nix” means.

                                                                  1. 1

                                                                    I’m aware I’m a month late here but there is exactly one thing called Nix. NixPkgs, NixOS, Nix Expression Language, they all have other names. This is like saying the Java community should come up with a different name for the Java Virtual Machine because it’s confusing that it has Java in the name.

                                                                3. 5

                                                                  Nix models mutation in the same way Git does: with atomically updated references into an underlying content-addressed store.

                                                                  1. 1

                                                                    Right! Sure. And I guess my point is that’s a great model for some computing environments, but not all, or even most. The overhead is an impedance mismatch with the actual needs of the users. IMO, of course.

                                                                    1. 4

                                                                      I think of NixOS as a pioneering project for a really great concept. So I imagine there will be several different NixOS-based distributions. Like imagine Debian is to Ubuntu as ? is to NixOS. There’s not even a graphical installer for NixOS yet. If you make a convenient graphical editor for a curated subset of NixOS’s configuration space, so users can toggle installed packages in an “app store” and tweak their setup in a user-friendly editor—I see no reason why that couldn’t be absolutely delightful and far MORE user-friendly than traditional distributions.

                                                                  2. 2

                                                                    Nix is a useful approach for specific, narrow, use cases.

                                                                    I use Nix for absolutely everything. I work on Atlassian products, host servers, use random software projects (stuff like Python, Go, Haskell, etc) and we deploy using Nix at work. There’s nothing narrow about it.

                                                                    1. -2

                                                                      I work on Atlassian products,

                                                                      I’m so sorry.

                                                                      😉

                                                                  3. 6

                                                                    Some years ago I wrote my own local development web server in a few dozen lines of bash. I could never get nc to work for serving concurrent requests (i.e. html+js+css at the same time) but ncat works great.

                                                                    It was actually really nice for prototyping with compile-to-js languages like ClojureScript or PureScript, as well as very quickly mocking up little CRUD apps. You’d write little executables to handle all the different HTTP verbs.

                                                                    https://github.com/ianthehenry/httprintf

                                                                    i.e. start it up, POST /some/resource, and it’ll try to run ./some/resource/POST if that script exists, then fall back to parent directories. Kind of a cute little hack.

                                                                    1. 3

                                                                      I’ve enjoyed using Bernstein’s tcpserver for this exact thing. It doesn’t do TLS though.

                                                                      https://cr.yp.to/ucspi-tcp/tcpserver.html

                                                                    2. 11

                                                                      I figured the comments would look like this, based on how many coders like dark themes. Honestly it doesn’t matter how scientific the evidence in this article isor isn’t, because if you disagree with its conclusions you’re all smart enough to find something you can invalidate it for. That’s the way our brains are wired, and being smart doesn’t really reduce that tendency, in fact it can make it worse because it’s easy for us to act like know-it-alls.

                                                                      But yes, there is science behind this. For me, astigmatism is the clincher: it’s very common and it very definitely reduces optical acuity when the iris is wide open, i.e. looking at a dark scene, because basic optics. I have it, and this effect is very noticeable. (It’s not the only reason, though.)

                                                                      And yes, there have been scientific studies of reading and legibility for, oh, at least a century. As far back as the 1960s it was known that black text on a pale green or yellow background results in the least eye strain and best comprehension.

                                                                      1. 4

                                                                        Looks very interesting. I’d be interested in seeing reviews.

                                                                        1. 11

                                                                          I bought it and have done a read through. I’m interested in algebraic structures as building blocks for programming, verification through specifications, and denotative design, and have spent time with all these concepts. I’m probably on the advanced side of the target audience.

                                                                          The book covers the process of creating “laws” to model a problem, using a mechanical process to create a naive implementation, using tooling to derive quickcheck specs, and then creating a better implementation using those specs as verification you’re not breaking your domain model. The modeling is similar to denotative design though not quite as formal on its notation. It does show that domain problems can be modeled with Monoids, Functors, Functions, etc and includes an appendix to discuss these structures. It uses haskell as it’s code and tooling environment, though I can take the concepts and use them in clojure.

                                                                          The sample of the book covers the first problem, which I recognized from https://github.com/conal/talk-2014-lambdajam-denotational-design and Conal Elliot’s other work. The second domain problem deals with matching user photos to a location to grant rewards. Think about a scavenger hunt or pokemon go style game. I still need to reread and spend some more time processing this example to really get everything deeply.

                                                                          I’d have enjoyed another example of a problem domain going through the design phases. Having the first one be from prior sources is fine for introductions to the ideas, but I was hoping to see it applied multiple times to something new.

                                                                          Seeing the use of tooling over the naive implementation to generate quickcheck specs, even ones not in the original design’s laws, was new to me and cool to see. Also the second example eventually gets complex enough that I think it shows the value of the specs.

                                                                          Overall, I’m happy with my purchase of the book.

                                                                          1. 5

                                                                            There’s a pretty interesting book called “Algebraic Models for Accounting Systems” that I stumbled onto. You might be curious:

                                                                            https://www.amazon.com/Algebraic-Accounting-Systems-Salvador-Rambaud/dp/9814287113

                                                                          2. 2

                                                                            There’s a link to the first few chapters at the bottom of the page.

                                                                          3. 3

                                                                            As I do in every thread about mail server hosting, I will mention that the NixOS-based “simple-nixos-mailserver” has worked ideally for me. Haven’t touched it in two years except to add users.

                                                                            https://gitlab.com/simple-nixos-mailserver/nixos-mailserver/-/wikis/A-Complete-Setup-Guide

                                                                            1. 2

                                                                              Seconded – this module is wonderful, and makes server installation almost braindead easy aside from DNS.

                                                                            2. 2

                                                                              Very interesting. I would definitely try to use Grammatical Framework for a prototype, since its “resource grammars” for natural languages represent a ton of usable linguistic work. It’s very briefly cited in the technical paper but only to say that functional languages are promising for language generation. Indeed GF works today and has a pleasant formalism.

                                                                              1. 5

                                                                                After using it for a while I started to find the Nix expression language as one of the best designed syntaxes ever. It doesn’t have separators for records or lists so it’s friendly to diff. The multiline strings are perfect. Writing nested records with “a.b.c” keys is super convenient. The lambda syntax is as simple as possible. Etc etc.

                                                                                1. 9

                                                                                  It doesn’t have separators for records or lists so it’s friendly to diff.

                                                                                  Records are separated with the ; symbol.

                                                                                  As for lists, I beg to disagree. The list symbols are separated with a whitespace, which is unfortunate since whitespace is also used to represent function application. It means you’ll have to be careful enough to wrap your function applications in parenthesis every time you’ll perform it in a list.

                                                                                  That’s a easy trap to fell into, especially in multi-lines statements. Add the lazy nature of the language on top of that, you can end up with stacktraces that are pretty difficult to decipher. Especially if you end up doing that in a NixOS machine description :/.

                                                                                  I see a lot of newcomers falling into this trap on IRC.

                                                                                  e.g:

                                                                                  let pkgs = [
                                                                                    htop
                                                                                    import ./local-pkgs.nix
                                                                                    ssh
                                                                                  ]; in ...
                                                                                  

                                                                                  Instead of

                                                                                  let pkgs = [
                                                                                    htop
                                                                                    (import ./local-pkgs.nix)
                                                                                    ssh
                                                                                  ]; in ...
                                                                                  
                                                                                  1. 2

                                                                                    Sorry, I meant separators to mean comma-like separators where the last item doesn’t end with the separator.

                                                                                    The issue you mentioned is real, yeah. I still love the syntax.

                                                                                2. 9

                                                                                  Great news! I am eager to try this!

                                                                                  Turn on -XLinearTypes, and the first thing you will notice, probably, is that the error messages are typically unhelpful: you will get typing errors saying that you promised to use a variable linearly, but didn’t. How hasn’t it been used linearly? Well, it’s for you to puzzle out. And while what went wrong is sometimes egregiously obvious, it can often be tricky to figure the mistake out.

                                                                                  So, basically, GHC just got its own “Syntax error” a la OCaml… just a bit more specialized :p.

                                                                                  1. 11

                                                                                    Maybe it’s just me, but to me OCaml’s errors are terse and unhelpful and GHC’s errors are… verbose and unhelpful. ;)

                                                                                    There are interesting papers that show working ways to improve both, but I wonder why none of those improvements are in the mainline compilers.

                                                                                    1. 2

                                                                                      Good error reporting is easiest if it’s built into the compiler front end from the start. If a new algorithm comes along to improve the error information it’s almost never going to be a simple job to drop it into an existing compiler.

                                                                                      You need type information & parse information from code that’s potentially incorrect in both spaces, so any error algorithm usually has to be tightly integrated into both parts of the compiler front end. That tight integration usually means that improving compiler errors is a significant amount of work.

                                                                                      1. 3

                                                                                        It varies. What puzzles me is that a lot of time ready to use, mergeable patches take much longer to merge than they should.

                                                                                        Like this talk: https://ocaml.org/meetings/ocaml/2014/chargueraud-slides.pdf

                                                                                        1. 1

                                                                                          Do you also have a link for a patch for the improved error messages?

                                                                                          A lot of work has been going on to move OCaml to a new parser and improve error messages. Even though there is a lot still needed to be done, latest releases have started improving a lot. Maybe we can still extract some useful bits from that effort and try again

                                                                                          1. 2

                                                                                            Turns out it was even made into a pull request that isn’t merged yet: https://github.com/ocaml/ocaml/pull/102

                                                                                            1. 1

                                                                                              Thanks. It is quite an informative PR actually, and explains why the change is not there yet and once can infer why it is easier to add informative messages in new languages and complier but it may be quite hard to retrofit them to seasoned ones

                                                                                    2. 7

                                                                                      Would you be kind enough to give me an ELI5 about what linear types are and what you can do with them?

                                                                                      1. 29

                                                                                        In logic, normal implication like A implies B means whenever you have A, you can derive B. You have tautologies like “A implies (A and A)” meaning you can always infinitely duplicate your premises.

                                                                                        Linear implication is a different notion where deriving B from A “consumes” A. So “A linearly implies B” is a rule that exchanges A for B. It’s not a tautology that “A linearly implies (A and A).”

                                                                                        The classic example is you can’t say that “$3 implies a cup of coffee” but “$3 linearly implies a cup of coffee” makes sense. So it’s a logical form that reasons about resources that can be consumed and exchanged.

                                                                                        Same in functional programming. A linear function from type A to type B is one that consumes an A value and produces a B value. If you use it once with an A value then you can’t use it again with the same A value.

                                                                                        This is nice for some performance guarantees, but also for encoding safety properties like “a stream can only be read once” etc.

                                                                                          1. 5

                                                                                            It can be used to model protocols with type signatures. The following is in theory what you should be able to do.

                                                                                            data ConsoleInput
                                                                                                = Input String ConsoleOutput
                                                                                                | ExitInput
                                                                                            
                                                                                            data ConsoleOutput
                                                                                                = PrintLines ([String] ⊸ Console)
                                                                                                & PrintLastLines ([String] ⊸ ())
                                                                                            
                                                                                            greet :: ConsoleOutput ⊸ ()
                                                                                            greet console
                                                                                                = let PrintLines f = console
                                                                                                  in step2 (f ["name?"])
                                                                                            
                                                                                            step2 :: ConsoleInput ⊸ ()
                                                                                            step2 ExitInput = ()
                                                                                            step2 (Input input console)
                                                                                                = let PrintLastLines f = console
                                                                                                  in f ["hello " ++ input]
                                                                                            

                                                                                            If you combine it with continuation passing style, you get classical linear logic and it’s a bit more convenient to use.

                                                                                            If you model user interfaces with types, they should be quite useful.

                                                                                            I’m also examining and studying them: http://boxbase.org/entries/2020/jun/15/linear-continuations/

                                                                                            1. 1

                                                                                              Wikipedia gives a reasonable overview. The closest analogy would be something like move semantics – for example ownership in Rust can be considered as manifestation of linear types.

                                                                                              1. 6

                                                                                                Rust ownership is linear affine types. Linear types are similar but differ in the details. A shitty way of understanding it is affine types mimic ref counting and prevent you from having a ref count < 0. Linear types are more a way of acting like RAII in that you might create a resource but just “know” that someone later on in the chain does the cleanup.

                                                                                                Which I’m sure sounds similar but affine types allow for things like resource leaks but linear types should guarantee overall behavior to prevent it.

                                                                                                This all assumes my understanding and explanation is apt. I’m avoiding a ton of math and i’m sure the shitty analogy doesn’t hold up but behaviorally this is how I have it in my brain.

                                                                                                  1. 2

                                                                                                    I’m personally of the stance that the 2020 linear ghc stuff is more <= 1 usage, and kinda misses out on a lot of really fun expressivity that can fall out of making full classical linear logic first class. But that’s a long discussion in its own right , and I’ve yet to make the time to figure out the right educational exposition on that front

                                                                                                    1. 1

                                                                                                      it definitely seems more limited in scope/ambition compared to the effort ongoing for dependent types, for better or worse. Can’t say I know much about what first class linear logic would look like, but perhaps now there will be more discussion about such things.

                                                                                                      1. 2

                                                                                                        The really amazing thing about full linear logic is it’s really sortah a rich way to just do mathematical modelling where everything has a really nice duality. The whole thing about linearity isn’t the crown jewel (though wonderfully useful for many applications ), it’s that you get a fully symmetric bag of dualities for every type / thing you can model.

                                                                                                        The paper that really made it click for me was mike shulmans linear logic for constructive mathematics paper. It’s just a fun meaty read even at a conceptual level. There’s a lot of other work by him and other folks that taken together just point to it being a nice setting for formal modelling and perhaps foundations of category theory style tools too!

                                                                                                    2. 1

                                                                                                      Not sure I can agree that Uniqueness types are the same as Linear types. Care to explain they’re similar sure but not the same thing and your… screenshot of a powerpoint? isn’t very illustrative of whatever point you’re trying to make here.

                                                                                                      And from my experience with Idris, I’m not sure I’d call what Rust has Uniqueness types.

                                                                                                      1. 1

                                                                                                        They are different rows in the matrix because they are different, of course.

                                                                                                        it’s from this presentation about progress on linear ghc a little over a year ago https://lobste.rs/s/lc20e3/linear_types_are_merged_ghc#c_2xp2dx skip to 56:00

                                                                                                        What is meant by Uniqueness types here is “i can guarantee that this function gets the unique ptr to a piece of memory” https://i.imgur.com/oJpN4eN.png

                                                                                              2. 2

                                                                                                Am I the only one thinking this is not how you ship language features?

                                                                                                If the compiler can’t even report errors correctly, the feature shouldn’t ship.

                                                                                                1. 15

                                                                                                  If the compiler can’t even report errors correctly, the feature shouldn’t ship.

                                                                                                  Its more this is an opt-in feature with crappy error reporting for now using computer programming design features not in use in most programming languages. Its going to have rough edges. If we required everything to be perfect we’d never have anything improved. Linear types like this also might not have a great way to demonstrate errors, or the domain is new so why not ship the feature for use and figure out what kind of error reporting you want based on feedback.

                                                                                                  1. 13

                                                                                                    Many people do not realize that haskell is a research language and GHC is one of the main compilers for it. This is an experimental feature in a research language. If it works out well, then it will be standardized.

                                                                                                    1. 15

                                                                                                      You have an experimental feature and advertise as such, disable by default. It is not like it will become widely use anytime soon. I don’t get the outraged comments to be honest.

                                                                                                      1. 14

                                                                                                        This is utterly unprofessional

                                                                                                        I disagree. While good diagnostic messages are important in the long term, I think you can permit yourself to have less useful messages in the short term. Of course once shipped, you should dedicate time and resources to improving it.

                                                                                                        I can’t even remotely imagine how people thought this would be a good idea to ship if it isn’t even clear whether good error reporting is even technically possible.

                                                                                                        I think the reason is simple: to get feedback on the feature, how useful it is (regardless of the error messages), etc. Based on that you can then decide how to move on, what to focus on, etc.

                                                                                                        1. 4

                                                                                                          This is utterly unprofessional – my private hobby project has higher standards than this.

                                                                                                          Your private hobby project is almost 30 years old, and is used in production in any number of areas as well I take it?

                                                                                                          As goalieca notes, GHC/Haskell is a research langugage, its got a ton of extensions that you can opt in for, but accept that things can have rough edges largely because its near the bleeding edge of language design. This is one of them.

                                                                                                          There is literally no point in having this feature if it turns out that nothing can be done about error reporting.

                                                                                                          Of course there is a point, it is to explore Linear Types in spite of the error reporting. Advice from early “hair shirt” adopters will likely drive the error reporting or work towards a better system. I’m just pointing out that error reporting may not yet be even thought of as a concept of how Linear type systems are used.

                                                                                                          I’m not saying it isn’t possible, I’m saying it might not even be worth considering yet. Sometimes you have to implement things before you can fully know how to do it right. Same reason why Haskell will eventually move from a lazy language to a strict language. Only after you get decades into a design might you find out it was a dead end. But until you try it, nobody will ever know. In those conditions explain how you expect to learn the tacit knowledge to be “professional”? Someone somewhere has to do the work, this is how it happens.

                                                                                                          If you ever wondered why software is in such an utter state of disrepair, it’s because of shit like this.

                                                                                                          To be blunt, your axiomatic thinking is not helping matters, this is what research IS. It is ugly, incomplete, and the only way to move forward. This is the exploration of computer science concepts never implemented anywhere in an existing langauge. Of course its won’t be pretty, it took 4 years to get to “it compiles and we can use it, lets make it a POC/MVP and get feedback from people that see value from it”.

                                                                                                      2. 5

                                                                                                        Other people have sort-of said it, but not clearly enough I think. This is not a language feature being added. It is a feature-flagged experimental feature of a particular compiler. Most such compiler extensions never make it into real Haskell, and the ones that do take years after they are added to a compiler to make it to a language spec.

                                                                                                        1. 4

                                                                                                          for all practical purposes isn’t “real Haskell” defined by what ghc implements these days?

                                                                                                          1. 2

                                                                                                            Yes, all the other implementations are dead. They still work, but they won’t run most modern Haskell code, which usually uses a bunch of GHC extensions.

                                                                                                            1. 1

                                                                                                              You might say “isn’t it not popular to write standards-compliant Haskell these days?” and you’d be right. Of course it’s often trendy to write nonstandard C (using, say, GNU extensions) or nonstandard HTML/JavaScript. However, ignoring the standard being trendy doesn’t mean the standard doesn’t exist, or even that it isn’t useful. I always make sure my Haskell is Haskell2010, and I try to avoid dependencies that use egregious extensions.

                                                                                                            2. 2

                                                                                                              Honestly curious: are there any other Haskell compilers out there? Are they used in production?

                                                                                                              Also, what is a definition of a true Haskell? I always thought it’s what’s in GHC.

                                                                                                              1. 5

                                                                                                                There’s a Haskell which runs on the JVM - Frege. But it makes no attempt to be compatible with the version of Haskell that GHC impements, for good reasons. Hugs is a Haskell interpreter (very out of date now, but still works fine for learning about Haskell.) There a bunch of other Haskell compilers, mostly research works that are now no longer in development - jhc, nhc98 etc etc.

                                                                                                                But GHC is the dominant Haskell compiler by far. I don’t think there are any others in active development, apart from Frege, which isn’t interested in being compatible with GHC.

                                                                                                                (“True Haskell” is the Haskell defined in the Haskell Report, but real world Haskell is the Haskell defined by what GHC + your choice of extensions accepts.)

                                                                                                                1. 2

                                                                                                                  There are other compilers and interpreters. None of them is anywhere near as popular as GHC, and usually when one does something interesting GHC consumes the interesting parts.

                                                                                                                  There is definitely a standard, though: https://www.haskell.org/onlinereport/haskell2010/

                                                                                                                  The whole reason language extensions are called “extensions” and require a magic pragma to turn on is that they are not features of the core language (Haskell) but experimental features of the compiler in question.

                                                                                                                2. 1

                                                                                                                  In short, GHC Haskell is a language designed by survival-of-the-fittest.

                                                                                                                3. 3

                                                                                                                  Overly terse error messages are bad, but they are better than wrong error messages. Some things are much harder to give helpful error messages for than others.

                                                                                                                  I wish people spend more time improving error reporting, at least in cases when the way to do it is well understood. There is no reason for say TOML or JSON parsers to just say “Syntax error”. But, YAML parsers are pretty much doomed to give unhelpful errors just because the language syntax is ambiguous by design.

                                                                                                                  And then some errors are only helpful because we know what their mean. Consider a simple example:

                                                                                                                  Prelude> 42 + "hello world"
                                                                                                                  
                                                                                                                  <interactive>:1:1: error:
                                                                                                                      • No instance for (Num [Char]) arising from a use of ‘+’
                                                                                                                      • In the expression: 42 + "hello world"
                                                                                                                        In an equation for ‘it’: it = 42 + "hello world"
                                                                                                                  

                                                                                                                  How helpful is it to a person not yet familiar with type classes? Well, it just isn’t. It’s not helping the reader to learn anything about type classes either.

                                                                                                                  1. 1

                                                                                                                    I’ve seen some good suggestions on r/haskell for improving the wording of these errors.

                                                                                                                  2. 2

                                                                                                                    The error they’re talking about is a kind of type error they’ve not worked with. It’s produced if you forget to construct or use a structure. I I’m guessing it’s technically “proper” but the produced error message may be difficult to interpret.

                                                                                                                    They’ve ensured it’s a feature you can entirely ignore if you want to. Everybody’s not convinced they need this.

                                                                                                                    I otherwise dunno what they’re doing and I’m scratching my head at the message. Something like “Oh cool you’ve done this… … … So where are the types?”

                                                                                                                    1. 2

                                                                                                                      So you never got a C++ template error in the good olden days? Seriously though, it just got merged. It’s not released or “shipped” in any means.

                                                                                                                      1. 0

                                                                                                                        So you never got a C++ template error in the good olden days?

                                                                                                                        No, because I looked at the language, figured out that the people involved completely lost their fucking mind, and moved on.

                                                                                                                        Seriously though, it just got merged. It’s not released or “shipped” in any means.

                                                                                                                        They took 4 years to arrive at the current state, which I’ll approximate at roughly 10% done (impl unfinished, spec has unresolved questions, documentation doesn’t really seem to exist, IDE support not even on the radar).

                                                                                                                        So if you assume that there will be a Haskell version in the next 36 years, then this thing is going to end up in some Haskell release sooner or later.

                                                                                                                        1. 2

                                                                                                                          So if you assume that there will be a Haskell version in the next 36 years, then this thing is going to end up in some Haskell release sooner or later.

                                                                                                                          Could you elaborate on this? If practical users of linear types will only use them if they have good error messages, and early testers want to work out the kinks now, what’s wrong with having a half-baked linear types feature with no error messages permanently enshrined in GHC 8.12?

                                                                                                                  3. 2

                                                                                                                    In the Nix language, expressions are the top-level language construct. (As opposed to, for example, statements in JavaScript / Python / Ruby, or definitions in C and friends.)

                                                                                                                    (nitpick) this is also true of Ruby

                                                                                                                    1. 1

                                                                                                                      Eek! Thanks for pointing this out. I simply removed the mention of Ruby there. :-)

                                                                                                                      1. 2

                                                                                                                        It’s still true that Nix’s top-level construct is one expression used only for its value, while Ruby’s is a sequence of expressions used only for their side-effects…

                                                                                                                    2. 29

                                                                                                                      This is a very long winded article and yet in a way it stopped too short. The thesis is that software didn’t go wrong but that software exists in an environment motivated by capital. The intuition that the problem isn’t software but the context that software lives in is a good one. But the author shouldn’t have stopped at Capital. The problem is that Capital exists in a context as well. At it’s crux the issue is human nature. Human nature has a number of failure modes. Those failure modes manifest in the use and accumulation of Capital as well in the development of code and in fact in any alternative attempt to replace Capital as a motivation.

                                                                                                                      Solving the failure modes of software requires solving the failure modes of human beings.

                                                                                                                      1. 36

                                                                                                                        There is a reflex in anglophone online discussion to jump straight to attributing the state of capitalism in the US to fundamental forces of the universe, as if the sad state of healthcare provision, public transport, employment law, infrastructure etc etc are just inevitable because Human Nature. And also it has to be this way because the alternative is communism.

                                                                                                                        It seems to wilfully ignore most of the rest of the developed world. You can make useful inroads into this problem with boring, un-pontificatey, un-weary-old-sage stuff like policy and government and compromise and all the other things that are deeply unfashionable to the point of being broken at the moment. It does work if you let it. The state of the examples I gave above are the result of active choices made by Americans, knowingly or otherwise. I am not saying for a second e.g. north west Europe is perfect, that is impossible because it is impossible to solve the failure modes of human beings. They have merely made a different choice to Americans about how they want their society to be (e.g. the things I mentioned above are a higher priority).

                                                                                                                        At the present time, the USA is one of the easiest places in the world to become a billionaire, unhindered (relatively) by constraints societal, regulatory and moral that exist in other places (the recent tax cuts, the wealth gospel, marking up insulin 1000% would all be seen as Martian to a Dane, for example). Americans voted for this. The only other similarly fertile time for rapidly-accumulated billions in recent history was the oligarch class that formed in the vacuum of the collapsed USSR. Though in that case the absence of effective government and regulation wasn’t as a result of an active choice by the citizens.

                                                                                                                        Choosing to remove many of the constraints against rapid capital accumulation is now really starting to eat into the things that gave america its strengths in the first place, such as good research and the ability to spin that research into productive industries. R&D labs are expensive and don’t survive CFO-orchestrated mergers. You can’t innovate in your Valley garage anymore because you can’t afford to buy the house with the garage from the Instagram employee who is selling it. I shouldn’t even use the valley in my example as a shorthand for an innovative place. It used to be an engine of technological innovation, now it only is if you squint really hard to try and see selling adverts as a branch of computer science. Instagram replaced Intel. Good on the VCs for taking the valley and shaping it in the way that maximises the rate at which they accumulate capital, they are winning the game whose rules were written by the American electorate.

                                                                                                                        The sentiment ‘We won’t get anywhere until we solve human nature’ is a false dichotomy [the choice being between the status quo or some singular revolution in human behaviour] and quite seductive to people like us who like grand, clever, sexy [a troublesome used deliberately here] new advances to cleanly solve existing problems. (c.f. the grim and now-parodied heydays of TED where people queued up to pronounce things like ‘Technology Will Fix Education’).

                                                                                                                        Your messiah won’t come and fix it. You, I, we all need to take the basics seriously and make careful choices in our everyday lives. It’s much less convenient for me at the moment to buy an oven glove online from a local kitchenware place than from amazon, but I do because it’s important. I spent $30 instead of $5 to get my hobby PCBs made in this country rather than in China because it’s important. I walked in the cold rain when I was tempted to stay inside to canvas for a local political cause because it’s important. None of these are big revolutionary things, they’re just trying to be a better cog in the machinery of my society (and all of us exist within and shape our societies, even if we don’t want to) because that’s important. The basics are important. Regulators musn’t turn a blind eye to the accumulating shortcuts of their industries. The law must apply to everyone. Lobbying is bribery by any other name but is much more tightly regulated in other countries. The money in politics must be transparent.

                                                                                                                        All of these basics are difficult and boring and tiresome and essential and effective.

                                                                                                                        1. 5

                                                                                                                          I think it’s very helpful to view capitalism as an inevitable force of nature. Just like many other forces of nature, we want to mitigate, redirect and transform some of its effects. Wind is fine, storms and hurricanes require defensive action. Rivers are useful and even nice, but we need to guard against flooding and sometimes want/need to canalize a part.

                                                                                                                          Capitalism may be human nature, but that implies nothing about the acceptable/desirable consequences. If someone thinks otherwise, they are simply committing the naturalistic fallacy.

                                                                                                                          1. 2

                                                                                                                            This is an important point that too often gets left behind. Capitalism isn’t some option off a menu you choose when setting up your government. It exists now, it will exist in the future, it will always exist. The study of economics isn’t something we do because we control it, it’s something that already happens that we seek to more fully understand.v You can take the most oppressive regime in history, perhaps with every bit of money controlled by the state, and there was still capitalism. The “capital” just switched over to political influence, reputation, and so forth. The same principles apply.

                                                                                                                            History show us that the only thing you can really control about capitalism is how much of it you want to be overt versus covert.

                                                                                                                            These discussion are really sad to read. We start off with everything being about money: who has money, who doesn’t have money, who has too little, who has too much, and so forth. Then we venture on this long and winding journey around whatever problem we’re trying to analyze only to end back up where we started. Turns out? The problem was all about money! That’s the problem!

                                                                                                                            If I can take your premise and know how your analysis is going to conclude, you’re not doing much in the way of analysis. At best you’re simply regurgitating ideas you’ve consumed elsewhere and mangling them together. That might make for well-written and great prose, by the way. It could easily make for a piece of text worth reading and sharing with others. It’s just not going anywhere that we haven’t already gone a thousand times before.

                                                                                                                            1. 2

                                                                                                                              It exists now, it will exist in the future, it will always exist.

                                                                                                                              Capitalism is an economic system that was created by people, and put into effect by force. There is nothing inevitable about it and it’s heavily reliant on the societal ideals and values, and seeks to manipulate them through media, and the very language that we use to talk about things, to ensure that it continues.

                                                                                                                              The idea that we cannot build a different economic system, that might or might not involve money, ignores the fact that the dynamics of capitalism are fundamentally just societal agreements and social normals. And that societies have had, and current have, very different variations along that concept. It buys in to the idea that capitalism was a natural development, when it is anything but.

                                                                                                                              In addition, your analysis that the person you are responding to is regurgitating ideas is entirely ignorant of the fact that that is all you are doing. You’re not stating anything new, you’re not even stating factual or historically correct information. You’re regurgitating half-thought ideas that have been passed along to you by your culture that you and others haven’t properly analysed, nor have you clearly read any analyses or critiques of those ideas. The fact that you’re using this to shame someone else is amazing, quite frankly.

                                                                                                                              Please go and read The Origins of Capitalism by Meiksins-Wood. It’s an academic work but it’s very, very good. I’d also recommend Anthony Kenny’s History of Philosophy, purely because you don’t seem to believe that culture as a whole, and the zeitgeist specifically has changed massively over time, and not just through scientific evidence. For example, before JS Mills, morality was thought to be based on an inherent good or bad quality of the act. It was an impossible and clearly wrong idea that it could depend on the context in which an act takes place to determine whether it is a good act or a bad act. If morality itself depends on your societal context, just think about how deeply complex systems depend on specific circumstances and beliefs, and how much they could differ if those beliefs and circumstnaces were changed.

                                                                                                                              1. 1

                                                                                                                                I will consider this. Thank you.

                                                                                                                                I am afraid, however, that I already know where this is going before it even begins. This is going to be about the classic definition of capitalism while I was talking more about something that academically might be called “free trade”

                                                                                                                                I tried to make that clear by my examples. Apologies if I failed. I felt it was important to bring the conversation down to the vernacular and not get too far into semantics, history, and economic theory. But your point is a good one. I’m just not sure it’s relevant given the examples I provided.

                                                                                                                          2. 3

                                                                                                                            This should be posted somewhere on a website of writing to be better preserved than a comment on a story posted Lobsters (not that there’s anything wrong with Lobsters comments …).

                                                                                                                            What you write sinks to the core of my being and the life I’ve carved out for myself in the United States. My friends think I’m crazy for moving to a small town and making due with the (largely) older population that still resides here. Where’s the nightlife? Where’s the easy entertainment?

                                                                                                                            We buy less. We consume less. We build more. My kids are being raised knowing that when you hatch chicks, that one with a deformed leg will die, and it wont be anyone’s fault. But they see the miracle of two dozen other chicks grow into livestock that provides us with eggs. We then turn around and sell the eggs to make a small profit compared to the input of grain. In this way we participate in our own version of capitalism, but we’re not trying to convert two dozen eggs a day into 10,000. I don’t need cancerous growth to show my kids how to live a high quality life.

                                                                                                                            Choosing the slow growth is hard. Choosing to go without is hard. But the choices are there. Everyday we’re making choices that inform the world we live in.

                                                                                                                            Thank you for giving me a train of thought to meditate on.

                                                                                                                            1. 2

                                                                                                                              I 100% agree, The key here is to recognize that people make particular choices and those choices have consequences and if you don’t address our tendency to make bad choices when misinformed or tempted in certain ways then no system you create to address the bad effects of those choices will succeed. Capitalism done wrong will have certain effects. Communism done wrong will have certain effects. Socialism done wrong will have certain effects.

                                                                                                                              The defenders of those systems will all say “Well, that’s because they didn’t do it right.” To which I respond yes, and until you fix their tendency to do them wrong they will continue to do them wrong.

                                                                                                                            2. 9

                                                                                                                              That’s a great point. At the moment, capital is our primary representative of desire/human nature. And of course, this is the great bait-and-switch of capital, which convinces us that it is the real thing we desire; before capital, this “stand-in for desire” was earth itself, and then the body of the despot.

                                                                                                                              It felt more productive to discuss software-under-capitalism than software-under-human-nature, not least because the article is long-winded and heady enough as it is. It’s also easier to take action against something more concrete, even if that concreteness is a trick. Just because things are human constructions or illusions doesn’t make their consequences any less real!

                                                                                                                              1. 20

                                                                                                                                Human beings existed in non-capitalist forms for the vast majority of the time we’ve been on this planet. Non-capitalist cultures are rare and dying these days. But this is due to forms of globalization, notably the history of colonization. It’s not human nature but domination, often violent, that has produced the current state of affairs where capitalism as a cultural form is seen as somehow being due to “human nature”, as if it weren’t in fact a historical production.

                                                                                                                                1. 9

                                                                                                                                  What do you mean by non-capitalist, in this context? I suppose one of the features of modern capitalism – the idea that the pie can grow – is a relatively new one, as is the idea that competition is good for consumers. But usually, people who reject capitalism don’t seem to reject those parts.

                                                                                                                                  However, exchange on a relatively free market, which is the most important part of capitalism, has existed for probably the bulk of human history, and in the cases where it was disallowed, it still stuck around in the form of a black market.

                                                                                                                                  1. 12

                                                                                                                                    Various forms of exchange have existed for a really long time, but the best way to delineate ‘capitalism’ and ‘not-capitalism’ is to look at the general mode of production prevalent in society. In 900 AD, most people worked under personal obligations, i.e. their labour was not sold on the free market, and the point of producing goods wasn’t to satisfy a profit motive, rather to satisfy need and a mesh of social obligations. Only in capitalism is most work organized and most goods produced under this generalized framework of selling them, only there is labour treated as a commodity.

                                                                                                                                    This is a simple, factual difference in how the economy works. You need a name for it, and ‘capitalism’ has always been that name. You can say that ‘capitalism’ actually means ‘exchange, in whatever form, is present’, but most people don’t mean that when they think of capitalism.

                                                                                                                                    1. 3

                                                                                                                                      I’ve seen different people use capitalism very differently, which is why I asked. I find that it’s usually worth stripping the -isms before starting a discussion. It both clarifies the terms, and reduces the emotional attachment to them.

                                                                                                                                      As far as human nature goes – I don’t buy that free trade is human nature, but I do think that wanting to move past a subsistence mode of living is. Then, once there’s largely enough stuff to survive, people start wanting to have different stuff from other people, which caters to their different tastes, and markets are an effective way to achieve that.

                                                                                                                                    2. 3

                                                                                                                                      there are arguments that the root of capitalism is in the neolithic revolution, but again, most of the time humans existed out of this structures and some still do. There are concepts like gift economy, collective property and so on that escape what you’re describing. It’s true that in some contexts people reverted to black markets, but as a reaction to existing economic structures that made it valuable. This is not a universal truth but specific to a (indeed quite broad) subset of economic systems.

                                                                                                                                    3. 2

                                                                                                                                      This is true but doesn’t invalidate the point. Those cultures also had failure modes some of them the same as the current failure modes.

                                                                                                                                    4. 1

                                                                                                                                      Those failure modes manifest in the use and accumulation of Capita

                                                                                                                                      Considering among capital are medicine and other things meant to improve our lives, I have a hard time seeing this as a failure. Rather it turns out most people don’t want to excersize their minds, and would rather spend their days watching cat videos. So that’s what we got.

                                                                                                                                      The failure of humanity seems to be the desire for idleness.

                                                                                                                                      1. 17

                                                                                                                                        Considering among capital are medicine and other things meant to improve our lives, I have a hard time seeing this as a failure.

                                                                                                                                        How, exactly, is medicine about capital? If you remove a capitalist system we don’t suddenly lose the ability to treat people, or develop new medicines. In fact, the current ways of doing both of those things are grossly inefficient, where people who cannot afford to get treatment run the risk of debilitating illness or death, and where research companies do not publish data simply because they invested capital in developing a drug that is, at best, no better than placebo.

                                                                                                                                        Rather it turns out most people don’t want to excersize their minds, and would rather spend their days watching cat videos. So that’s what we got.

                                                                                                                                        That’s not really the case though. The capitalist system itself causes stress on people, especially low-income people (which make up the majority). Not only could most of the work at the moment be done by less people (See: In Praise of Idleness by Bertrand Russell, and Bullshit Jobs by David Graeber), but removing stress from people’s lives allows them the opportunity to grow and focus. The idea that people who aren’t working are inherently a) of less value to society, and b) utterly unproductive, is a fallacy and a product of Religious Dogma (“Idle hands are the Devil’s workshop”). Stress kills creativity, if people didn’t have to struggle to survive (See: literally any UBI study), they not only tend to be more productive, or take valued roles in society that are scarce because they don’t have to work for the means to survive, but also they tend to be more creative. In fact, Eric S. Raymond (For however many his flaws are, and the fact that he is on the opposing side of my argument because of decades of cultural McCarthyism), in one of the essays in The Cathedral and the Bazaar, himself goes over the fact that, once the basic means are sorted, higher wages are not correlated with productivity, the basic measure that the capitalist system has for an individual’s productivity is inherently broken.

                                                                                                                                        Capitalism was a system created and enforced on people by force (As Meiksins-Wood shows in The Origins of Capitalism), it is not a natural system, and has nothing to do with human nature. In fact, it hampers it. Things that people used to do, like giving gifts, being productive, collaboration, etc. are suddenly viewed only through the lens of capitalist exchange, which twists those actions to be solely about capital. Even idleness itself is under the force of capital, people who are throwing up because they are stressed, have even more stress because they feel they are failing themselves for not being able to work! The very act of idleness is now about exchanging economic activity, and about driving the economy. If you look at say, leasure activities in the early 20th century compared to the late 20th century, it goes from “Going to the local club for a round of badminton” to something much, much more focused on consumption, you can see this shift happening in around the 1960s to the 1980s.

                                                                                                                                        Capitalism made it so that, suddenly, the only worth of a human being is for them to produce capital, almost always for other people. Human beings don’t just suddenly stop functioning and become mindless machines because they are outside of capitalism, that in itself is propaganda that has been shown to be false.

                                                                                                                                        We are worth more, we can do more.

                                                                                                                                        1. 4

                                                                                                                                          Things that people used to do, like giving gifts, being productive, collaboration, etc. are suddenly viewed only through the lens of capitalist exchange, which twists those actions to be solely about capital.

                                                                                                                                          They used to do other things before the invention of Capital too, like subjugating others, taking from others by force, killing others. The point I was trying to make is that Capital in and of itself doesn’t cause those failure modes anymore than anything else. It’s just part of who we are. We have failures modes like any other system and attempting to solve problems by blaming them on a tool is failing to recognize the root cause: Human Nature.

                                                                                                                                          1. 4

                                                                                                                                            I mean, that doesn’t really track with the facts. There have been people who were good leaders that led people to believe things that caused them to murder, and kill, and subjugate, but those aren’t necessarily inherent to human nature. Most of those things are believed to be an necessity by the people involved (Zionism, for example was seen as colonialism by the people who created it, but it was justified as an existential necessity, and they wrote entire books outlining their reasons. The cold war was seen as an existential destruction on both sides. Naziism was seen and justified as making the world a better place, free of ‘lesser’ people – My Nan grew up under Nazi Germany, in a reasonably middle class family, he was seen in a positive light because he got rid of unemployment. He also lowered education standards to an abominable level for the women, the amount of things my nan was just completely uneducated on at 87 years of age was astonishing, she didn’t even understand “what held up the planets”), or just fact of the world (look at slavery, justified as being inherently and genetically lesser, and as soon as white folks came across science we invested a lot of money and time into backing that up ideologically).

                                                                                                                                            While there are a handful of killers that kill without motive, most mass killers kill because they believe it will make the world a better place, because of their worldview. The fact that people create intricate justifications for the things that they do – which is well proven through the records we can find going back literally thousands of years, show very clearly, humans aren’t inherently hostile, except when they believe they’re in no other position, or a leader becomes greedy and convinces people that there is no other choice (Or when they don’t have to be convinced, when they’re in a societal position that ensures they will follow the commands).

                                                                                                                                            On the large, modern studies show that humans are naturally cooperative, and not inherently selfish, and there’s around several centuries of anarchist literature where people give more evidence towards that fact, and everything else I’ve outlined above.

                                                                                                                                            1. 5

                                                                                                                                              Zionism, for example was seen as colonialism by the people who created it, but it was justified as an existential necessity, and they wrote entire books outlining their reasons.

                                                                                                                                              It makes me incredibly uncomfortable to see this crop up in an argument about oppressive economic systems. Zionism is a deeply complicated topic that seems to so often collapse into “Jews bad”.

                                                                                                                                              1. 3

                                                                                                                                                I can understand why you feel it’s uncomfortable, I feel the same. However, my point was correct, while Zionism is a complex topic, the founders of the movement explicitly called it colonialism multiple times, see this twitter thread with excerpts from their writing (Which you can stick into Google to pull sources for them, if you don’t believe them):

                                                                                                                                                Jabotinsky, Herzl, Nordau, Ussishkin, and other founders of Zionism clearly stating it’s colonialism

                                                                                                                                                You are right we must not mistake and conflate critique of Zionism, which is a specific political ideology, with hate towards Jewish people, who follow a religious belief and have massively different political tendencies within that belief system, and you are right that there is a lot of overlap between people who critique Zionism, and people who have hatred for Jewish people, which is wildly unfortunate, as they stand in the way of actual critiques of Zionism.

                                                                                                                                                1. 16

                                                                                                                                                  the founders of the movement explicitly called it colonialism multiple times, see this twitter thread with excerpts from their writing (Which you can stick into Google to pull sources for them, if you don’t believe them):

                                                                                                                                                  First, I looked up the source of your linked “quote”. The only places it appears is on antisemitic and anti-Zionist websites. More digging eventually got me to the essay they claim to quote, The Iron Wall, which doesn’t have the quote. Everybody said “it’s in the source!” but nobody actually read the source.

                                                                                                                                                  (It does have deeply troubling anti-Arab statements, which I don’t deny, but the gulf between what it’s saying and what people are saying it’s saying is vast.)

                                                                                                                                                  Second, that’s a bait and switch. You’re conflating colonization as we understand it as an oppressive system with how they used “colonization”, which is literally just “moving to a new land.” You can’t call them the modern interpretation of colonialism because it appears in a text, translated from Russian, from a hundred years ago.

                                                                                                                                                  Third, Zionism isn’t a specific political ideology. It’s a set of similar concepts that form a mishmash of different political ideologies, just like “leftism” doesn’t mean “Leninist.”

                                                                                                                                                  Fourth, there is a lot of conflation between anti-Zionism and antisemitism by intention of anti-Zionists. Look up the history of “Zionology” and the Soviet effort to get Zionism declared a form of racism.

                                                                                                                                                  I’m pretty mad about this because I’ve been challenged on this everybody in “progressive circles”. People have asked me at conferences “what do you think about the Israel-Palestine conflict?” I’ve had to otherwise totally progressive people that no, Israel is not an “apartheid state”, yes, Arabs are allowed to vote, no, Israel didn’t start the Six-Day War. Antisemitism is socially acceptable in leftist circles and saying “I understand why you feel uncomfortable” doesn’t absolve anyone of anything.

                                                                                                                                                  1. 3

                                                                                                                                                    How can I upvote this 1000 times.

                                                                                                                                                    1. 2

                                                                                                                                                      Did you actually do the research? You’re right that the quotes appear on anti-Semitic websites, but this includes the ones where the quotes come from primary sources (Such as diaries written by the quoted leaders, or books written by them), so that doesn’t mean anything whatsoever.

                                                                                                                                                      I referred to the full thread, so let’s go through them and dig up the citations in sequence, as you will see, many of them come from the horses’ mouth:

                                                                                                                                                      1) The second numbered tweet (but the first one with an image and citation) comes from page 7 of “The Case for Palestine: An International Law Perspective”, this in turn, cites the following works for the text highlighted in the twitter post:

                                                                                                                                                      “38. Abdallah Schleifer, The Fall of Jerusalem”, p 23

                                                                                                                                                      Which is a book written by Abdallah Schleifer, born to a secular Jewish family, a “prominent Middle East expert”, and a former member of the US foreign policy research institute.

                                                                                                                                                      “39. Raphael Patai (ed.) The Complete Diaries of Theodor Herzl (1960). p 1194”

                                                                                                                                                      Which is a collection of Theodor Herzl’s diary written by Patai, a Jewish-Hungarian Ethnographer.

                                                                                                                                                      Are you trying to tell me that Patai and Schleifer are Anti-semitic? If that’s the fact, then state it, make your case.

                                                                                                                                                      2) You’re right the second tweet (the one I linked to) comes from The Iron Wall by Jabotinsky. A seemingly trustworthy source I can find here is from en.jabotinsky.org, and it says:

                                                                                                                                                      There can be no voluntary agreement between ourselves and the Palestine Arabs. Not now, nor in the prospective future. I say this with such conviction, not because I want to hurt the moderate Zionists. I do not believe that they will be hurt. Except for those who were born blind, they realised long ago that it is utterly impossible to obtain the voluntary consent of the Palestine Arabs for converting “Palestine” from an Arab country into a country with a Jewish majority.

                                                                                                                                                      My readers have a general idea of the history of colonisation in other countries. I suggest that they consider all the precedents with which they are acquainted, and see whether there is one solitary instance of any colonisation being carried on with the consent of the native population. There is no such precedent. The native populations, civilised or uncivilised, have always stubbornly resisted the colonists, irrespective of whether they were civilised or savage. And it made no difference whatever whether the colonists behaved decently or not. The companions of Cortez and Pizzaro or (as some people will remind us) our own ancestors under Joshua Ben Nun, behaved like brigands; but the Pilgrim Fathers, the first real pioneers of North America, were people of the highest morality, who did not want to do harm to anyone, least of all to the Red Indians, and they honestly believed that there was room enough in the prairies both for the Paleface and the Redskin. Yet the native population fought with the same ferocity against the good colonists as against the bad. Every native population, civilised or not, regards its lands as its national home, of which it is the sole master, and it wants to retain that mastery always; it will refuse to admit not only new masters but, even new partners or collaborators.

                                                                                                                                                      He very clearly likens it to colonialism, through a direct analogy, and from then on I think the variance is one caused by the translation chosen. Whether this one is more true or less true to the words he wrote is something a native reader will have to determine.

                                                                                                                                                      3) The next citation (the 4th twitter post) can be traced to “Zionism and Anti-Semitism”, a book that was written by Nordau and Gottheil, it is a primary source.

                                                                                                                                                      4) The 5th twitter post was by Ussishkin. Ussishkin’s writings are, according to the Jewish Virtual Library recorded in two volumes, neither of which I can find online (I have found previous works via libgen, for example). They are presumably in hebrew, so I wouldn’t be able to read it anyway unfortunately.

                                                                                                                                                      This citation comes from “Expulsion Of The Palestinians” by Masalha, who is a (Palestinian (? Is that the right way to phrase that?)) academic. The book lists in the Bibliography (Sorry if I mistype anything, because I can’t copy and paste this): “See the minutes of his meeting on 24 September 1941. CAB 65/23. His pro-Zionist Secretary for India, Leopold Amery, endorsed the idea; see his letter to Churchill dated 4 October 1941, cited in Nathaniel Katzburg, Mendinlyut Bemavoch: Mendinlyut Britania Beeretz -Yisrael [The British Policy in the Land of Israel 1940-1945] (Jerusalem: 1977), p. 18.”. I will leave it to you to find those.

                                                                                                                                                      5) His sixth tweet makes reference to The Palestine Jewish Colonization Association (wiki), the Jewish Colonial Trust (jewish virtual library), and the Jewish Agency’s Colonization Department (American Jewish Archives).

                                                                                                                                                      Afterword: One must, indeed, wonder if Zionism isn’t Colonialism, why do multiple Zionist leaders proclaim it to be Colonialism, and why do the names of many pro-Zionist organizations explicit contain references to Colonialism?! I don’t see any other explanation other than the Zionists themselves, believed it to be Colonialism.

                                                                                                                                                      That’s a bait and switch. You’re conflating colonization as we understand it as an oppressive system with how they used “colonization”, which is literally just “moving to a new land.” You can’t call them the modern interpretation of colonialism because it appears in a text, translated from Russian, from a hundred years ago.

                                                                                                                                                      But doesn’t Jabotinsky, in the quote above, refer to fighting off existing people? What else is colonialism if not removing people who are already existing in a land, so you can settle there yourself? Also, I think I have a fair grasp of how people from the 1800s in Russia use the word colonialism, I’ve read Trotsky, Lenin, and Marx. All of whom make reference to those terms and use it in the same way we do today. The usage back then was not any different to the one we use now.

                                                                                                                                                      the Soviet effort to get Zionism declared a form of racism.

                                                                                                                                                      Both Lenin and Stalin were loudly outspoken against Anti-Semitism. The Bolsheviks and Mensheviks had a significant proportion of Jewish members, and the monarchy had treated Jewish people abominably. Shorly before the Russian Revolution, fascists (for want of a better term) locked a village full of Jewish people in a church and set it alight, just one of the many horrific incidents to happen. Before the Russian Revolution Jewish people were – quite literally – under attack. One of the few remaining recordings of Lenin is one of him giving a speech against anti-Semitism. There’s a good quote on Wikipedia from Stalin in 1931. And during the war he relocated Jews in areas that were at risk of coming under Nazi control.

                                                                                                                                                      1. 0

                                                                                                                                                        Oh! Hey! What’s this? A Jewish anti-Zionist song??

                                                                                                                                                        And a pro-Soviet anti-Fascist Jewish folk song?

                                                                                                                                                        Maybe it turns out Jewish people are real people and have views all across the Political Spectrum? Hmmm 🤔🤔

                                                                                                                                                      2. 1

                                                                                                                                                        I’d like to point out that the Polish government believed Madagascar was a good option because 1) it removed a population from the countryside, and 2) it extended polish influence as Colonialism. So certain strains of Zionism were in fact colonialist in justification.

                                                                                                                                              2. 1

                                                                                                                                                …himself goes over the fact that, once the basic means are sorted, higher wages are not correlated with productivity, the basic measure that the capitalist system has for an individual’s productivity is inherently broken.

                                                                                                                                                I’d like to read what economists think about this but this sentence is subtly wrong in my opinion.

                                                                                                                                                I think we should start to say that for a lot of positions, an individual’s productivity is awfully hard to measure, and in some cases it’s even hard to define (cf. all the art of counting lines of code). This is always true, for both Marxism, capitalism and whatsoever, right?

                                                                                                                                                Then, in a capitalist system, wages are a statement of the natural outcome of supply and demand, which means that they can vary a lot between companies, positions and locations. In my opinion this is - by design - not a reliable measure of productivity across positions and locations. And for the same position at the same location within the same company it doesn’t work at all if productivity is hard to measure for the position.

                                                                                                                                                In fact I see capitalism as a system where wages are naturally not correlated with productivity. I also think that money can’t really buy happiness so in overall, I don’t care a lot about it.

                                                                                                                                                1. 4

                                                                                                                                                  Right - ‘Productivity’ is not an objective measure, because it’s easy to produce things nobody wants.

                                                                                                                                                  Once upon a time, Capitalism solved that by moving decision-making power closer to the information - but wealth concentration has diluted that advantage to homeopathic levels.

                                                                                                                                                  1. 3

                                                                                                                                                    That’s a fair point! And I’m very likely wrong on that front, given more consideration! The rest of it still stands :)

                                                                                                                                                    1. 1

                                                                                                                                                      I don’t have any arguments against the rest of it, but:

                                                                                                                                                      I also think that money can’t really buy happiness so in overall, I don’t care a lot about it.

                                                                                                                                                      Fundamentally, for anything sub- 30-50k/mo, more money means significant quality of life improvements. Preliminary tests of UBI have shown massive health improvements in low wage populations. Money is the gatekeeper for medical care, for access to basic necessities, and recreational activity. It’s also the gatekeeper for changing jobs, changing your environment, and removing yourself from hostile and abusive scenarios that are damaging to your mental health.

                                                                                                                                                      I think this idea of downplaying that “money can’t buy happiness” is foolish. Nobody has claimed that money is a direct line to happiness, however it’s the main, sometimes only, gatekeeper between us and the solutions to almost all of the material problems that plague pretty much everyone who isn’t earning around or above the aforementioned wage line.

                                                                                                                                                      I know and have heard en-masse of people who have lost their entire lives to work, simply trying to get their children into a better financial situation, so they do not have to know that pain too. I know people in the south of the USA, describe how working constantly and not having time has become so ingrained into their culture that “not having time to see your kids” is an expression of love.

                                                                                                                                                      I know people who have been forced to work for abusive managers, or been forced to live in abusive households, because the cost of moving themselves out of that scenario was ridiculously, ludicrously high, and because they are completely unable to obtain that money, because of their impacted mental health.

                                                                                                                                                      I know people who have died from mental health and physical health problems because they were unable to afford treatment, or who end up living with lifelong injury because they do not have the time to see the doctor, or pay for better ones. And, just to contextualise that, I live in a country where healthcare is free – ideally there shouldn’t be a cost to that, but all of the best doctors

                                                                                                                                                      I know extremely intelligent and smart people who can’t find the time to work on projects that would improve, in a small way, people’s lives, because they wouldn’t be able to make a living off it.

                                                                                                                                                    2. 1

                                                                                                                                                      Do you actually believe that stuff?

                                                                                                                                                      1. 2

                                                                                                                                                        I don’t need to believe it. Read the literature, it’s been very clearly shown.

                                                                                                                                                        1. 0

                                                                                                                                                          The question to be answered is: what is to be done with one’s labor. Capitalism answers that with “it’s to remain with the laborer.” There is no other answer that can be moral, not if one takes as True that people may possess.

                                                                                                                                                          Quite clearly shown is clearly in the eye of the beholder.

                                                                                                                                                          1. 6

                                                                                                                                                            Capitalism’s answer is that labor should typically be rented out to the employer under employment contracts enforced by the state. That’s not exactly the same as “remaining with the laborer.” David Ellerman makes this point quite forcefully.

                                                                                                                                                            1. 1

                                                                                                                                                              It remains with the laborer because they get to see the results of their labor in the form of a paycheck which can be redeemed for others’ labor. Unlike other systems where your needs are taken care of regardless of your value.

                                                                                                                                                              1. 3

                                                                                                                                                                It’s just that the employment contract specifies that everything produced and consumed by the work is the responsibility of the employer, not the employee—so as a coder, everything you make is appropriated by the company.

                                                                                                                                                                If you sold your whole future labor under such conditions it would rightly be considered a version of slavery. But in capitalism we rent labor, we don’t buy it.

                                                                                                                                                            2. 5

                                                                                                                                                              The question to be answered is: what is to be done with one’s labor. Capitalism answers that with “it’s to remain with the laborer.”

                                                                                                                                                              and the laborer has no other choice than giving it away for the least amount of compensation the market allows? like a casino, the market always favours the capital. there may be some irregularity across the different occupations (tech jobs currently have it better than most), but as a whole, those who have the capital decide how much compensation you will get for your work force. and that will always (by definition of the market) the least amount possible to keep the system running.

                                                                                                                                                              1. 1

                                                                                                                                                                and the laborer has no other choice than giving it away for the least amount of compensation the market allows?

                                                                                                                                                                The option always exists to assert the market would pay more, in which case additional compensation is granted, or to work in a different field, or to not work at all, so long as you yourself didn’t steal others’ labor. The capitalist system creates value out of thin air, because one thing the Marxists get right is the value added by a person is far more than their compensation.

                                                                                                                                                                1. 3

                                                                                                                                                                  The option always exists to assert the market would pay more, in which case additional compensation is granted

                                                                                                                                                                  i think that in certain sectors the “prices” for labour are being fixed by the capital at the lowest point possible, most commonly in sectors which don’t require much education. unions are at a point where they are more or less corrupt and are being bought. capitalism is excellent in defending itself :)

                                                                                                                                                                  or to work in a different field, or to not work at all, so long as you yourself didn’t steal others’ labor.

                                                                                                                                                                  i don’t really know what to reply to this? work as something which requires a medium amount of education (x years). so i can choose between not being payed enough for my job or saying “fuck it” and have a severely reduced income in the next y years while being retrained? that’s not really an option, just like “don’t work at all”.

                                                                                                                                                                  1. 1

                                                                                                                                                                    They are always options, and depending on the individual’s circumstances, they may be the right or wrong options. That’s all.

                                                                                                                                                                    1. 4

                                                                                                                                                                      They are always options, and depending on the individual’s circumstances, they may be the right or wrong options. That’s all.

                                                                                                                                                                      i don’t see much of an option in the sense of “things one can choose between”. shitty payment or unemployment is most of the time a straight route to poverty which in turn leads to social and health problems leading to making it difficult being employed again. that some people can pull themselves out of this by their bootstraps doesn’t validate the “you only have to try hard enough” meme.

                                                                                                                                                                      what is lost by making sure people are paid well? bezos n-th billion? what is gained? the possibility of having a non-cutthroat society where it’s members can focus on being social (note the similarity of “social” and “society”) instead of thinking of the best way to get the most money.

                                                                                                                                                                  2. 2

                                                                                                                                                                    or to work in a different field, or to not work at all

                                                                                                                                                                    That isn’t really the case. Many people on low-income jobs, many skilled people forced to work such jobs, are unable to do that.

                                                                                                                                                        2. 4

                                                                                                                                                          I wasn’t implying that using and accumulating capital were instrinsically failure modes. My point was that many of our failure modes manifest in the process of using and accumulating capital. Similarly to the way that they manifest when writing software.

                                                                                                                                                          1. 1

                                                                                                                                                            The failure of humanity seems to be the desire for idleness.

                                                                                                                                                            If anything, I’d put it completely the other way. It is the impossibility of being content, of merely sitting in an empty room doing anything but being with our thoughts (going as far as giving ourselves electric shocks instead of being idle), that pushes ourselves to do anything (be it watching kitten videos, or accumulate useless capital) to push the burden of sentience away.

                                                                                                                                                            1. 1

                                                                                                                                                              the impossibility of being content

                                                                                                                                                              This is how people grow though. We poke and prod and learn. Doing nothing doesn’t necessarily require being content, but it does require that your time be useless to yourself and others. Some people really want to do nothing.

                                                                                                                                                          2. 1

                                                                                                                                                            At it’s crux the issue is human nature. Human nature has a number of failure modes. Those failure modes manifest in the use and accumulation of Capital

                                                                                                                                                            Accumulation of capital is not a failure mode. It is life serving its purpose, which is replication of genes. You are in a better position to do that the more stuff you have.

                                                                                                                                                            If you have financial independence, many people are just going to play video games. They are not gonna become a pianist or a painter. Garbage in, garbage out, as they say. Softwares just empower people to do what they want to do better. And what they want is to be forever distracted.

                                                                                                                                                            1. 4

                                                                                                                                                              You’re going in a decent direction but miss the larger point: evolution optimizes for the population to survive, not individuals. That individuals get rich in this system is almost entirely due to how the economic, financial, and legal systems are constructed. The system also makes unhealthy, imprisons, and/or kills large numbers of people for both random and non-object reasons. That usually works against evolutionary goals.

                                                                                                                                                              There’s other systems where the population as a whole has their needs met, are healthier, get good education, and sometime more time off work for leisurely activities. In well-run socialism, these benefits of their system mean that both the average individual and the population as a whole are more likely to survive and pass on their genes.

                                                                                                                                                              Note: One might also look at the infant mortality rate of each country for this assessment. That’s a bit, too dark a subject for me this early in my morning. Probably others, too. I’ll pass on it for now.

                                                                                                                                                              1. 2

                                                                                                                                                                Well-run socialism is an oxymoron, did you maybe mean to say “social democracy” instead of “socialism”? The former is a way to organise society which has been adopted in some way by most western democracies, including the US - Medicare and Medicaid are examples of social programs which have been voted into being through a democratic process. Socialism is the precursor to communism and has never been shown to lead to anything but societal decline and poverty, often in combination with a stratified society where those who do not support the state in all it does - for better or for worse - are denied basic rights.

                                                                                                                                                                Social democracy is not the same as socialism. The DDR and the Soviet Union were socialist states. The Netherlands, Denmark, Sweden, Norway and Finland (and many more) are social democracies.

                                                                                                                                                                1. 1

                                                                                                                                                                  The Netherlands, Denmark, Sweden, Norway and Finland (and many more) are social democracies.

                                                                                                                                                                  Yeah, that’s what I’m talking about. Three of those were even examples I was ready to give. They just call those socialist where I’m from. The ones you call socialist they call communist. Although I have memory problems, I’d probably still not be sure what term to use given the varying usages of socialist, left, right, etc in my country and outside it.

                                                                                                                                                                  So, looking it up on Wikipedia, it starts with “Social democracy is a political, social and economic philosophy within socialism… “ The linked article on Socialism itself includes my usage of the term. Is Wikipedia inaccurate where the social democracies aren’t in socialism or socialism not having multiple forms which include above countries? If so, it might be worth editing those articles to include the source for that, too.

                                                                                                                                                                  1. 3

                                                                                                                                                                    Well, there is ‘wrong’ and ‘wrong’. Social democracy is an amalgamation of some of the tenets of socialism and those of a democratic society with a market economy. It is an end stage in and of itself - social democracies do not strive after abolishing the market economy - where socialism is a precursor to communism, the ‘dictatorship of the proletariat’ with a socialist party in control of the state. Venezuela is the most recent example of such a state that I know of.

                                                                                                                                                                    Marx and Engels thought the workers would eventually revolt to get a more fair share of the value created by their labour. This is not what happened though, working conditions and rewards were improved in such a way that workers did not rise up in revolt. They voted ‘their’ candidates into power, organised in labour unions and got some of their demands met in this way. Some revolutionary socialists - Lenin being the best-known example - thought this was not enough and, disappointed by the refusal of the workers to revolt stated that the proletariat needed to be guided into the classless communist society through the dictatorship of the proletariat, i.e. a leading class of revolutionary socialists would take power by non-democratic means. It is at this point where socialism and social democracy parted ways around 100 years ago.

                                                                                                                                                                2. 2

                                                                                                                                                                  In well-run socialism,

                                                                                                                                                                  In a well-run utopia, everything is perfect.

                                                                                                                                                                  1. 3

                                                                                                                                                                    Now, you’re just trolling. A number of existing countries have the benefits I describe that increase evolutionary survivability. No need to theorize or bring in utopias.

                                                                                                                                                                    Even in theory, one should expect capitalism and free market might work against evolution because they work against individuals’ health. Companies and workers are always expected to do more for less overtime. That inevitably leads to more stress, less healthy ingredients in food, more toxins in environment, more dying from lack of healthcare, etc.

                                                                                                                                                                    It’s by design. Good news is you can let evolution do its thing and capitalism do its thing. You can be a fan of both. They are seperate for now unless you mean it protects the survival of rich kids’ genes. That might be true but with who knows what consequences.

                                                                                                                                                                    1. 3

                                                                                                                                                                      well, the usa took care that the non dictatorial socialist experiments would fail :)

                                                                                                                                                              2. 1

                                                                                                                                                                lifting off the hallway door and replacing it with a piece of plywood with a cat hole so we can live for ten seconds without the baby trying to eat the cat’s food

                                                                                                                                                                1. 2

                                                                                                                                                                  Stretching it but I like to make Telegram bots. I see it as a framework for making collaborative apps based on messages. You can send GIFs, maps, files, multiple choice keyboards, etc. And you get fast clients for mobile that a lot of people already have installed. All you need to do is some HTTP POST requests to api.telegram.org.

                                                                                                                                                                  1. 2

                                                                                                                                                                    I use a dark theme at night and a light theme in the day. This seems harmonious to me, at night I just crave a dark theme. And I do a lot of night shift coding, usually from 2 AM to 6 AM, because that’s when I work the best and it works in our family situation. I also use huge fonts.

                                                                                                                                                                    I don’t trust that usability studies have any relevance to my idiosyncratic habits and preferences…

                                                                                                                                                                    1. 3

                                                                                                                                                                      Maybe instead of a new programming language, you could learn a specification language that will be useful for programming in any language!

                                                                                                                                                                      TLA+ is probably a good choice. It is a static analyzer! And there are resources for beginners to learn: @hwayne’s Practical TLA+ and Leslie Lamport’s own video series and free books on his website.

                                                                                                                                                                      1. 8

                                                                                                                                                                        I became sick of reinstalling my OS over and over again, and it was clear that even tools like Ansible would not cut it. So I installed NixOS three years ago and never looked back.

                                                                                                                                                                        1. 3

                                                                                                                                                                          Yep, running the same NixOS installation since 2015, still as fresh as ever, can’t imagine wanting to reinstall.