Searching txt.sour.is

Twts matching #programming
Sort by: Newest, Oldest, Most Relevant
In-reply-to » There are no really good GUI toolkits for Linux, are there?

FTR, I see one (two) issues with PyQt6, sadly:

  1. The PyQt6 docs appear to be mostly auto-generated from the C++ docs. And they contain many errors or broken examples (due to the auto-conversion). I found this relatively unpleasent to work with.
  2. (Until Python finally gets rid of the Global Interpreter Lock properly, it’s not really suited for GUI programs anyway – in my opinion. You can’t offload anything to a second thread, because the whole program is still single-threaded. This would have made my fractal rendering program impossible, for example.)

​ Read More
In-reply-to » There are no really good GUI toolkits for Linux, are there?

@prologic@twtxt.net Hm, same startup delay. (Go is not an option for me anyway.)

It’s hard to tell why all this is so slow. Maybe in this particular case it has something to do with fonts: strace shows the program loading the fontconfig configs several times, and that takes up a bulk of the startup time. đŸ€” (Qt6 or Java don’t do that, but they’re still slow to start up – for other reasons, apparently.)

To be fair, it’s “just” the initial program startup (with warm I/O caches). Once it’s running, it’s fine. All toolkits I’ve tried are. But I don’t want to accept such delays, not in the year 2025. 😅 Imagine every terminal window needing half a second to appear on the screen 
 nah, man.

​ Read More
In-reply-to » There are no really good GUI toolkits for Linux, are there?

Be it Java with Swing or PyQt6, it takes ~300 ms until a basic window with a treeview and a listbox appears. That is a very noticeable delay.

Is it unrealistic to expect faster startup times these days? đŸ€”

Once the program is running, a new second window (in the same process) appears very quickly. So it’s all just the initialization stuff that takes so long. I could, of course, do what “fat” programs have done for ages: Pre-launch the process during boot, windowless. But I was hoping that this wasn’t needed. 😞 (And it’s a bad model anyway. When the main process crashes, all windows crash with it.)

​ Read More
In-reply-to » @bender Thanks for this illustration, it completely “misunderstood” everything I wrote and confidently spat out garbage. 👌

@prologic@twtxt.net Let’s go through it one by one. Here’s a wall of text that took me over 1.5 hours to write.

The criticism of AI as untrustworthy is a problem of misapplication, not capability.

This section says AI should not be treated as an authority. This is actually just what I said, except the AI phrased/framed it like it was a counter-argument.

The AI also said that users must develop “AI literacy”, again phrasing/framing it like a counter-argument. Well, that is also just what I said. I said you should treat AI output like a random blog and you should verify the sources, yadda yadda. That is “AI literacy”, isn’t it?

My text went one step further, though: I said that when you take this requirement of “AI literacy” into account, you basically end up with a fancy search engine, with extra overhead that costs time. The AI missed/ignored this in its reply.

Okay, so, the AI also said that you should use AI tools just for drafting and brainstorming. Granted, a very rough draft of something will probably be doable. But then you have to diligently verify every little detail of this draft – okay, fine, a draft is a draft, it’s fine if it contains errors. The thing is, though, that you really must do this verification. And I claim that many people will not do it, because AI outputs look sooooo convincing, they don’t feel like a draft that needs editing.

Can you, as an expert, still use an AI draft as a basis/foundation? Yeah, probably. But here’s the kicker: You did not create that draft. You were not involved in the “thought process” behind it. When you, a human being, make a draft, you often think something like: “Okay, I want to draw a picture of a landscape and there’s going to be a little house, but for now, I’ll just put in a rough sketch of the house and add the details later.” You are aware of what you left out. When the AI did the draft, you are not aware of what’s missing – even more so when every AI output already looks like a final product. For me, personally, this makes it much harder and slower to verify such a draft, and I mentioned this in my text.

Skill Erosion vs. Skill Evolution

You, @prologic@twtxt.net, also mentioned this in your car tyre example.

In my text, I gave two analogies: The gym analogy and the Google Translate analogy. Your car tyre example falls in the same category, but Gemini’s calculator example is different (and, again, gaslight-y, see below).

What I meant in my text: A person wants to be a programmer. To me, a programmer is a person who writes code, understands code, maintains code, writes documentation, and so on. In your example, a person who changes a car tyre would be a mechanic. Now, if you use AI to write the code and documentation for you, are you still a programmer? If you have no understanding of said code, are you a programmer? A person who does not know how to change a car tyre, is that still a mechanic?

No, you’re something else. You should not be hired as a programmer or a mechanic.

Yes, that is “skill evolution” – which is pretty much my point! But the AI framed it like a counter-argument. It didn’t understand my text.

(But what if that’s our future? What if all programming will look like that in some years? I claim: It’s not possible. If you don’t know how to program, then you don’t know how to read/understand code written by an AI. You are something else, but you’re not a programmer. It might be valid to be something else – but that wasn’t my point, my point was that you’re not a bloody programmer.)

Gemini’s calculator example is garbage, I think. Crunching numbers and doing mathematics (i.e., “complex problem-solving”) are two different things. Just because you now have a calculator, doesn’t mean it’ll free you up to do mathematical proofs or whatever.

What would have worked is this: Let’s say you’re an accountant and you sum up spendings. Without a calculator, this takes a lot of time and is error prone. But when you have one, you can work faster. But once again, there’s a little gaslight-y detail: A calculator is correct. Yes, it could have “bugs” (hello Intel FDIV), but its design actually properly calculates numbers. AI, on the other hand, does not understand a thing (our current AI, that is), it’s just a statistical model. So, this modified example (“accountant with a calculator”) would actually have to be phrased like this: Suppose there’s an accountant and you give her a magic box that spits out the correct result in, what, I don’t know, 70-90% of the time. The accountant couldn’t rely on this box now, could she? She’d either have to double-check everything or accept possibly wrong results. And that is how I feel like when I work with AI tools.

Gemini has no idea that its calculator example doesn’t make sense. It just spits out some generic “argument” that it picked up on some website.

3. The Technical and Legal Perspective (Scraping and Copyright)

The AI makes two points here. The first one, I might actually agree with (“bad bot behavior is not the fault of AI itself”).

The second point is, once again, gaslighting, because it is phrased/framed like a counter-argument. It implies that I said something which I didn’t. Like the AI, I said that you would have to adjust the copyright law! At the same time, the AI answer didn’t even question whether it’s okay to break the current law or not. It just said “lol yeah, change the laws”. (I wonder in what way the laws would have to be changed in the AI’s “opinion”, because some of these changes could kill some business opportunities – or the laws would have to have special AI clauses that only benefit the AI techbros. But I digress, that wasn’t part of Gemini’s answer.)

tl;dr

Except for one point, I don’t accept any of Gemini’s “criticism”. It didn’t pick up on lots of details, ignored arguments, and I can just instinctively tell that this thing does not understand anything it wrote (which is correct, it’s just a statistical model).

And it framed everything like a counter-argument, while actually repeating what I said. That’s gaslighting: When Alice says “the sky is blue” and Bob replies with “why do you say the sky is purple?!”

But it sure looks convincing, doesn’t it?

Never again

This took so much of my time. I won’t do this again. 😂

​ Read More

Java’s Swing is allegedly in “maintenance mode”, so I doubt it’s a good idea to use it for new programs. For example, I very much doubt that it will ever support Wayland.

The replacement is supposed to be JavaFX, but that’s not included in JREs – anymore! It used to be, now it’s not, even though it’s well over 15 years old now.

This whole thing (“Java GUIs”) appears to have stagnated a lot. Probably because everything is web stuff these days 


https://www.oracle.com/java/technologies/javafx/faq-javafx.html#6

​ Read More
In-reply-to » @lyse

@movq@www.uninformativ.de Uh, that actually looks not that terrible. Somehow, I remember Swing GUIs being way uglier.

As for Visual Basic, I only had to use VBA once in my life. That was in the beginning of my career when I inherited a project from a leaving coworker. Fuck me, was that awful. Just alone the damn compiler error dialog box popping up in my face all the time while editing and the compiler already trying to parse the unfinished and hence of course uncompilable code. Boy, that left a lasting impression on me. I ported everything to Java very quickly. Luckily, the code base wasn’t all that large at that point in time. I had to add a bunch of new features after that, so I was very glad that I convinced my workmate/project manager to do that first. We didn’t even need a GUI, the button in Excel was transformed to a command line program that just generated the large file.

But I cannot comment on the VB GUI designer, I never used that. Your screenshot looks very similar to the Delphi one, though. Only towards the end of my Delphi days I found out about the possibility to make the widgets snap to window edges and corners (I don’t remember how that was called), so that resizing the windows was actually possible without messing up their entire contents.

Switching to Linux, Delphi wasn’t an option anymore. For some reason I couldn’t use Kylix. Maybe it was already dead by the time I changed OSes. Or I couldn’t get it to run. I just don’t remember. I just recall that the unavailability of Delphi was the reason it took me a while to actually settle on Linux. I then fully switched to Java. The GridBagLayout was my absolutely favorite Swing layout manager. I reckon I used it 98% of the time, because it was so powerful and made the windows resize properly, just as I had learned to do in Delphi shortly before.

Up until discovering Swing, I used Java’s AWT for a short amount of time. That was very limited I think and I hit the limits fairly quickly. Later at uni, we had one project making use of SWT. Didn’t convince me either. I could be wrong, but I think there was also a SWT GUI designer plugin for Eclipse. If there really was, that one wasn’t in the same street as Delphi’s (there must be a reason I forgot about it ;-)).

​ Read More
In-reply-to » And maybe I should go back to using GUI designers. Haven’t used those since the Visual Basic days. đŸ€” It wasn’t pretty, but you got results very quickly and efficiently.

@lyse@lyse.isobeef.org

The one for Delphi was quite good.

It was! I didn’t use Delphi for long, though. Dunno why, I always gravitated towards Visual Basic back then. 😅

These days I don’t deal with GUI programming anymore.

I also avoid it when possible, because 
 it’s exhausting, because 
 the tools that I have/know are “subpar”. Doing anything regarding GUIs always feels like a chore. That wasn’t the case in the VB days.

Well, I made this in ~2009 with Java/Swing and it was pretty nice to work with, custom widgets and all:

https://movq.de/v/de26d5edb3/s.png

I wouldn’t dare doing this with GTK.

​ Read More
In-reply-to » And maybe I should go back to using GUI designers. Haven’t used those since the Visual Basic days. đŸ€” It wasn’t pretty, but you got results very quickly and efficiently.

@movq@www.uninformativ.de The one for Delphi was quite good. But JCreator (I don’t remember exactly) was awful and I never looked back to GUI designers. Always layed out the GUI by hand in code myself since then. These days I don’t deal with GUI programming anymore.

​ Read More

Oregon State University Teaches “White Rage” as Computer Science
OSU’s Computer Science program — which had a $1 Million Dollar grant for “Gender-Inclusive Open Source” — teaches about “White Supremacy” and “Reparations” instead of programming. ⌘ Read more

​ Read More
In-reply-to » Well, it sure has been a while since I last posted here. Just up late doing yet another Linux installation. Debian turned out to be about as stable as a plutonium Jenga tower, and Alpine refused to boot, so I gave it the boot. Here's to hoping that Arch fares better. Oddly, I've always found Arch to be considerably more stable than other distros...

@dce@hashnix.club Arch is the most stress-free OS I’ve ever run (I last reinstalled it 14 years ago, only rolling updates since then) – but to be honest, I sometimes wonder what role my general choice of software plays. I mostly run minimalistic software or programs that I wrote myself. I guess that greatly reduces the chance of breakage. đŸ€”

​ Read More

It happened.

“Can you help me debug this program? I vibe coded it and I have no idea what’s going on. I had no choice – learning this new language and frameworks would have taken ages, and I have severe time constraints.”

Did I say “no”? Of course not, I’m a “nice guy”. So I’m at fault as well, because I endorsed this whole thing. The other guy is also guilty, because he didn’t communicate clearly to his boss what can be done and how much time it takes. And the boss and his bosses are guilty a lot, because they’re all pushing for “AI”.

The end result is garbage software.

This particular project is still relatively small, so it might be okay at the moment. But normalizing this will yield nothing but garbage. And actually, especially if this small project works out fine, this contributes to the shittiness because management will interpret this as “hey, AI works”, so they will keep asking for it in future projects.

How utterly frustrating. This is not what I want to do every day from now on.

​ Read More

[$] Gccrs after libcore
Despite its increasing popularity, the Rust programming language is still
supported by a single compiler, the LLVM-based rustc. At the 2025 GNU Tools\‹Cauldron, Pierre-Emmanuel Patry said that a lot of people are waiting
for a GCC-based Rust compiler before jumping into the language. Patry, who
is working on just that compiler (known as “gccrs”), provided an update on
the status of that project and what is coming next. ⌘ Read more

​ Read More

Shutdown Threatens Food Aid Program Relied on By Millions of Families
Associated Press Reporters,    -  MedPage Today | Associated Press

_Stephan: Trump is a psychopath, and so are a number of his vassals like Stephen Miller. They demonstrate their mental illness every day, and it just gets nastier. They obviously care nothing for the wellbeing of American families as this report details. And, meanwhile, the Republican Congressmembers just docilely watch 
 ⌘ Read more

​ Read More

New program allows parents of kids with complex needs to take a break
An Australian-first pilot program gets underway in WA in the hope of not only giving the parents of children with complex needs a break, but helping them navigate the maze of different support systems. ⌘ Read more

​ Read More

Wheat diversity discovery could provide an urgently-needed solution to global food security
Wheat has a very large and complex genome. Researchers have found that different varieties can use their genes in different ways. By studying RNA—the molecules that carry out instructions from DNA—researchers can see which genes are active and when. By mapping this gene activity for the first time, researchers are able to accelerate international wheat breeding programs, developing new varieties of 
 ⌘ Read more

​ Read More
In-reply-to » @lyse Xfce is nice, but it’s also mostly GTK. I don’t really know the answer yet. For now, I’ll just avoid anything that uses GTK4.

@movq@www.uninformativ.de I never programmed with Tkinter myself and it’s been ages that I ran a program which used it. I always thought that it looks awful. But maybe there are nicer themes these days. I just wanted to give the demo python3 -m tkinter a try, but this module doesn’t exist. I was always under the wrong impression that Tkinter is bundled with Python.

​ Read More
In-reply-to » It’s time to say goodbye to the GTK world.

@lyse@lyse.isobeef.org Xfce is nice, but it’s also mostly GTK. I don’t really know the answer yet. For now, I’ll just avoid anything that uses GTK4.

For my own programs, I might have a closer look at Tkinter. I was complaining recently that I couldn’t find a good file manager, so it might be an interesting excercise to write one in Python+Tkinter. đŸ€” (Or maybe that’s too much work, I don’t know yet.)

​ Read More

2 Ways to Install Homebrew in MacOS Tahoe
Homebrew is a powerful command line package manager that allows you to easily install, update, and manage popular command line programs and tools, as well as traditional graphical apps with cask (and third party tools like Applite help you manage cask through the GUI too). It’s a popular tool with advanced Mac users and those 
 Read More ⌘ Read more

​ Read More

Spec-driven development: Using Markdown as a programming language when building with AI
I coded my latest app entirely in Markdown and let GitHub Copilot compile it into Go. This resulted in cleaner specs, faster iteration, and no more context loss. ✹

The post [Spec-driven development: Using Markdown as a programming language when building with AI](https://github.blog/ai-and-ml/generative-ai/spec-driven-development-using-markdown-as-a-p 
 ⌘ Read more

​ Read More

Tiny RISC-V Development Board with WCH CH32V317WCU6 Available from $6.80
The nanoCH32V317 is a compact development board created by MuseLab to simplify prototyping and embedded system development. It integrates USB connectivity, Ethernet support, and a straightforward programming interface through USB Type-C, providing an accessible platform for engineers and hobbyists working with RISC-V microcontrollers. The board is powered by the WCH CH32V317WCU6, a RISC-V microcontro 
 ⌘ Read more

​ Read More

First Beta of iOS 26.1, MacOS Tahoe 26.1 is Available for Testing
Apple has issued the first beta versions of iOS 26.1, MacOS Tahoe 26.1, iPadOS 26.1, and the rest of the OS 26 suite. The first betas are available for any user registered in the developer beta program, and soon after for public beta testers too. It’s not entirely clear what the focus of iOS 26.1 
 [Read More](https://osxdaily.com/2025/09/22/first-beta-of-ios-26-1-macos-tahoe-26-1-is-available-for-testin 
 ⌘ Read more

​ Read More

This thing about making software run on other people’s computers can be pretty hard!

No wonder I think I’ve heard this is one of the things that distinguishes professional software development from [my preferred domain of] things such as “end-user programming” etc.

The problem is that when you start sharing code in the context of a FLOSS project you almost immediately get enmeshed in concerns about packaging and how other people will install stuff, when sometimes you just don’t want to be a professional software developer! 😿

I’m always borrowing terms (learning ideas) from @lr like: incidental complexity. I hate incidental complexity or maybe I just fear incidental complexity. Can we escape incidental complexity? I guess not.

​ Read More

«Welcome to the #AutomatingGIS processes course! Through interactive lessons and hands-on exercises, this course introduces you to #GeographicDataAnalysis using the #Python programming language. If you are new to Python, we recommend you first start with the Geo-Python course (geo-python.readthedocs.io) before diving into using it for GIS analyses in this course.

Geo-Python and Automating GIS Processes (‘#AutoGIS’) have been developed by the Department of Geosciences and Geography at the University of Helsinki, Finland. The course has been planned and organized by the #DigitalGeographyLab. The teaching materials are openly accessible for anyone interested in learning.»

https://autogis-site.readthedocs.io/en/latest/

#GIS #geoPython #geopandas #shapely #osmnx #networkx

​ Read More

«Welcome to the #AutomatingGIS processes course! Through interactive lessons and hands-on exercises, this course introduces you to #GeographicDataAnalysis using the #Python programming language. If you are new to Python, we recommend you first start with the Geo-Python course (geo-python.readthedocs.io) before diving into using it for GIS analyses in this course.

Geo-Python and Automating GIS Processes (‘#AutoGIS’) have been developed by the Department of Geosciences and Geography at the University of Helsinki, Finland. The course has been planned and organized by the #DigitalGeographyLab. The teaching materials are openly accessible for anyone interested in learning.»

https://autogis-site.readthedocs.io/en/latest/

(via Paul Walter no linkedin)

#GIS #geoPython #geopandas #shapely #osmnx #networkx

​ Read More

«  It all went well until 1980 or so, when Ronald Reagan appointed a new head of the EPA. The lady didn’t like her stationery we had designed and with a simple “I want my daisy back” undermined the overall graphic system. If the Queen doesn’t like it, we don’t like it became the attitude, and the program began to crumble. The old logo was fully reinstated and the graphic system was abandoned. A decade later, nobody at the EPA could find a copy of the Graphic Standards System, except a bunch of legalese that you will find on its website.

I’m a fan of the EPA and all its efforts and hope that we helped in some small way for this agency to communicate within itself, to other government agencies, and with the American people. I’m very grateful and appreciative that Jesse Reed and Hamish Smyth of Standards Manual, and Julie Anixter of AIGA, brought this document to life again. Have fun revisiting.»
(from the introduction by Steff GeissbĂŒhler)

​ Read More
In-reply-to » Good morning. Driving the dot matrix printer from my little real-mode toy OS. đŸ–šïž

@lyse@lyse.isobeef.org @dce@hashnix.club It’s pretty cool, I won’t argue that, but also really simple, to be completely honest. 😅 The BIOS already provides all you need to send data to the printer:

https://helppc.netcore2k.net/interrupt/bios-printer-services

The BIOS actually does provide a great deal of things, which, to me, was one of the most surprising learnings of this project (the project of writing a little 16-bit real-mode OS, that is). It often doesn’t feel like I was writing an operating system – it felt more like writing a normal program that just uses BIOS calls like we would use syscalls these days.

(I’ve also read a lot of warnings, like “don’t use the BIOS for this or that”. Mostly because it tends to be very slow.)

​ Read More

We use all the Microsoft programs at work - Teams and Outlook especially.

After all kinds of technical problems with Teams, that sometimes go unresolved for over a year, Microsoft shifted their priorities away from fixing things and towards adding an annoying AI Copilot button, that just takes up space and all it does, is loads the website in Teams, so I disabled it. Soon they just add it back, but in a different row of icons, therefore it’s now a different button, you have to disable (I think they added yet another one, to the Teams, on my work phone and I had to disabled that too). Not too long after, the desktop one just enabled itself, because of “an error” and I can disable it, but doing so activates a popup, that begs you to turn it back on, every once in a while. You can’t disable the popup and can only click “Yes” or “Not now” on it. I still keep it disabled, out of principle, but yesterday I noticed yet another Copilot button, this time in the top right corner of my Outlook and this one cannot be disabled, on the business version of Outlook and even on the personal one, it’s only possible to do it through hidden privacy settings, by prohibiting the program from connecting to Microsoft servers, for extra “features”.

There’s people complaining about it online, so it’s clear nobody really wants it, but at this point Microsofts position is that you will have at least one useless AI button on your screen, at any given time, and you will be happy. And yes, their AI sucks and if I absolutely have to use AI for something, there’s already 2 better options, we have access to, at work.

​ Read More

** To the surprise of literally no one, I’m working on implementing a programming language all my own **
Inspired by conversation at a recent Future of Coding event, I decided I’d write up a little something about the programming language I’ve been working on (for what feels like forever) before I’ve gotten it to a totally shareable state. I have a working interpreter that I’m pretty pleased with, but I don’t yet have an interact 
 ⌘ Read more

​ Read More
In-reply-to » Sooooooooo, things happened, and I now have a dot matrix printer again. 😍😂

This is why I love tech from that era.

Write bytes to a parallel port and stuff happens. If it’s just ASCII bytes, then it will print ASCII text. Even the simplest programs can use a printer this way.

With a little bit of ESC/P, you can print images and other fancy stuff. That’s what I did this morning – never worked with ESC/P before, now I can print images. It’s not that hard.

Hayes-compatible modems are similar: Write some AT commands to the serial port and the modem does things. This isn’t even arcane knowledge, it’s explained in the printed manual.

Maybe I’m wearing rose-tinted glasses here, but I think with all this old stuff, you get useful results very quickly and the manuals are usually actually helpful. It’s so much easier to get started and to use this hardware to the full extent. Much less complexity than what we have today, not a ton of libraries and dependencies and SDKs and cloud services and what not.

https://movq.de/v/4bd16cb3c7/tux1.jpg

https://movq.de/v/4bd16cb3c7/tux2.jpg

​ Read More
In-reply-to » After around 3 years, I managed to make my "smallest recognizable canine", even smaller. So here's the all new, smallest recognizable canine 2.0: Media

@thecanine@twtxt.net Wow. I’m not an artist in any way, but I have tried to make icons for programs or fonts every now and then. Making something that is still recognizable at so few pixels is hard. Hats off!

​ Read More

Updating my #Processing + #Python tools table:

https://github.com/villares/Resources-for-teaching-programming/blob/main/README.md#processing–python-tools-table

After some years, things changed and my opinions changed a bit too:

  • #py5 is going supper strong and the “new snake_case names” are not an issue for me anymore. I used to worry a lot about all the Processing Python mode examples and teaching materials out there, and some of my own, with “CamelCase Processing names” I’m not worried at all about it anymore!

  • For the record, Processing Python mode is just a legacy thing, no one should start anything with it.

  • The great pure Python Processing implementation project #p5py seems stalled, latest release in Dec. 2023 :((( Advancing it was always going to be an uphill battle


  • The unrelated Brython based site p5py.com seems to be gone, so I removed it from the table.

  • I added a link to my own #pyp5js hack py5pjs/py5mode because this is what I’m using most nowadays.

​ Read More

Updating my #Processing + #Python tools table:

https://github.com/villares/Resources-for-teaching-programming/blob/main/README.md#processing–python-tools-table

After some years, things changed and my opinions changed a bit too:

  • #py5 is going super strong and the “new snake_case names” are not an issue for me anymore. I used to worry a lot about all the Processing Python mode examples and teaching materials out there, and some of my own, with “CamelCase Processing names” I’m not worried at all about it anymore!

  • For the record, Processing Python mode is just a legacy thing, no one should start anything with it.

  • The great pure Python Processing implementation project #p5py seems stalled, latest release in Dec. 2023 :((( Advancing it was always going to be an uphill battle


  • The unrelated Brython based site p5py.com seems to be gone, so I removed it from the table.

  • I added a link to my own #pyp5js hack py5pjs/py5mode because this is what I’m using most nowadays.

​ Read More

Updating my #Processing + #Python tools table:

https://github.com/villares/Resources-for-teaching-programming/blob/main/README.md#processing–python-tools-table

After some years, things changed and my opinions changed a bit too:

  • #py5 is going super strong and the “new snake_case names” are not an issue for me anymore. I used to worry a lot about all the Processing Python mode examples and teaching materials out there, and some of my own, with “CamelCase Processing names” I’m not worried at all about it anymore!

  • For the record, Processing Python mode is just a legacy thing, no one should start anything with it.

  • The great “pure Python” (no Java required) Processing implementation project #p5py seems stalled, latest release in Dec. 2023 :((( Advancing it was always going to be an uphill battle


  • The unrelated Brython based site p5py.com seems to be gone, so I removed it from the table.

  • I added a link to my own #pyp5js hack py5pjs/py5mode because this is what I’m using most nowadays.

​ Read More

Updating my #Processing + #Python tools table:

https://github.com/villares/Resources-for-teaching-programming/blob/main/README.md#processing–python-tools-table

After some years, things changed and my opinions changed a bit too:

  • #py5 is going super strong and the “new snake_case names” are not an issue for me anymore. I used to worry a lot about all the Processing Python mode examples and teaching materials out there, and some of my own, with “CamelCase Processing names” I’m not worried at all about it anymore!

  • For the record, Processing Python mode is just a legacy thing, no one should start anything new with it.

  • The great “pure Python” (no Java required) Processing implementation project #p5py seems stalled, latest release in Dec. 2023 :((( Advancing it was always going to be an uphill battle


  • The unrelated #Brython based site p5py.com seems to be gone, so I removed it from the table.

  • I added a link to my own #pyp5js hack py5pjs/py5mode because this is the version of pyp5js I’m using most nowadays.

​ Read More
In-reply-to » Speaking of manpages:

You can explicitly use colors in manpages. I saw this in the apt manpage of Ubuntu recently, which, for some reason, uses blue text in one place:

https://movq.de/v/de5ab72016/s.png

Makes little sense to me. I’m glad that most manpages don’t do this. I wouldn’t want unicorn vomit all over the place.

Using colors can be done using the low level commands \m and \M:

.TH foo_program 3
\m[blue]I'm blue\m[], da ba dee.
\m[red]\M[yellow]I'm red on yellow.\m[]\M[]
This is quite horrible.

https://movq.de/v/394282ec75/s.png

​ Read More
In-reply-to » Speaking of manpages:

@kat@yarn.girlonthemoon.xyz On the one hand, all these programs have a very long history and the technology behind manpages is actually very powerful – you can use it to write books:

https://www.troff.org/pubs.html

I have two books from that list, for example “The UNIX programming environment”:

https://movq.de/v/c3dab75c97/upe.jpg

It’s a bit older, of course, but it looks and feels like a normal book, and it uses the same tech as manpages – which I think is really cool. 😎

It’s comparable to LaTeX (just harder/different to use) but much faster than LaTeX. You can also do stuff like render manpages as a PDF (man -Tpdf cp >cp.pdf) or as an HTML file (man -Thtml cp >cp.html). I think I once made slides for a talk this way.

On the other hand, traditional manpages (i.e., ones that are not written in mandoc) do not use semantic markup. They literally say, “this text is bold, that text over here is italics”, and so on.

So when you run man foo, it has no other choice but to show it in black, white, bold, underline – showing it in color would be wrong, because that’s not what the source code of that manpage says.

Colorizing them is a hack, to be honest. You’re not meant to do this. (The devs actually broke this by accident recently. They themselves aren’t really aware that people use colors.)

If mandoc and semantic markup was more commonly used, I think it would be easier to convince the devs to add proper customizable colors.

​ Read More

In 1996, they came up with the X11 “SECURITY” extension:

https://www.reddit.com/r/linux/comments/4w548u/what_is_up_with_the_x11_security_extension/

This is what could have (eventually) solved the security issues that we’re currently seeing with X11. Those issues are cited as one of the reasons for switching to Wayland.

That extension never took off. The person on reddit wonders why – I think it’s simple: Containers and sandboxes weren’t a thing in 1996. It hardly mattered if X11 was “insecure”. If you could run an X11 client, you probably already had access to the machine and could just do all kinds of other nasty things.

Today, sandboxing is a thing. Today, this matters.

I’ve heard so many times that “X11 is beyond fixable, it’s hopeless.” I don’t believe that. I believe that these problems are solveable with X11 and some devs have said “yeah, we could have kept working on it”. It’s that people don’t want to do it:

Why not extend the X server?

Because for the first time we have a realistic chance of not having to do that.

https://wayland.freedesktop.org/faq.html

I’m not in a position to judge the devs. Maybe the X.Org code really is so bad that you want to run away, screaming in horror. I don’t know.

But all this was a choice. I don’t buy the argument that we never would have gotten rid of things like core fonts.

All the toolkits and programs had to be ported to Wayland. A huge, still unfinished effort. If that was an acceptable thing to do, then it would have been acceptable to make an “X12” that keeps all the good things about X11, remains compatible where feasible, eliminates the problems, and requires some clients to be adjusted. (You could have still made “X11X12” like “XWayland” for actual legacy programs.)

​ Read More
In-reply-to » “Wayland Will Never Be Ready For Every X.Org User”

I wasn’t really aware until recently that programs can’t choose their own window’s position on Wayland. This is very weird to me, because this was not an issue on X11 to begin with: X11 programs can request a certain position and size, but the X11 WM ultimately decides if that request is being honored or not. And users can configure that.

But apparently, this whole thing is a heated debate in the Wayland world. đŸ€”

​ Read More

gomdn: Yet another Static Site Generator
Yet another Static Site Generator (SSG), but this one is mine.

It’s a stupidly simple Go program ( wc says 229 lines), more like a
hack, really, but I don’t need something like Hugo. Most of the real
work is done by the goldmark package, of course. This is mostly just a
wrapper, deciding if something needs to be rebuilt.

I’ve been using a Perl script together with cmark (originally
Markdown.pl) since forever. And before that the old [txt2tags](htt 
 ⌘ Read more

​ Read More
In-reply-to » PSA: setpriv on Linux supports Landlock.

Another example:

$ setpriv \
    --landlock-access fs \
    --landlock-rule path-beneath:execute,read-file:/bin/ls-static \
    --landlock-rule path-beneath:read-dir:/tmp \
    /bin/ls-static /tmp/tmp/xorg.atom

The first argument --landlock-access fs says that nothing is allowed.

--landlock-rule path-beneath:execute,read-file:/bin/ls-static says that reading and executing that file is allowed. It’s a statically linked ls program (not GNU ls).

--landlock-rule path-beneath:read-dir:/tmp says that reading the /tmp directory and everything below it is allowed.

The output of the ls-static program is this line:

─rw─r──r────x 3000 200 07-12 09:19 22'491 │ /tmp/tmp/xorg.atom

It was able to read the directory, see the file, do stat() on it and everything, the little x indicates that getting xattrs also worked.

3000 and 200 are user name and group name – they are shown as numeric, because the program does not have access to /etc/passwd and /etc/group.

Adding --landlock-rule path-beneath:read-file:/etc/passwd, for example, allows resolving users and yields this:

─rw─r──r────x cathy 200 07-12 09:19 22'491 │ /tmp/tmp/xorg.atom

​ Read More

The WM_CLASS Property is used on X11 to assign rules to certain windows, e.g. “this is a GIMP window, it should appear on workspace number 16.” It consists of two fields, name and class.

Wayland (or rather, the XDG shell protocol – core Wayland knows nothing about this) only has a single field called app_id.

When you run X11 programs under Wayland, you use XWayland, which is baked into most compositors. Then you have to deal with all three fields.

Some compositors map name to app_id, others map class to app_id, and even others directly expose the original name and class.

Apparently, there is no consensus.

​ Read More
In-reply-to » The lack of suckless-like simple, hackable software these days is appalling.

@prologic@twtxt.net Yeah, this really could use a proper definition or a “manifest”. 😅 Many of these ideas are not very wide spread. And I haven’t come across similar projects in all these years.

Let’s take the farbfeld image format as an example again. I think this captures the “spirit” quite well, because this isn’t even about code.

This is the entire farbfeld spec:

farbfeld is a lossless image format which is easy to parse, pipe and compress. It has the following format:

╔════════╀═════════════════════════════════════════════════════════╗
║ Bytes  │ Description                                             ║
╠════════â•Ș═════════════════════════════════════════════════════════╣
║ 8      │ "farbfeld" magic value                                  ║
â•Ÿâ”€â”€â”€â”€â”€â”€â”€â”€â”Œâ”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â•ą
║ 4      │ 32-Bit BE unsigned integer (width)                      ║
â•Ÿâ”€â”€â”€â”€â”€â”€â”€â”€â”Œâ”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â•ą
║ 4      │ 32-Bit BE unsigned integer (height)                     ║
â•Ÿâ”€â”€â”€â”€â”€â”€â”€â”€â”Œâ”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â•ą
║ [2222] │ 4x16-Bit BE unsigned integers [RGBA] / pixel, row-major ║
╚════════╧═════════════════════════════════════════════════════════╝

The RGB-data should be sRGB for best interoperability and not alpha-premultiplied.

(Now, I don’t know if your screen reader can work with this. Let me know if it doesn’t.)

I think these are some of the properties worth mentioning:

  • The spec is extremely short. You can read this in under a minute and fully understand it. That alone is gold.
  • There are no “knobs”: It’s just a single version, it’s not like there’s also an 8-bit color depth version and one for 16-bit and one for extra large images and one that supports layers and so on. This makes it much easier to implement a fully compliant program.
  • Despite being so simple, it’s useful. I’ve used it in various programs, like my window manager, my status bars, some toy programs like “tuxeyes” (an Xeyes variant), or Advent of Code.
  • The format does not include compression because it doesn’t need to. Just use something like bzip2 to get file sizes similar to PNG.
  • It doesn’t cover every use case under the sun, but it does cover the most important ones (imho). They have discussed using something other than RGBA and decided it’s not worth the trouble.
  • They refrained from adding extra baggage like metadata. It would have needlessly complicated things.

​ Read More

** Om nom nom LLMs, in which I respond to Simon Willison’s analogy **
I am hesitant to wade into the tumultuous waters that are the discourse around generative AI and LLMs, but this morning I came across a thing that so thoroughly melted my brain I feel uncontrollably compelled to respond.

This morning, at evidently 4:10 AM (no mention of timezone), Simon Willison shared the following blog post, quoted here in full:

Quitting programming as 
 ⌘ Read more

​ Read More

Just realized: One of the reasons why I don’t like “flat UIs” is that they look broken to me. Like the program has a bug, missing pixmaps or whatever.

Take this for example:

https://movq.de/v/8822afccf0/a.png

I’m talking about this area specifically:

https://movq.de/v/8822afccf0/a%2Dhigh.png

One UI element ends and the other one begins – no “transition” between them.

The style of old UIs like these two is deeply ingrained into my brain:

https://movq.de/v/8822afccf0/b.png
https://movq.de/v/8822afccf0/c.png

When all these little elements (borders, handles, even just simple lines, 
) are no longer present, then the program looks buggy and broken to me. And I’m not sure if I’ll ever be able to un-learn that.

​ Read More

I did a “lecture”/“workshop” about this at work today. 16-bit DOS, real mode. đŸ’Ÿ Pretty cool and the audience (devs and sysadmins) seemed quite interested. đŸ„ł

  • People used the Intel docs to figure out the instruction encodings.
  • Then they wrote a little DOS program that exits with a return code and they used uhex in DOSBox to do that. Yes, we wrote a COM file manually, no Assembler involved. (Many of them had never used DOS before.)
  • DEBUG from FreeDOS was used to single-step through the program, showing what it does.
  • This gets tedious rather quickly, so we switched to SVED from SvarDOS for writing the rest of the program in Assembly language. nasm worked great for us.
  • At the end, we switched to BIOS calls instead of DOS syscalls to demonstrate that the same binary COM file works on another OS. Also a good opportunity to talk about bootloaders a little bit.
  • (I think they even understood the basics of segmentation in the end.)

The 8086 / 16-bit real-mode DOS is a great platform to explain a lot of the fundamentals without having to deal with OS semantics or executable file formats.

Now that was a lot of fun. đŸ„ł It’s very rare that we do something like this, sadly. I love doing this kind of low-level stuff.

​ Read More

** Of fairies, compost, and computers **
Lately I’ve buried myself in reading fiction. Stand outs from among the crowd are, of course, Middlemarch but also a lot of sort of scholarly fairy fiction; works that follow the scholastic adventures of studious professorial types in vaugely magical settings. Namely Emily Wilde’s Encyclopedia of Faeries’, Heather Fawcett and The Ten Thousand Doors of January, Alix E. Harrow.

I’ve also been working on a handful of personal utility programs. I 
 ⌘ Read more

​ Read More

Saw this on Mastodon:

https://racingbunny.com/@mookie/114718466149264471

18 rules of Software Engineering

  1. You will regret complexity when on-call
  2. Stop falling in love with your own code
  3. Everything is a trade-off. There’s no “best” 3. Every line of code you write is a liability 4. Document your decisions and designs
  4. Everyone hates code they didn’t write
  5. Don’t use unnecessary dependencies
  6. Coding standards prevent arguments
  7. Write meaningful commit messages
  8. Don’t ever stop learning new things
  9. Code reviews spread knowledge
  10. Always build for maintainability
  11. Ask for help when you’re stuck
  12. Fix root causes, not symptoms
  13. Software is never completed
  14. Estimates are not promises
  15. Ship early, iterate often
  16. Keep. It. Simple.

Solid list, even though 14 is up for debate in my opinion: Software can be completed. You have a use case / problem, you solve that problem, done. Your software is completed now. There might still be bugs and they should be fixed – but this doesn’t “add” to the program. Don’t use “software is never done” as an excuse to keep adding and adding stuff to your code.

​ Read More

Okay, here’s a thing I like about Rust: Returning things as Option and error handling. (Or the more complex Result, but it’s easier to explain with Option.)

fn mydiv(num: f64, denom: f64) -> Option<f64> {
    // (Let’s ignore precision issues for a second.)
    if denom == 0.0 {
        return None;
    } else {
        return Some(num / denom);
    }
}

fn main() {
    // Explicit, verbose version:
    let num: f64 = 123.0;
    let denom: f64 = 456.0;
    let wrapped_res = mydiv(num, denom);
    if wrapped_res.is_some() {
        println!("Unwrapped result: {}", wrapped_res.unwrap());
    }

    // Shorter version using "if let":
    if let Some(res) = mydiv(123.0, 456.0) {
        println!("Here’s a result: {}", res);
    }

    if let Some(res) = mydiv(123.0, 0.0) {
        println!("Huh, we divided by zero? This never happens. {}", res);
    }
}

You can’t divide by zero, so the function returns an “error” in that case. (Option isn’t really used for errors, IIUC, but the basic idea is the same for Result.)

Option is an enum. It can have the value Some or None. In the case of Some, you can attach additional data to the enum. In this case, we are attaching a floating point value.

The caller then has to decide: Is the value None or Some? Did the function succeed or not? If it is Some, the caller can do .unwrap() on this enum to get the inner value (the floating point value). If you do .unwrap() on a None value, the program will panic and die.

The if let version using destructuring is much shorter and, once you got used to it, actually quite nice.

Now the trick is that you must somehow handle these two cases. You must either call something like .unwrap() or do destructuring or something, otherwise you can’t access the attached value at all. As I understand it, it is impossible to just completely ignore error cases. And the compiler enforces it.

(In case of Result, the compiler would warn you if you ignore the return value entirely. So something like doing write() and then ignoring the return value would be caught as well.)

​ Read More
In-reply-to » OpenBSD has the wonderful pledge() and unveil() syscalls:

@movq@www.uninformativ.de That sounds great! (Well, they actually must have recorded the audio with a potato or so.) You talked about pledge(
) and unveil(
) before, right? I somewhere ran across them once before. Never tried them out, but these syscalls seem to be really useful. They also have the potential to make one really rethink about software architecture. I should probably give this a try and see how I can improve my own programs.

​ Read More
In-reply-to » Fuck me sideways, Rust is so hard. Will we ever be friends?

@prologic@twtxt.net I’m trying to call some libc functions (because the Rust stdlib does not have an equivalent for getpeername(), for example, so I don’t have a choice), so I have to do some FFI stuff and deal with raw pointers and all that, which is very gnarly in Rust – because you’re not supposed to do this. Things like that are trivial in C or even Assembler, but I have not yet understood what Rust does under the hood. How and when does it allocate or free memory 
 is the pointer that I get even still valid by the time I do the libc call? Stuff like that.

I hope that I eventually learn this over time 
 but I get slapped in the face at every step. It’s very frustrating and I’m always this đŸ€ close to giving up (only to try again a year later).

Oh, yeah, yeah, I guess I could “just” use some 3rd party library for this. socket2 gets mentioned a lot in this context. But I don’t want to. I literally need one getpeername() call during the lifetime of my program, I don’t even do the socket(), bind(), listen(), accept() dance, I already have a fully functional file descriptor. Using a library for that is total overkill and I’d rather do it myself. (And look at the version number: 0.5.10. The library is 6 years old but they’re still saying: “Nah, we’re not 1.0 yet, we reserve the right to make breaking changes with every new release.” So many Rust libs are still unstable 
)


 and I could go on and on and on 
 đŸ€Ł

​ Read More

OpenBSD has the wonderful pledge() and unveil() syscalls:

https://www.youtube.com/watch?v=bXO6nelFt-E

Not only are they super useful (the program itself can drop privileges – like, it can initialize itself, read some files, whatever, and then tell the kernel that it will never do anything like that again; if it does, e.g. by being exploited through a bug, it gets killed by the kernel), but they are also extremely easy to use.

Imagine a server program with a connected socket in file descriptor 0. Before reading any data from the client, the program can do this:

unveil("/var/www/whatever", "r");
unveil(NULL, NULL);
pledge("stdio rpath", NULL);

Done. It’s now limited to reading files from that directory, communicating with the existing socket, stuff like that. But it cannot ever read any other files or exec() into something else.

I can’t wait for the day when we have something like this on Linux. There have been some attempts, but it’s not that easy. And it’s certainly not mainstream, yet.

I need to have a closer look at Linux’s Landlock soon (“soon”), but this is considerably more complicated than pledge()/unveil():

https://landlock.io/

​ Read More

So I was using this function in Rust:

https://doc.rust-lang.org/std/path/struct.Path.html#method.display

Note the little 1.0.0 in the top right corner, which means that this function has been “stable since Rust version 1.0.0”. We’re at 1.87 now, so we’re good.

Then I compiled my program on OpenBSD with Rust 1.86, i.e. just one version behind, but well ahead of 1.0.0.

The compiler said that I was using an unstable library feature.

Turns out, that function internally uses this:

https://doc.rust-lang.org/std/ffi/struct.OsStr.html#method.display

And that is only available since Rust 1.87.

How was I supposed to know this? đŸ€šđŸ«©

​ Read More

CNCF Kubestronaut Program Momentum Highlights Asia’s Role in Growing Cloud Native Talent
Upcoming Kubestronaut celebrations in China and Japan to honor global program growth Hong Kong, China– 10 June, 2025 – The Cloud Native Computing Foundation¼ (CNCF¼), which builds sustainable ecosystems for cloud native software, today announced continued
 ⌘ Read more

​ Read More

“She didn’t want to leave’: Program to help people using libraries as safe spaces
A Perth library trials a social worker program after noticing an increase in people using libraries as a safe space. ⌘ Read more

​ Read More

Queensland shark control plan goes against government commissioned advice
The KPMG report stresses that while “traditional measures” are still required, the program needs to transition away from “environmentally harmful practices”, such as drumlines and mesh nets. ⌘ Read more

​ Read More

How can one write blazing fast yet useful compilers (for lazy pure functional languages)?
I’ve decided enough is enough and I want to write my own compiler (seems I caught a bug and lobste.rs is definitely not discouraging it). The language I have in mind is a basic (lazy?) statically-typed pure functional programming language with do notation and records (i.e. mostly Haskell-lite).

I have other ideas I’d like to explore as well, but mainly, I want the compiler to be so fast (w/ optimisations) that 
 ⌘ Read more

​ Read More

Killing more than breast and prostate, our deadliest cancer to get screening
After years of lobbying from patients, the first ever national lung cancer screening program will roll out next month for people who have a significant history of smoking. ⌘ Read more

​ Read More

Tasmanian land program yet to deliver affordable lots for homes
Developers in Tasmania can apply for a rebate to offset some of the costs associated with subdivisions. It’s part of a program aimed at fast-tracking lots for “affordable” sales but, after 10 months not one affordable lot has been sold. ⌘ Read more

​ Read More

The diabetes program lifting people out a ‘really dark place’
When Kelly Anderson suddenly lost her daughter, she became depressed and rapidly gained weight. A community exercise program helped turn her life around. ⌘ Read more

​ Read More

[$] Allowing BPF programs more access to the network
Mahé Tardy led two sessions about some of the challenges that he, Kornilios Kourtis,
and John Fastabend have run into in their work on
Tetragon (Apache-licensed BPF-based security monitoring software)
at the Linux Storage, Filesystem, Memory Management, and BPF Summit. The session
prompted discussion about the feasibility of letting BPF programs
send data over the network, as well as potential new kfuncs to let BPF firewalls
send TCP reset packets. Tardy pre 
 ⌘ Read more

​ Read More