Location of user files in V 5.1 pip install using venv

93 views
Skip to first unread message

Peter Fletcher

unread,
Oct 28, 2024, 5:36:27 PM10/28/24
to weewx-user
Where do these files (code for user written services) go, by default? The doc says "bin/user', but there is no 'user' directory in weewx-venv/bin. Does a directory of that name simply need to be created there? I am really finding the consequences of the new 'rules' for installing Python applications in the latest (Bookworm) versions of Debian and its Pi derivative a severe PITA.

gjr80

unread,
Oct 28, 2024, 6:11:00 PM10/28/24
to weewx-user

You need to read the ‘Where to find  things’ page carefully and completely. The answer is in the notes:

In the locations above, relative paths are relative to WEEWX_ROOT. Absolute paths begin with a forward slash (/). The tilde character (~) represents the HOME directory of the user.

Gary

vince

unread,
Oct 28, 2024, 6:36:25 PM10/28/24
to weewx-user
Reread https://www.weewx.com/docs/5.1/quickstarts/pip/ and pick the Debian tab.

Assuming you're a new user on a pi who ran pip as user 'pi' and who has the typical /home/pi $HOME location:
  • Core weewx itself would be in /home/pi/weewx-venv
  • The station(s) you create, their skin(s) and databases, and anything else you add would be under /home/pi/weewx-data
That said, if you use the extension installer to install such things, the right things happen.  I'd highly suggest packaging anything you add for the extension installer if possible.

FWIW - we all feel your pain about the venv PITA but nobody here caused that issue.  Blame the python and debian teams upstream.  We're all victims for that one and just kinda have to deal with it.

Peter Fletcher

unread,
Oct 28, 2024, 7:02:43 PM10/28/24
to weewx-user
I was (incorrectly, but perhaps understandably) looking on the Debian tab - I missed the pip tab, the contents of which makes it a bit clearer, and there is, indeed, a user directory in weewx-data/bin.

Peter Fletcher

unread,
Oct 28, 2024, 7:17:04 PM10/28/24
to weewx-user
As I noted in another reply, looking on the Debian tab rather than the pip tab was a large part of the problem!

My services make use of various external things which are present in my specific environment, so they are no use to anyone else, and packaging them as extensions didn't (and doesn't) seem to make sense.

I did not mean to imply that the venv PITA was in any way the weewx folks' fault - just expressing my frustration. The previous time Debian and Pi upgraded the OS (to Bullseye), it took me a couple of hours to configure the updated OS for and with all the (substantial amount of) home monitoring and control software that runs on my 'workhorse' system. This time, it has already taken me days of work, and I am still not done!

Glenn McKechnie

unread,
Oct 29, 2024, 6:28:50 AM10/29/24
to weewx...@googlegroups.com
In weewx-data...

~/weewx-data/bin/user


Cheers
 Glenn

Various WeeWx addons at
https://github.com/glennmckechnie


On Tue, 29 Oct 2024 at 08:36, 'Peter Fletcher' via weewx-user <weewx...@googlegroups.com> wrote:
Where do these files (code for user written services) go, by default? The doc says "bin/user', but there is no 'user' directory in weewx-venv/bin. Does a directory of that name simply need to be created there? I am really finding the consequences of the new 'rules' for installing Python applications in the latest (Bookworm) versions of Debian and its Pi derivative a severe PITA.

--
You received this message because you are subscribed to the Google Groups "weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/weewx-user/3dd7573a-d776-429d-8e78-79441f36d7a6n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages