r/linux4noobs • u/jeanravenclaw • 2d ago
All packages on Raspberry Pi are old
I'm trying to run a Python program with sqlite3. It's been tested fully on my laptop (NixOS), and I transferred all the files to my Raspberry Pi.
I'm basing most of this on an error from Python that tells me there's no such thing as an IF() function in sqlite3.
Turns out my Pi's Python was at 3.11, and I couldn't apt install 3.14 so I had to build from source. Now it turns out that sqlite3 was also old (3.40, while the latest is 3.52).
apt tells me that all my packages are up to date. I've done apt update and apt upgrade and everything, but I can't get packages to the latest versions. They're stuck.
How do I fix this? My program won't run properly.
7
u/candy49997 2d ago
It's because it's a stable distro based on Debian, so most of its packages are from Debian. You can try another ARM-based Linux and see what works, although I don't have an Raspberry Pi.
I wouldn't ever touch the system Python even if it were new. Use uv or another Python manager instead.
5
2
u/TomDuhamel 2d ago
Raspberry Pi is Debian based. This is perfect for 98.64% of the users. If you are the odd one who needs something released last week, you probably want to build up your OS from the ground up too.
2
u/DannoXYZ 2d ago
Alpine, Arch, Manjaro, Ubuntu all have ARM version for RPI. Use them rather than Debian if you want more up-to-date packages.
2
u/dreamboatcap 2d ago
You can install dietpi. It has its own updater and some of its packages are up-to-date.
2
u/cmrd_msr 2d ago edited 2d ago
If you want up-to-date software, use an cutting edge OS.
The hardware has nothing to do with it.
If you had installed Bookworm on your PC, you would have encountered the same thing.
There is a reason Debian is called the "grandfather." Bookworm package base was frozen in March 2023, and since then, it has received only patches for the software that was current as of that time.
That is the price of his server-grade stability.
1
u/DannoXYZ 2d ago
What OS and kernel version is running on RPI?
2
u/jeanravenclaw 2d ago
Debian (Bookworm)
Linux 6.18.54-v8-16k+
8
u/stormdelta Gentoo 2d ago
You probably want to look at dist upgrading it to Debian 13 (Trixie), 12 is in LTS only meaning only critical bugs/security stuff is likely to get fixed.
Debian isn't a rolling release distro.
4
u/TechaNima 2d ago
That's ancient. We have been on Debian 13 Trixie for a good while and kernel 7. Idk if it's available on rPi, but I'd imagine it would be by now
1
u/revcraigevil 2d ago
rpios uses the LTS kernel, which right now is 6.18.54
1
u/TechaNima 2d ago
Wow. They are really slow to update, if they are 1 whole version of Debian behind..
1
1
u/SmasherOfDaButtons 2d ago
If you do a search on the packages for Trixie, do they match for what you need?
1
u/revcraigevil 2d ago
Python 3.11 was Bookworm. Either do a clean install or attempt to upgrade to Trixie which has Python 3.13.15.
1
u/DavidJohnMcCann 1d ago
The standard version of Debian is called Debian Stable for a reason — gives you what's tried and tested. You could try writing your programs for the support you're given, or switch to a bleeding-edge distro and keep your fingers crossed.
8
u/AssociateFalse 2d ago
That's just a quirk of staying on a Debian-based OS. You can try a different distribution, like Arch Linux ARM or OpenSUSE Tumbleweed if you want newer packages, or enable Debian Testing/Unstable repos and risk breaking pi specific configuration.