site  contact  history  index

Yradio version 1.9.6-5

November 23, 2026 — BarryK

Forum member fredx181 has made some improvements to Yradio:

https://forum.puppylinux.com/viewtopic.php?p=179994#p179994

Looking good!    

Tags: easy

Fix for Easy Containers crash

November 23, 2026 — BarryK

Forum member retiredt00 raised the question, and Caramel posted some excellent suggestions:

https://forum.puppylinux.com/viewtopic.php?t=17740

I have had a good look at the code, have implemented Caramel's suggestions, and removed the call to script 'ec-chroot-admin', it is no longer needed.

Need a bit more testing to verify, but it looks improved.   

Tags: easy

Fixes for EasySetup

November 23, 2026 — BarryK

A little while ago, fixed EasyApps:

Yesterday it was reported same problem with EasySetup, some icons do not find any applications. Fixes in a few places, including in the "EasyOS" tab:

img1

Hmmm, unable to login to the Puppy Forum this morning. Still cannot upload to ibiblio.org, for several days now.   

Tags: easy

Tweak powerapplet_tray external charging

November 22, 2026 — BarryK

I posted about using Claude AI to detect battery types other than BAT0 and BAT1:

However, I noticed a difference from the original code; when the external power adapter is plugged in, but battery is at 100% so no longer charging, sometimes the tray icon was a red colour and mouse-over stated "Battery discharging, capacity 100%". I reported this to Claude:

In the original code, when the external power is plugged in and the charge has reached 100%, mouseover the tray icon says "Battery charging, capacity 100%" and the icon in the tray is color blue. However, your code says "Battery discharging, capacity 100%" and icon is red color, which is misleading. I think that when the external power is plugged in, the tray icon should always be color blue.

Claude responded:

That's a regression from my change, not your original logic. The original treats the battery as charging unless sysfs says "Discharging". I added "Not charging" as a discharging state, and many laptops report "Not charging" or "Full" at 100% on AC. I'll remove that and also check the AC adapter directly, so plugged-in always shows blue.

I've fixed it. The regression was my "Not charging" line, which I've removed.

There are two changes in the sysfs branch of `Update()`:
- **Original behaviour restored:** the battery counts as charging unless its status is exactly "Discharging". "Full" and "Not charging" at 100% on AC now show the blue icon and "Battery charging, capacity 100%", as in your original.
- **AC check added:** a new `ac_online()` function looks for a non-battery supply in `/sys/class/power_supply` (the AC adapter or a USB-C charger) with `online` = 1. If the battery reports "Discharging" while external power is connected, as some laptops do near a charge limit, the applet now treats that as charging too, so the icon stays blue whenever you're plugged in.

I haven't built or run this. The sandbox has no GTK headers and no power supplies, so I only compiled `ac_online()` on its own. It ran and returned 0, which is correct there. Please run `./compile` and test it on your laptop.

The updated `powerapplet_tray.c` is the file to use. The patch is attached as `battery-detect.patch.txt`, a diff against your original upload that includes both the detection fix and this one.

I have bumped powerapplet_tray PET to version 3.4.   

Tags: easy

EasyOS version 7.5.4 released

November 20, 2026 — BarryK

Here are the highlights since version 7.5.3:

A lot has happened!

Unfortunately, uploading to ibiblio.org is broken, has been for 4-5 days. Discussion here:

https://forum.puppylinux.com/viewtopic.php?t=17743

So, the desktop "update" icon won't work.

Instead, I have uploaded 7.5.4 to easyos.org:

https://easyos.org/releases/7.5.4/

You will need to download the .img file, then do a manual update. It's very simple, see lower down the page on this update tutorial:

https://easyos.org/user/how-to-update-easyos.html

My URLs bkhome.org and easyos.org are on a shared-hosting account, so might get a complaint from the hosting company if do lots of big downloads. What is really needed is an alternative to ibiblio.org, that we can fallback to. It would need to handle lots of downloads and have an rsync server.

Feedback welcome at the forum:

https://forum.puppylinux.com/viewtopic.php?p=180237#p180237

Have fun!    

Tags: easy

Fix powerapplet find battery in laptop

November 19, 2026 — BarryK

Forum member Vverve posted a fix for powerapplet_tray that finds the battery on his laptop:

https://forum.puppylinux.com/viewtopic.php?p=180195#p180195

I'm on a roll last couple of days with Claude AI, so gave it the source of powerapplet_tray v3.2, and asked:

This is a Linux tray application that monitors battery status in a laptop, displays percentage charge and warns when battery low. The problem is that it does not detect the battery on some laptops. Can you suggest a change that will fix this?

Claude responded:

I've patched it so the applet finds the battery by what it is rather than by name, but I haven't built or run it. This sandbox has no GTK headers and no batteries, so I could only check the new detection function on its own. Please run `./compile` and try it on a laptop that failed before.

**The cause:** On modern kernels the `/sys` branch of `main()` only looks for `/sys/class/power_supply/BAT0`, then `BAT1`. If neither exists, it logs "Abort, unable to open … BAT0 or BAT1" and exits. Some laptops name the battery `CMB0`, `BATT`, `BATC` or `macsmc-battery` (Apple Silicon), so the applet never starts there.

**The fix:** I added `find_sys_battery()`, which scans `/sys/class/power_supply/` and picks the first entry that:
- has `type` = `Battery`, which skips AC adapters and USB supplies;
- isn't a peripheral battery (`scope` = `Device`), such as a wireless mouse or keyboard;
- has a `capacity` file;
- has `present` not equal to 0. A battery that reports absent is used only as a last resort, so a dual-battery machine with an empty bay still works.

The discovered name replaces the hard-coded `BAT0`/`BAT1` paths.

I also fixed three nearby problems:
- **Click dialog:** it ran `cat /sys/class/power_supply/BAT[01]/uevent`, so the click-for-details popup would have been blank on those same machines. It now uses the detected battery.
- **Crash on unreadable files:** `Update()` called `fgets` on a possibly NULL file pointer. It now returns quietly, so the timer stays alive if the battery is unplugged or unreadable.
- **"Not charging" status:** this status (some laptops report it at a charge threshold) is now treated as not charging, so the icon isn't shown as charging when it isn't.

Compiling the isolated function with `-Wall` gave only harmless `snprintf` truncation warnings. They can't trigger, because names of 64 characters or more are skipped first.

Files are in `/home/claude`:
- battery-detect.patch
- powerapplet_tray.c

I have compiled it and created powerapplet_tray version 3.3. It works the same on my laptop, detects BAT0. Remains to be seen how works on others such as Vverve's laptop.   

Tags: easy

ROX-Filer thumbnails patch

November 19, 2026 — BarryK

In ROX-Filer there is an "eye" icon; right-click on it toggles thumbnails on/off for image and video files.

The problem is that sometimes not all the files are converted to thumbnails; have to toggle thumbnails off then on again, sometimes more than twice, to convert all of them.

I have asked Claude AI about this, and we had a to-and-fro interaction, eventually had a patch that fixed it.

Previously, if an image file failed to convert to a thumbnail, it prevented the rest of the image files in the window from being converted. There is now a 3-second timeout for a conversion, then conversion of the rest of the files will continue. Works OK.   

Tags: easy

Fix convert pup_event_ipc.bac to C

November 18, 2026 — BarryK

Yesterday I posted about using Claude AI to convert some utilities in the pup-tools package written in BaCon and nim to C:

The BaCon utilities: welcome1stboot.bac, find_cat.bac, pup_event_ipc.bac

The nim utility: debdb2pupdb.nim

Don't actually use welcome1stboot anymore, nor, I think, find_cat; however, pup_event_ipc is an important part of the pup_event mechanism.

I compiled these C programs, and unfortunately pup_event_ipc does not work. Could probably work through it and find where it is going wrong; however, decided on a different approach. The BaCon compiler is not an actual compiler; it generates C code then calls gcc. So, I told the 'bacon' executable to create the C code only, then I made it into a tarball and provided it to Claude. I asked Claude:

Could you simplify this C code

What followed is quite remarkable. The C code created by bacon is very human-unreadable, so I was hoping that Claude could reduce it to something simpler and human-readable. It did. This is Claude's analysis:

I've rewritten the BaCon-generated code as one standalone file, `pup_event_ipc.c`, about 186 lines. It builds with `cc -o pup_event_ipc pup_event_ipc.c`. The original was roughly 1,850 lines spread over nine files, plus the BaCon runtime.

I compiled both versions and ran them side by side. They gave the same output and exit codes for every case I tried:
- mailbox send, read and empty
- the `waitmail` timeout
- a bad format
- a request/reply exchange
- the keyword waits

**What changed**
- The `#line` markers, the BaCon string runtime, the `select`/`CONCAT` machinery and the `exitsub`/`waitsub` wrappers are gone.
- The help text is one string literal.
- The keyword handling is a small table: `block`, `dbus`, `network`, `x`, `bluetoothhw`, `timeout1`, `timeout4`, `timeout60` and `netchg` all wait on `<keyword>_<client>`.
- The "Not implemented" branch is gone. It could never run, because the file had just been created a few lines earlier.
- Cleanup is left to `exit`, which closes the file descriptors. There's no explicit `inotify_rm_watch`.
- The timeout wait now uses `poll` in both cases, with an infinite timeout when `-t` is 0, instead of a separate blocking `read`.

**Behaviour that differs from the original**
- **`dbus`:** In the original it was missing from the keyword list, so `dbus:x` wrote to file descriptor 0 (stdin). Now it behaves like the other keywords. This is a guess at what the author intended.
- **Error codes 3 and 4:** A failed `open` used to hit BaCon's runtime error first, so the documented exit codes 3 and 4 never happened. They now work as the help text says.
- **`-t` as the last argument:** It used to read past the end of `argv`. Now it's ignored.

The client names go straight into `/tmp/pup_event_ipc/<name>` with no check for `/`, same as the original. That would allow path traversal if untrusted input ever reaches it. I left it alone to keep behaviour identical, but it's a one-line check if you want it.

The result is a single small C file, completely redesigned, using some C functions that must be in libc, but I know nothing about them. Anyway, it compiled, and it works. Haven't studied how it works; for now, just happy that it does.  

Tags: easy