Skip to content

[RFC] Make it work on RaspberryPi OS Trixie#633

Draft
ozbenh wants to merge 3 commits intongardiner:mainfrom
ozbenh:new-raspios
Draft

[RFC] Make it work on RaspberryPi OS Trixie#633
ozbenh wants to merge 3 commits intongardiner:mainfrom
ozbenh:new-raspios

Conversation

@ozbenh
Copy link
Copy Markdown

@ozbenh ozbenh commented Dec 16, 2025

Hi ! Not an expert at python packaging but here we go ... A few things in there, small .gitattributes fix, turning regexp strings into r"" strings so newer python (3.14 here) doesn't barf, and finally always use a venv to install the pip dependencies, because otherwise hell breaks lose on any modern system.

This is rough. Will probably break older systems, I don't really know what I'm doing here :-) Happy to adapt based on feedback.

For make install I chose for now to copy the whole source over to /home/twcmanager to be able to properly pip install into the venv from there. There might be a better way... this works :-) I've added a modified systemd service file to run it that way (seems to work on dummy for now, I'll try on the real charger when I get back near it).

Otherwise we get invalid escape sequences with newer python versions

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
With newer distro, polluting the global python namespace with pip
is disabled by default and very much frowned upon. Let's just venv
it all, shall we ?

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
@deece
Copy link
Copy Markdown

deece commented Dec 17, 2025

We should update docs/Software_Manual.md with explicit instructions for Trixie

@ozbenh
Copy link
Copy Markdown
Author

ozbenh commented Dec 21, 2025

We should update docs/Software_Manual.md with explicit instructions for Trixie

Right but I'm thinking maybe I should default to USE_VENV?=0 and make the instructions explicit about using make USE_VENV=1 for Trixie ? I worry I can't test this isn't breaking existing workloads otherwise

@ngardiner
Copy link
Copy Markdown
Owner

Thanks for the PR. No need to default back to VENV=0 I would say, it's essentially a core requirement for the apt ecosystem now, unless there were any objections I'd suggest we just do it by default.

@ozbenh
Copy link
Copy Markdown
Author

ozbenh commented Dec 28, 2025

I finally got a chance to try it on the real charger today rather than in "fake" mode and it didn't actually work. I have to stick to 'b' not 'r' for the regexps as the msg is binary. I will look into this more later to figure why I had to change it in the first place, for now don't merge this.

@ozbenh ozbenh marked this pull request as draft January 6, 2026 22:39
@ozbenh
Copy link
Copy Markdown
Author

ozbenh commented Jan 6, 2026

Converted to draft. I will polish this once I've actually moved into the new place where the charger is and can test more fully

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants