• 4 Posts
  • 121 Comments
Joined 1 year ago
cake
Cake day: July 8th, 2023

help-circle
  • This could actually a pretty big deal

    1. The Eclipse foundation has been making alternatives to VS Code’s “killer apps” (Docker, Python, Go, C++, SSH, Live share, etc). AKA the closed source ones exclusive to VS Code offical that make all VS Code forks a huge downgrade. The Eclipse foundation is also running the extension store that powers VS Codium.
    2. “why not just use VS Codium?” (With the killer extensions made by Eclipse)
      • VS Codium is great, but because of manpower limits, they always have to be “downstream” of VS Code. They can’t rewrite any of the core systems.
      • As someone who contributes to VS Code, and loves VS Codium, many issues I have with VS Code have been open on github for +5 years, with hundreds of comments and thumbs-ups. We can’t even sort the file explorer view by last-edited and folders-first (but we can do folders-first alphabetical). Thats been open since 2020.
      • Theia looks like it could finally be the hard fork I’ve been waiting for. A hackable editor, trying to be open source, where all my extensions work, and the community can actually make a PR, get it merged, and extensions are not excessively sandboxed.
      • Will it be that? Only time will tell, but the Eclipse foundation has a pretty good record. They’re definitely prepared for long term support.


  • Same haha.

    I’ve already started it twice for lemmy, but didn’t put in heavy effort yet. I’ve got a wrapper for nix that helps with common issues, but its on the messy side.

    There are so many small GUI apps I want to make but I refuse until I can get Tauri to build an appimage and macos app within nix. It was more than a year ago since I put a lot of effort on that though. If you’ve got any tips/pointers or examples for tauri I’d be happy to hear them.


  • Sadly it still causes system instability even if you NEVER need the feature.

    You might not need numpy at all, but Pandas needs numpy and Opencv needs numpy. Sometimes pandas needs one version and Opencv needs a different version. Well… python only allows one global verison of numpy, so pandas and opencv fight over which one they want installed, and the looser is forced to use a numpy they were not designed/tested for. Upgrading pandas might also upgrade numpy and break opencv. That causes system instability.

    Stable systems like cargo coupld upgrade pandas, have pandas use numpy 1.29 without touching/breaking opencv (opencv would still importing/using using numpy 1.19 or whatever). That stability is only possible if the system is capable of having two versions of the same dependency at the same time.


  • And FYI to OP, if you can’t install two versions of the same library at the same time (ex: numpy 1.25 and numpy 1.19) then the answer to “has its dependencies under control?” is generally “no”.

    • Deno (successor to NodeJS) is “yes” by default, and has very very few exceptions
    • Rust can by default, and has few but notable/relevant exceptions
    • Python (without venv) cannot (even with venv, each project can be different, but 1 project still can’t reliably have two versions of numpy)
    • NodeJS can, but it was kind of an afterthought, and it has tons modules that are notable exceptions


  • jeffhykin@lemm.eetoProgramming@programming.devIncus and programming
    link
    fedilink
    arrow-up
    1
    arrow-down
    2
    ·
    edit-2
    4 months ago

    The more reliable/reproducible the container is the more pain/effort it is to setup. If you don’t need reliability, then you don’t need containers.

    • If you want unbeatable reliability, use nix.
    • If you want better-than-nothing use venv/anaconda envs (one or the other, not both)
    • If you want the most reliability-per-effort and don’t care about performance, use distrobox





  • Also

    I’ve exhausted every EXE-generating option I could find [for python]

    Unfortunately software is one giant mess right now. You’d think things like compiling to an EXE for python would be standard. They’re not. One day, maybe 15 years from now, we will have Nix be user friendly, a single line installer for everything, and have it all “just work”. But until then, almost everything is hacked together.

    Overview of (basically) all GUI systems

    I believe Flutter, React Native, and Android studio are the only major ones I don’t have experience with.

    EDIT! (2024-4-30) .NET Avalonia seems like a great modern option that I have not gotten to try. Its C# and fully cross platform. It could be a real game changer compared to the options I’ve listed below

    • Yes as far as I know theres no good exe maker for python. Python without dependencies (or async) is great, a nice little scripting lang for prototyping or data analysis. Python with dependencies is terrible, truly awful for packaged user-applications.
    • C++ / C are and effectively will always be miserable IMO. You’ll basically never be able to automate it without nix. Make, cmake, autoconf, pkg-tools, ant, etc they’re all a mess. For example, biggest blocker to python packaging is that many python packages are wrappers around C/C++ packages. The most annoying thing about one of the tools I’m about to mention (electron) are the dependencies that secretely use C++.
    • The most modern, consistent, and cross platform graphical systems right now are Electron and Tauri, which are literally browsers with URL bar/buttons removed. Electron is what Discord, Spotify, and VS Code use. Its bulky but theres a lot of support/tutorials. Tauri is the new, faster/cleaner kid on the block and uses the Rust language, which has good dependency management. But Tauri doesn’t have the tutorials or ecosystem yet. Also Rust is a very hard language. For both you’ll need to learn Javascript/HTML/CSS, which is probably good. But you’ll also need the terrible npm ecosystem, and get introduced to javascript frameworks which seem great until theyre not. That said, basically every cross platform not-browser GUI I know of (JavaFX, QT, TCL/TK, WxWidgets, FLTK) has exactly the miserable experience you’re getting; lots of dependency hedaches, and weird graphical differences between operating systems. Also that list is in order, with FLTK being untouchable garbage, and JavaFX being the least-bad in my experience.
    • Even if you’re okay with using a broswer, (which solves lots of dependency/setup problems, and is the most useful/flexible UI system I’ve used) it still has stupid API problems because HTML was originally made to display documents (like microsoft word documents). It wasn’t meant to be a full blown UI system; it just became that over time. Stuff like styles and positioning in HTML has edgecases, like “fixed” meaning absolute and “absolute” actually meanting “relative to parent” and “relative” meaning “relative to where the element would normally be”.
    • Unity game dev (uses C#, which is similar to Java, but better IMO) might actually be worth looking into for your case. First check the unity API’s for your images and GPS tasks. The good news is they support packaging up applications for every OS. The bad news is you can’t automate the setup because its proprietary. The (very good) open source alternative is Godot.
    • The final alternative is, just don’t go cross platform. This is the only not-mess, not hacky, intentionally-designed toolset approach I know of. MacOS has Swift and XCode, Microsoft has Visual Studio and C#. Neither are great but they’re both the “this is how we expect you to do it” approches. You might be able to adapt these to other platforms (swift has been gaining some cross platform support and the .net runtime for C# can be cross platform).

    My perfect setup would be Tauri (with all security disabled), with Deno accessible on the front end, all installed/setup by Nix. But alas, that doesnt exist yet. Even with +3 years of nix experience I can’t even get Tauri running in Nix.


  • I’d like directions on how to set up a software project with dependencies, so that future contributors can pitch in with the least amount of set-up required when they clone the repo

    Unforunately that kind of task, with our current tools, is not a junior level task. I have worked on automating project setups for almost a decade; creating a single command that is cross platform install of all dependencies, project ENV setup, and in a way that doesn’t break the users existing system(s), or causes the project to bitrot. The only real way at the moment is through Nix (nixpkgs), which is unfortunate because Nix is very difficult to setup and use. If you start a small project in nix its not too bad, but adapting an existing project often is, especially anything with graphical tooling.

    I made Deno gulliotine to help with first step of cross-platform setup, but once the setup begins to install packages/languages it all needs to be done with nix to be reliable.

    Also FLTK is miserable. I’m not a huge fan of QT, but it is at least definitively better than FLTK. Wx Python is also miserable, avoid it like the plague.



  • Ryan Dhal, the creator of node, litterally saw the npm problem(s) before incidents like this happened, and created Deno to fix his mistakes. And fix them he did! The Deno import system is incredible. Its basically the only reason I use deno. You can just import URLs directly, the deno vendors (aka caches) them. Deno has an equivlent to npm.org (Deno.land/x) but anyone can import straight from github, or make their npm.org equivlent, or import from their own private server. So if a company wants reliability, they can mirror deno.land while also avoiding unpublishing.




  • I disagree slightly, but only with his level of cynicism. I agree, we see the “peak diskwasher” problem everywhere. And I agree with his conclusion. But I feel he glossed over that, well, people still need dishwashers. Growth might be impossible, but a steady and “boring” amount of profit should still be possible selling plain-ole-dishwashers. Yet … for some reason, we don’t see that.

    Instead companies throw everything into growth and we get the retarded bluetooth enabled dishwasher problem everywhere, and I’d like to know more about why.