polarmutex/fava-envelope

Python 3.9 Upgrade Broke Plugin (FreeBSD 13.1)

Closed this issue · 9 comments

What Happened

I upgraded my python version to the latest supported release for FreeBSD. The webpage is now showing just pure HTML and not rendering properly on any device.

image

How to reproduce

  1. Upgrade the python port to latest release
  2. Remove the virtual env directory
  3. Run virtualenv env; . env/bin/activate
  4. pip install git+https://github.com/polarmutex/fava-envelope.git
  5. Start fava

Extra Details

I was perusing my stdout logs and noticed that this keeps appearing when restarting Fava:

Jul 8 03:08:32 budget fava[79407]: Error in atexit._run_exitfuncs: Jul 8 03:08:32 budget fava[79407]: Traceback (most recent call last): Jul 8 03:08:32 budget fava[79407]: File "/usr/home/fava/env/lib/python3.9/site-packages/beancount/query/shell.py", line 63, in save_history Jul 8 03:08:32 budget fava[79407]: readline.write_history_file(filename) Jul 8 03:08:32 budget fava[79407]: PermissionError: [Errno 13] Permission denied

It only started recently

This same behavior is occurring on the slim python docker images 3.7, 3.8, 3.9 and 3.10 (ex. python:3.7-slim)

What OS are you on, @expired00 ?

Debian Bullseye

I'm not sure what to try to get this working right now and not fully sure what broke it yet

Sorry I have not had any time to look at this, I will try to figure it out when I can

@expired00 have you upgraded numpy and protobuf to the latest versions yet? Asking because after upgrading both, I was able to get it to render properly again. I'm not sure what changed between releases

I can upgrade the poetry lock file if that is the issue

I am also having this issue, although I believe in my case it's related to the fava version. If I use fava 1.22 as installed via system packages, it displays similar to the screenshot above. If I run it with 1.21 as defined in the pyproject.toml it runs fine.

To note: I'm using python 3.10.5.

Sorry for getting back so late but that seems to be the issue. I'm not using the ports version of Fava for FreeBSD since it's not fully up to date and does seem to have some minor issues regardless. Upgrading to Fava 1.22 is what broke it for me but the official port was a bit too out of date for fava-envelope to work last time I tested it.