Re: [weewx-user] Problem with WeeWX5 "driver" directory

2024-02-28 Thread Remy LAVABRE
*with* :  unzip -l AWEKAS.zip
*we have* :
(weewx-venv) remy@remy-virtual-machine:~/weewx-data$ unzip -l AWEKAS.zip
Archive:  AWEKAS.zip
  Length  DateTimeName
-  -- -   
0  2024-02-29 08:42   AWEKAS/
  565  2024-02-29 08:42   AWEKAS/install.py
35149  2024-02-26 10:33   AWEKAS/LICENSE.txt
56528  2024-02-26 10:33   AWEKAS*/awekaswx.py*
- ---
92242 4 files


*Rémy LAVABRE*


Le mer. 28 févr. 2024 à 09:32, gjr80  a écrit :

> What does unzip -l AWEKAS.zip show? Does bin/user/awekaswx.py actually
> exist in the zip file?
>
> Gary
> On Wednesday 28 February 2024 at 17:54:49 UTC+10 remy.l...@gmail.com
> wrote:
>
>> Hello Tom,
>> First problem : when trying to install a driver in virtual environnement :
>>
>> (weewx-venv) remy@remy-virtual-machine:~/weewx-data$ weectl extension
>> install AWEKAS.zip
>> Using configuration file /home/remy/weewx-data/weewx.conf
>> Install extension 'AWEKAS.zip' (y/n)? y
>> Extracting from zip archive AWEKAS.zip
>> Traceback (most recent call last):
>>   File "/home/remy/weewx-venv/bin/weectl", line 8, in 
>> sys.exit(main())
>>   File "/home/remy/weewx-venv/lib/python3.8/site-packages/weectl.py",
>> line 66, in main
>> namespace.func(namespace)
>>   File
>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weectllib/__init__.py",
>> line 121, in dispatch
>> namespace.action_func(config_dict, namespace)
>>   File
>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weectllib/extension_cmd.py",
>> line 116, in install_extension
>> ext.install_extension(namespace.source, no_confirm=namespace.yes)
>>   File
>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py",
>> line 138, in install_extension
>> extension_name = self._install_from_file(extension_path, filetype)
>>   File
>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py",
>> line 168, in _install_from_file
>> extension_name = self.install_from_dir(extension_dir)
>>   File
>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py",
>> line 185, in install_from_dir
>> self._install_files(installer['files'], extension_dir)
>>   File
>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py",
>> line 269, in _install_files
>> shutil.copy(source_path, destination_path)
>>   File "/usr/lib/python3.8/shutil.py", line 418, in copy
>> copyfile(src, dst, follow_symlinks=follow_symlinks)
>>   File "/usr/lib/python3.8/shutil.py", line 264, in copyfile
>> with open(src, 'rb') as fsrc, open(dst, 'wb') as fdst:
>> FileNotFoundError: [Errno 2] No such file or directory:
>> '/tmp/tmprpxo6tw5/AWEKAS/bin/user/awekaswx.py'
>>
>> *and the install.py :*
>>
>> # installer for Awekas Bresser awekaswx driver
>> # Copyright 2024 Remy LAVABRE
>>
>> from setup import ExtensionInstaller
>>
>> def loader():
>> return awekaswxInstaller()
>>
>> class awekaswxInstaller(ExtensionInstaller):
>> def __init__(self):
>> super(awekaswxInstaller, self).__init__(
>> version="1.3",
>> name='awekaswx',
>> description='Get Bresser 7in1 data on Awekas',
>> author="Remy LAVABRE",
>> author_email="remy.l...@gmail.com",
>> files=[('bin/user', ['bin/user/awekaswx.py'])],
>> config={
>> 'awekaswx': {
>> 'driver' : 'bin.user.awekaswx',
>> 'poll_interval': '60',
>> 'awekasapikey' :'My_API_Awekas_Key','
>> 'openweatherapikey': 'My_API_OpenWeather_Key',
>> 'send_syslog': 'True',
>> 'model': 'Bresser 7in1'
>> }
>> }
>> )
>>
>> *Rémy LAVABRE*
>>
>>
>> Le dim. 25 févr. 2024 à 22:45, Tom Keffer  a écrit :
>>
>>> From your description, you're installing it in the correct spot, however
>>> you're not giving us much information. Instead of just showing the single
>>> error line, it would be helpful to see the log from startup. The reason is
>>> that it will log the location of the user directory.
>>>
>>> Set debug=1, then restart weewxd. Post the log *from startup* through
>>> the error.
>>>
>>> On Sun, Feb 25, 2024 at 10:55 AM Remy Lavabre 
>>> wrote:
>>>
 Hello,

 weewx is installed in virtual PIP mode -> ~/weewx-data/... and
 ~/weewx-venv/...
 I manually added the xxx.py driver for my weather station in the
 ~/weewx-data/bin/user directory.
 It is declared in weewx.conf as "driver = usr.xxx", as was done in
 version 4.x

 When launching weewxd, I get the message:
File
 "/home/pi/weewx-venv/lib/python3.8/site-packages/weewx/engine.py", line
 104, in setupStation
  __import__(driver)
 ModuleNotFoundError: *No module named 'usr'*

 I tried "driver = xxx.py" without success

 if I put my driver in
 ~/weewx-venv/lib/

Re: [weewx-user] Problem with WeeWX5 "driver" directory

2024-02-28 Thread Remy LAVABRE
*with :*
*from weecfg.extension import ExtensionInstaller*

def loader():
return awekaswxInstaller()

class awekaswxInstaller(ExtensionInstaller):
def __init__(self):
super(awekaswxInstaller, self).__init__(
version="1.3",
name='awekaswx',
description='Get Bresser 7in1 data on Awekas',
author="Remy LAVABRE",
author_email="remy.lava...@gmail.com",
files=[('bin/user', ['bin/user/awekaswx.py'])]
)

*We have :*

(weewx-venv) remy@remy-virtual-machine:~/weewx-data$ weectl extension
install awekas.zip
Using configuration file /home/remy/weewx-data/weewx.conf
Install extension 'awekas.zip' (y/n)? y
Traceback (most recent call last):
  File "/home/remy/weewx-venv/bin/weectl", line 8, in 
sys.exit(main())
  File "/home/remy/weewx-venv/lib/python3.8/site-packages/weectl.py", line
66, in main
namespace.func(namespace)
  File
"/home/remy/weewx-venv/lib/python3.8/site-packages/weectllib/__init__.py",
line 121, in dispatch
namespace.action_func(config_dict, namespace)
  File
"/home/remy/weewx-venv/lib/python3.8/site-packages/weectllib/extension_cmd.py",
line 116, in install_extension
ext.install_extension(namespace.source, no_confirm=namespace.yes)
  File
"/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py",
line 143, in install_extension
raise InstallError(f"Unrecognized type for {extension_path}")
weecfg.extension.InstallError: Unrecognized type for awekas.zip

*Rémy LAVABRE*


Le jeu. 29 févr. 2024 à 01:52, Tom Keffer  a écrit :

> I haven't tried it, but I'm thinking the problem is that the awekas
> extension uses
>
> *from setup import ExtensionInstaller*
>
>
> which has been deprecated for a long time and will no longer work with V5.
> It should be
>
> *from weecfg.extension import ExtensionInstaller*
>
>
> Try modifying the extension and see if that helps.
>
> On Wed, Feb 28, 2024 at 12:32 AM gjr80  wrote:
>
>> What does unzip -l AWEKAS.zip show? Does bin/user/awekaswx.py actually
>> exist in the zip file?
>>
>> Gary
>> On Wednesday 28 February 2024 at 17:54:49 UTC+10 remy.l...@gmail.com
>> wrote:
>>
>>> Hello Tom,
>>> First problem : when trying to install a driver in virtual
>>> environnement :
>>>
>>> (weewx-venv) remy@remy-virtual-machine:~/weewx-data$ weectl extension
>>> install AWEKAS.zip
>>> Using configuration file /home/remy/weewx-data/weewx.conf
>>> Install extension 'AWEKAS.zip' (y/n)? y
>>> Extracting from zip archive AWEKAS.zip
>>> Traceback (most recent call last):
>>>   File "/home/remy/weewx-venv/bin/weectl", line 8, in 
>>> sys.exit(main())
>>>   File "/home/remy/weewx-venv/lib/python3.8/site-packages/weectl.py",
>>> line 66, in main
>>> namespace.func(namespace)
>>>   File
>>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weectllib/__init__.py",
>>> line 121, in dispatch
>>> namespace.action_func(config_dict, namespace)
>>>   File
>>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weectllib/extension_cmd.py",
>>> line 116, in install_extension
>>> ext.install_extension(namespace.source, no_confirm=namespace.yes)
>>>   File
>>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py",
>>> line 138, in install_extension
>>> extension_name = self._install_from_file(extension_path, filetype)
>>>   File
>>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py",
>>> line 168, in _install_from_file
>>> extension_name = self.install_from_dir(extension_dir)
>>>   File
>>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py",
>>> line 185, in install_from_dir
>>> self._install_files(installer['files'], extension_dir)
>>>   File
>>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py",
>>> line 269, in _install_files
>>> shutil.copy(source_path, destination_path)
>>>   File "/usr/lib/python3.8/shutil.py", line 418, in copy
>>> copyfile(src, dst, follow_symlinks=follow_symlinks)
>>>   File "/usr/lib/python3.8/shutil.py", line 264, in copyfile
>>> with open(src, 'rb') as fsrc, open(dst, 'wb') as fdst:
>>> FileNotFoundError: [Errno 2] No such file or directory:
>>> '/tmp/tmprpxo6tw5/AWEKAS/bin/user/awekaswx.py'
>>>
>>> *and the install.py :*
>>>
>>> # installer for Awekas Bresser awekaswx driver
>>> # Copyright 2024 Remy LAVABRE
>>>
>>> from setup import ExtensionInstaller
>>>
>>> def loader():
>>> return awekaswxInstaller()
>>>
>>> class awekaswxInstaller(ExtensionInstaller):
>>> def __init__(self):
>>> super(awekaswxInstaller, self).__init__(
>>> version="1.3",
>>> name='awekaswx',
>>> description='Get Bresser 7in1 data on Awekas',
>>> author="Remy LAVABRE",
>>> author_email="remy.l...@gmail.com",
>>> files=[('bin/user', ['bin/user/awekaswx.py'])],
>>> config={
>>> 'awekaswx': {
>>> 'driver' : 'bin.user.awekaswx',
>>> 

Re: [weewx-user] Broken installation after upgrade to v5.0.2

2024-02-28 Thread fLsh
ok funny, after a reboot, v.5.0.2 is getting loaded.
Error is now:
-- Logs begin at Thu 2024-02-29 00:06:39 CET, end at Thu 2024-02-29 
08:06:40 CET. -- 
Feb 29 00:06:53 loxberry systemd[1]: Started WeeWX. 
Feb 29 00:06:56 loxberry weewxd[932]: INFO __main__: Initializing weewxd 
version 5.0.2 
Feb 29 00:06:56 loxberry weewxd[932]: INFO __main__: Command line: 
/usr/share/weewx/weewxd.py /etc/weewx/weewx.conf 
Feb 29 00:06:56 loxberry weewxd[932]: INFO __main__: Using Python 3.7.3 
(default, Oct 11 2023, 09:51:27) 
[GCC 8.3.0] 
Feb 29 00:06:56 loxberry weewxd[932]: INFO __main__: Located at 
/usr/bin/python3 
Feb 29 00:06:56 loxberry weewxd[932]: INFO __main__: Platform 
Linux-4.19.118-v7l+-armv7l-with-debian-10.13 
Feb 29 00:06:56 loxberry weewxd[932]: INFO __main__: Locale: 'de_DE.UTF-8' 
Feb 29 00:06:56 loxberry weewxd[932]: INFO __main__: Entry path: 
/usr/share/weewx/weewxd.py 
Feb 29 00:06:56 loxberry weewxd[932]: INFO __main__: WEEWX_ROOT: /etc/weewx 
Feb 29 00:06:56 loxberry weewxd[932]: INFO __main__: Configuration file: 
/etc/weewx/weewx.conf 
Feb 29 00:06:56 loxberry weewxd[932]: INFO __main__: User module: 
/etc/weewx/bin/user 
Feb 29 00:06:56 loxberry weewxd[932]: INFO __main__: Debug: 0 
Feb 29 00:06:56 loxberry weewxd[932]: INFO weewx.engine: Loading station 
type WeatherLinkLive (user.weatherlink_live) 
Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__: Caught 
unrecoverable exception:
Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__:  'type' object 
is not subscriptable
Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__:  Traceback 
(most recent call last):
Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__:  File 
"/usr/share/weewx/weewxd.py", line 160, in main
Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__:  engine = 
weewx.engine.StdEngine(config_dict)
Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__:  File 
"/usr/share/weewx/weewx/engine.py", line 77, in __init__
Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__:  
self.setupStation(config_dict)
Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__:  File 
"/usr/share/weewx/weewx/engine.py", line 104, in setupStation
Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__:  
__import__(driver)
Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__:  File 
"/etc/weewx/bin/user/weatherlink_live/__init__.py", line 27, in 
Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__:  from 
user.weatherlink_live.configurator import WeatherlinkLiveConfigurator
Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__:  File 
"/etc/weewx/bin/user/weatherlink_live/configurator.py", line 24, in 
Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__:  from 
user.weatherlink_live import configuration
Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__:  File 
"/etc/weewx/bin/user/weatherlink_live/configuration.py", line 24, in 

Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__:  from 
user.weatherlink_live.mappers import TMapping, THMapping, WindMapping, 
RainMapping, SolarMapping, UvMapping, \
Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__:  File 
"/etc/weewx/bin/user/weatherlink_live/mappers.py", line 48, in 
Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__:  class 
AbstractMapping(object):
Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__:  File 
"/etc/weewx/bin/user/weatherlink_live/mappers.py", line 137, in 
AbstractMapping
Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__:  def 
map_table(self) -> Dict[str, Union[str, list[str]]]:
Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__:  TypeError: 
'type' object is not subscriptable
Feb 29 00:06:57 loxberry weewxd[932]: CRITICAL __main__:  Exiting.
Feb 29 00:06:57 loxberry weewxd[932]: Traceback (most recent call last): 
Feb 29 00:06:57 loxberry weewxd[932]: File "/usr/share/weewx/weewxd.py", 
line 265, in  
Feb 29 00:06:57 loxberry weewxd[932]: main() 
Feb 29 00:06:57 loxberry weewxd[932]: File "/usr/share/weewx/weewxd.py", 
line 160, in main 
Feb 29 00:06:57 loxberry weewxd[932]: engine = 
weewx.engine.StdEngine(config_dict) 
Feb 29 00:06:57 loxberry weewxd[932]: File 
"/usr/share/weewx/weewx/engine.py", line 77, in __init__ 
Feb 29 00:06:57 loxberry weewxd[932]: self.setupStation(config_dict) 
Feb 29 00:06:57 loxberry weewxd[932]: File 
"/usr/share/weewx/weewx/engine.py", line 104, in setupStation 
Feb 29 00:06:57 loxberry weewxd[932]: __import__(driver) 
Feb 29 00:06:57 loxberry weewxd[932]: File 
"/etc/weewx/bin/user/weatherlink_live/__init__.py", line 27, in 
Feb 29 00:06:57 loxberry weewxd[932]: from 
user.weatherlink_live.configurator import WeatherlinkLiveConfigurator
Feb 29 00:06:57 loxberry weewxd[932]: File 
"/etc/weewx/bin/user/weatherlink_live/configurator.py", line 24, in 
Feb 29 00:06:57 loxberry weewxd[932]: from user.weatherlink_live import 
configuration
Feb 29 00:06:57 loxberry weewxd[932]: File 
"/etc/weewx/b

Re: [weewx-user] Broken installation after upgrade to v5.0.2

2024-02-28 Thread fLsh
yeah basicaly driver is not running and therefore Data from weatherlink 
Live cannot be read.
But question is, athough 5.0.2 is installed and driver v1.1.3, why are 
those not used and instead, 5.0.1 is being loaded?

Tom Keffer schrieb am Donnerstag, 29. Februar 2024 um 01:31:38 UTC+1:

> I hate to "pass the buck," but this looks like an issue with the new 
> WeatherLink Live driver.
>
> The log entry gets cut off with the phrase "Caus", which I suspect would 
> give you the "cause." Take a look in your log.
>
>
>
>
>
> On Wed, Feb 28, 2024 at 3:03 PM fLsh  wrote:
>
>> Hi folks,
>>
>> I was happily running 4.10.2 on my Raspberry Pi 4 with many changes to 
>> skins, drivers and templates.
>> Today I did an upgrade to 5.0.1 which was running too. Then I so in apt 
>> update that there is a public key missing which I resolved with the 
>> documentation. After that, 5.0.2 was available (or was just a coincidence 
>> maybe) and also upgrade the weatherllink_live driver bei Michael Schantl to 
>> 1.1.3.
>> Now weewx will fail to start with attached error. 
>> In ournalctl I can see, that weewxd v.5.0.1 gets started and old driver 
>> 1.1.3.
>> Can please somone help me on fixing that?
>>
>> In journalctl:
>> -- Logs begin at Wed 2024-02-28 11:14:25 CET, end at Thu 2024-02-29 
>> 00:01:13 CET. -- 
>> Feb 28 11:14:38 loxberry systemd[1]: Started WeeWX. 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Initializing weewxd 
>> version 5.0.1 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Command line: 
>> /usr/share/weewx/weewxd.py /etc/weewx/weewx.conf 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Using Python 3.7.3 
>> (default, Oct 11 2023, 09:51:27) 
>> [GCC 8.3.0] 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Located at 
>> /usr/bin/python3 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Platform 
>> Linux-4.19.118-v7l+-armv7l-with-debian-10.13 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Locale: 
>> 'de_DE.UTF-8' 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Entry path: 
>> /usr/share/weewx/weewxd.py 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: WEEWX_ROOT: 
>> /etc/weewx 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Configuration file: 
>> /etc/weewx/weewx.conf 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: User module: 
>> /etc/weewx/bin/user 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Debug: 0 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: Loading station 
>> type WeatherLinkLive (user.weatherlink_live) 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO user.weatherlink_live: 
>> Initializing driver: WeatherLinkLive v1.0.11 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: StdConvert 
>> target unit is 0x1 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.wxservices: 
>> StdWXCalculate will use data binding wx_binding 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: Archive will use 
>> data binding wx_binding 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: Record 
>> generation will be attempted in 'hardware' 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: Using archive 
>> interval of 300 seconds (specified in weewx configuration) 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.restx: StationRegistry: 
>> Registration not requested. 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.restx: Wunderground-PWS: 
>> Data for station IFELLB13 will be posted 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.restx: PWSweather: 
>> Posting not enabled. 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.restx: CWOP: Posting not 
>> enabled. 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.restx: WOW: Posting not 
>> enabled. 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.restx: AWEKAS: Posting 
>> not enabled. 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: 'pyephem' 
>> detected, extended almanac data is available 
>> Feb 28 11:14:41 loxberry /weewxd.py[234]: lowBattery: LowBattery alarm 
>> enabled. Count threshold is 10 
>> Feb 28 11:14:41 loxberry /weewxd.py[234]: alarm: Alarm set for 
>> expression: 'windGust > 35' 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Starting up weewx 
>> version 5.0.1 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: Using binding 
>> 'wx_binding' to database 'weewx.sdb_new' 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.manager: Starting 
>> backfill of daily summaries 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.manager: Daily summaries 
>> up to date 
>> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: Starting main 
>> packet loop. 
>> Feb 28 11:14:41 loxberry weewxd[234]: ERROR 
>> user.weatherlink_live.davis_http: HTTPConnectionPool(host='192.168.178.36', 
>> port=80): Max retries exceeded with url: /v1/current_conditions (Caus
>> Feb 28 11:14:41 loxberry weewxd[234]: ERROR 
>> user.weatherlink_live.davis_http: HTTP conditio

Re: [weewx-user] Problem with WeeWX5 "driver" directory

2024-02-28 Thread gjr80
I thought we were trying to solve the OPs problem? The OPs problem has 
nothing to do with setuptools (or perhaps more correctly the python 
distutils package); setuptools/distutils is not used in the OPs installer 
and there is no error re distutils in the provided console output. If the 
absence of setuptools/distutils was the issue the error trace would clearly 
identify this.

Sure, I have used distutils in my installers and when run on a system where 
the in-use python version no longer includes distutils (python 3.12 and 
later) the installer will fail - as you found with StackedWindRose.

Gary
On Thursday 29 February 2024 at 13:13:45 UTC+10 vince wrote:

> Dunno Gary but I had to install that for StackedWindRose to get v5 pip to 
> install it successfully here.  Details on the issue I opened on your github 
> repo.
>
> On Wednesday, February 28, 2024 at 5:56:14 PM UTC-8 gjr80 wrote:
>
>> Not quite sure of the relevance of setuptools; if that was the problem 
>> here it would be VERY evident.
>>
>> Gary
>>
>>
>> On Thursday 29 February 2024 at 11:26:15 UTC+10 vince wrote:
>>
>> I found an old extension of Gary’s the other day that needed setuptools 
>> to be able to install it…it has the same old syntax…
>>
>> On Wednesday, February 28, 2024 at 4:52:49 PM UTC-8 Tom Keffer wrote:
>>
>> I haven't tried it, but I'm thinking the problem is that the awekas 
>> extension uses
>>
>> *from setup import ExtensionInstaller*
>>
>>
>> which has been deprecated for a long time and will no longer work with 
>> V5. It should be
>>
>> *from weecfg.extension import ExtensionInstaller*
>>
>>
>> Try modifying the extension and see if that helps.
>>
>> On Wed, Feb 28, 2024 at 12:32 AM gjr80  wrote:
>>
>> What does unzip -l AWEKAS.zip show? Does bin/user/awekaswx.py actually 
>> exist in the zip file?
>>
>> Gary
>> On Wednesday 28 February 2024 at 17:54:49 UTC+10 remy.l...@gmail.com 
>> wrote:
>>
>> Hello Tom,
>> First problem : when trying to install a driver in virtual environnement :
>>
>> (weewx-venv) remy@remy-virtual-machine:~/weewx-data$ weectl extension 
>> install AWEKAS.zip
>> Using configuration file /home/remy/weewx-data/weewx.conf
>> Install extension 'AWEKAS.zip' (y/n)? y
>> Extracting from zip archive AWEKAS.zip
>> Traceback (most recent call last):
>>   File "/home/remy/weewx-venv/bin/weectl", line 8, in 
>> sys.exit(main())
>>   File "/home/remy/weewx-venv/lib/python3.8/site-packages/weectl.py", 
>> line 66, in main
>> namespace.func(namespace)
>>   File 
>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weectllib/__init__.py", 
>> line 121, in dispatch
>> namespace.action_func(config_dict, namespace)
>>   File 
>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weectllib/extension_cmd.py",
>>  
>> line 116, in install_extension
>> ext.install_extension(namespace.source, no_confirm=namespace.yes)
>>   File 
>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
>> line 138, in install_extension
>> extension_name = self._install_from_file(extension_path, filetype)
>>   File 
>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
>> line 168, in _install_from_file
>> extension_name = self.install_from_dir(extension_dir)
>>   File 
>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
>> line 185, in install_from_dir
>> self._install_files(installer['files'], extension_dir)
>>   File 
>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
>> line 269, in _install_files
>> shutil.copy(source_path, destination_path)
>>   File "/usr/lib/python3.8/shutil.py", line 418, in copy
>> copyfile(src, dst, follow_symlinks=follow_symlinks)
>>   File "/usr/lib/python3.8/shutil.py", line 264, in copyfile
>> with open(src, 'rb') as fsrc, open(dst, 'wb') as fdst:
>> FileNotFoundError: [Errno 2] No such file or directory: 
>> '/tmp/tmprpxo6tw5/AWEKAS/bin/user/awekaswx.py'
>>
>> *and the install.py :*
>>
>> # installer for Awekas Bresser awekaswx driver
>> # Copyright 2024 Remy LAVABRE
>>
>> from setup import ExtensionInstaller
>>
>> def loader():
>> return awekaswxInstaller()
>>
>> class awekaswxInstaller(ExtensionInstaller):
>> def __init__(self):
>> super(awekaswxInstaller, self).__init__(
>> version="1.3",
>> name='awekaswx',
>> description='Get Bresser 7in1 data on Awekas',
>> author="Remy LAVABRE",
>> author_email="remy.l...@gmail.com",
>> files=[('bin/user', ['bin/user/awekaswx.py'])],
>> config={
>> 'awekaswx': {
>> 'driver' : 'bin.user.awekaswx',
>> 'poll_interval': '60',
>> 'awekasapikey' :'My_API_Awekas_Key','
>> 'openweatherapikey': 'My_API_OpenWeather_Key',
>> 'send_syslog': 'True',
>> 'model': 'Bresser 7in1'
>> }
>> }
>

Re: [weewx-user] leap year and span

2024-02-28 Thread František Slimařík
Yes, right

#for $i in $span($day_delta=365).days
#set fDate = $i.dateTime.format("%-d. %B %Y")
$fDate;$i.outTemp.avg.format(add_label=False)
#end for

čt 29. 2. 2024 v 1:49 odesílatel Tom Keffer  napsal:

> I don't know. How are you using the $span() tags? In a loop, I assume?
>
> On Wed, Feb 28, 2024 at 3:25 PM František Slimařík 
> wrote:
>
>> Hello,
>>
>> is it possible that leap year causes issue in span tag? I am using these:
>>
>> $span($day_delta=365).days
>> $span($year_delta=1).months
>>
>> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
>> weewx.cheetahgenerator: Evaluation of template
>> /etc/weewx/skins/neowx/year.html.tmpl failed with exception '> 'ValueError'>'
>> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
>> weewx.cheetahgenerator:  Ignoring template
>> /etc/weewx/skins/neowx/year.html.tmpl
>> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
>> weewx.cheetahgenerator:  Reason: day is out of range for month
>> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
>> weewx.cheetahgenerator:   Traceback (most recent call last):
>> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
>> weewx.cheetahgenerator: File
>> "/usr/share/weewx/weewx/cheetahgenerator.py", line 334, in generate
>> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
>> weewx.cheetahgenerator:   unicode_string =
>> compiled_template.respond()
>> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
>> weewx.cheetahgenerator: File
>> "_etc_weewx_skins_neowx_year_html_tmpl.py", line 1380, in respond
>> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
>> weewx.cheetahgenerator: File "/usr/share/weewx/weewx/tags.py", line
>> 132, in span
>> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
>> weewx.cheetahgenerator:   year_delta=year_delta, boundary=boundary),
>> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
>> weewx.cheetahgenerator: File "/usr/share/weewx/weeutil/weeutil.py",
>> line 402, in archiveSpanSpan
>> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
>> weewx.cheetahgenerator:   start_dt = time_dt.replace(year=year,
>> month=month)
>> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
>> weewx.cheetahgenerator:   ValueError: day is out of range for month
>>
>> --
>> 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+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/weewx-user/6ca52acb-9235-4154-9e01-ba5e23a9750dn%40googlegroups.com
>> 
>> .
>>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "weewx-user" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/weewx-user/7c8sNahwkiw/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> weewx-user+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/weewx-user/CAPq0zECBN016YJK8gbzfY_gM4rjGFxmFUDmjpHWEdGcfTH2Tog%40mail.gmail.com
> 
> .
>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/CAPXATBW0bD_xgqW9m0q0yQ2JzoFB3uJmJv77ARyzM_dF-4ajOQ%40mail.gmail.com.


Re: [weewx-user] Problem with WeeWX5 "driver" directory

2024-02-28 Thread vince
Dunno Gary but I had to install that for StackedWindRose to get v5 pip to 
install it successfully here.  Details on the issue I opened on your github 
repo.

On Wednesday, February 28, 2024 at 5:56:14 PM UTC-8 gjr80 wrote:

> Not quite sure of the relevance of setuptools; if that was the problem 
> here it would be VERY evident.
>
> Gary
>
>
> On Thursday 29 February 2024 at 11:26:15 UTC+10 vince wrote:
>
> I found an old extension of Gary’s the other day that needed setuptools to 
> be able to install it…it has the same old syntax…
>
> On Wednesday, February 28, 2024 at 4:52:49 PM UTC-8 Tom Keffer wrote:
>
> I haven't tried it, but I'm thinking the problem is that the awekas 
> extension uses
>
> *from setup import ExtensionInstaller*
>
>
> which has been deprecated for a long time and will no longer work with V5. 
> It should be
>
> *from weecfg.extension import ExtensionInstaller*
>
>
> Try modifying the extension and see if that helps.
>
> On Wed, Feb 28, 2024 at 12:32 AM gjr80  wrote:
>
> What does unzip -l AWEKAS.zip show? Does bin/user/awekaswx.py actually 
> exist in the zip file?
>
> Gary
> On Wednesday 28 February 2024 at 17:54:49 UTC+10 remy.l...@gmail.com 
> wrote:
>
> Hello Tom,
> First problem : when trying to install a driver in virtual environnement :
>
> (weewx-venv) remy@remy-virtual-machine:~/weewx-data$ weectl extension 
> install AWEKAS.zip
> Using configuration file /home/remy/weewx-data/weewx.conf
> Install extension 'AWEKAS.zip' (y/n)? y
> Extracting from zip archive AWEKAS.zip
> Traceback (most recent call last):
>   File "/home/remy/weewx-venv/bin/weectl", line 8, in 
> sys.exit(main())
>   File "/home/remy/weewx-venv/lib/python3.8/site-packages/weectl.py", line 
> 66, in main
> namespace.func(namespace)
>   File 
> "/home/remy/weewx-venv/lib/python3.8/site-packages/weectllib/__init__.py", 
> line 121, in dispatch
> namespace.action_func(config_dict, namespace)
>   File 
> "/home/remy/weewx-venv/lib/python3.8/site-packages/weectllib/extension_cmd.py",
>  
> line 116, in install_extension
> ext.install_extension(namespace.source, no_confirm=namespace.yes)
>   File 
> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
> line 138, in install_extension
> extension_name = self._install_from_file(extension_path, filetype)
>   File 
> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
> line 168, in _install_from_file
> extension_name = self.install_from_dir(extension_dir)
>   File 
> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
> line 185, in install_from_dir
> self._install_files(installer['files'], extension_dir)
>   File 
> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
> line 269, in _install_files
> shutil.copy(source_path, destination_path)
>   File "/usr/lib/python3.8/shutil.py", line 418, in copy
> copyfile(src, dst, follow_symlinks=follow_symlinks)
>   File "/usr/lib/python3.8/shutil.py", line 264, in copyfile
> with open(src, 'rb') as fsrc, open(dst, 'wb') as fdst:
> FileNotFoundError: [Errno 2] No such file or directory: 
> '/tmp/tmprpxo6tw5/AWEKAS/bin/user/awekaswx.py'
>
> *and the install.py :*
>
> # installer for Awekas Bresser awekaswx driver
> # Copyright 2024 Remy LAVABRE
>
> from setup import ExtensionInstaller
>
> def loader():
> return awekaswxInstaller()
>
> class awekaswxInstaller(ExtensionInstaller):
> def __init__(self):
> super(awekaswxInstaller, self).__init__(
> version="1.3",
> name='awekaswx',
> description='Get Bresser 7in1 data on Awekas',
> author="Remy LAVABRE",
> author_email="remy.l...@gmail.com",
> files=[('bin/user', ['bin/user/awekaswx.py'])],
> config={
> 'awekaswx': {
> 'driver' : 'bin.user.awekaswx',
> 'poll_interval': '60',
> 'awekasapikey' :'My_API_Awekas_Key','
> 'openweatherapikey': 'My_API_OpenWeather_Key',
> 'send_syslog': 'True',
> 'model': 'Bresser 7in1'
> }
> }
> )
>
> *Rémy LAVABRE*
>
>
> Le dim. 25 févr. 2024 à 22:45, Tom Keffer  a écrit :
>
> From your description, you're installing it in the correct spot, however 
> you're not giving us much information. Instead of just showing the single 
> error line, it would be helpful to see the log from startup. The reason is 
> that it will log the location of the user directory.
>
> Set debug=1, then restart weewxd. Post the log *from startup* through the 
> error.
>
> On Sun, Feb 25, 2024 at 10:55 AM Remy Lavabre  wrote:
>
> Hello,
>
> weewx is installed in virtual PIP mode -> ~/weewx-data/... and 
> ~/weewx-venv/...
> I manually added the xxx.py driver for my weather station in the 
> ~/weewx-data/bin/user directory.
> It is declared in weewx.conf as "driver = usr.xxx", as was done i

Re: [weewx-user] Problem with WeeWX5 "driver" directory

2024-02-28 Thread gjr80
Not quite sure of the relevance of setuptools; if that was the problem here 
it would be VERY evident.

Gary

On Thursday 29 February 2024 at 11:26:15 UTC+10 vince wrote:

I found an old extension of Gary’s the other day that needed setuptools to 
be able to install it…it has the same old syntax…

On Wednesday, February 28, 2024 at 4:52:49 PM UTC-8 Tom Keffer wrote:

I haven't tried it, but I'm thinking the problem is that the awekas 
extension uses

*from setup import ExtensionInstaller*


which has been deprecated for a long time and will no longer work with V5. 
It should be

*from weecfg.extension import ExtensionInstaller*


Try modifying the extension and see if that helps.

On Wed, Feb 28, 2024 at 12:32 AM gjr80  wrote:

What does unzip -l AWEKAS.zip show? Does bin/user/awekaswx.py actually 
exist in the zip file?

Gary
On Wednesday 28 February 2024 at 17:54:49 UTC+10 remy.l...@gmail.com wrote:

Hello Tom,
First problem : when trying to install a driver in virtual environnement :

(weewx-venv) remy@remy-virtual-machine:~/weewx-data$ weectl extension 
install AWEKAS.zip
Using configuration file /home/remy/weewx-data/weewx.conf
Install extension 'AWEKAS.zip' (y/n)? y
Extracting from zip archive AWEKAS.zip
Traceback (most recent call last):
  File "/home/remy/weewx-venv/bin/weectl", line 8, in 
sys.exit(main())
  File "/home/remy/weewx-venv/lib/python3.8/site-packages/weectl.py", line 
66, in main
namespace.func(namespace)
  File 
"/home/remy/weewx-venv/lib/python3.8/site-packages/weectllib/__init__.py", 
line 121, in dispatch
namespace.action_func(config_dict, namespace)
  File 
"/home/remy/weewx-venv/lib/python3.8/site-packages/weectllib/extension_cmd.py", 
line 116, in install_extension
ext.install_extension(namespace.source, no_confirm=namespace.yes)
  File 
"/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
line 138, in install_extension
extension_name = self._install_from_file(extension_path, filetype)
  File 
"/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
line 168, in _install_from_file
extension_name = self.install_from_dir(extension_dir)
  File 
"/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
line 185, in install_from_dir
self._install_files(installer['files'], extension_dir)
  File 
"/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
line 269, in _install_files
shutil.copy(source_path, destination_path)
  File "/usr/lib/python3.8/shutil.py", line 418, in copy
copyfile(src, dst, follow_symlinks=follow_symlinks)
  File "/usr/lib/python3.8/shutil.py", line 264, in copyfile
with open(src, 'rb') as fsrc, open(dst, 'wb') as fdst:
FileNotFoundError: [Errno 2] No such file or directory: 
'/tmp/tmprpxo6tw5/AWEKAS/bin/user/awekaswx.py'

*and the install.py :*

# installer for Awekas Bresser awekaswx driver
# Copyright 2024 Remy LAVABRE

from setup import ExtensionInstaller

def loader():
return awekaswxInstaller()

class awekaswxInstaller(ExtensionInstaller):
def __init__(self):
super(awekaswxInstaller, self).__init__(
version="1.3",
name='awekaswx',
description='Get Bresser 7in1 data on Awekas',
author="Remy LAVABRE",
author_email="remy.l...@gmail.com",
files=[('bin/user', ['bin/user/awekaswx.py'])],
config={
'awekaswx': {
'driver' : 'bin.user.awekaswx',
'poll_interval': '60',
'awekasapikey' :'My_API_Awekas_Key','
'openweatherapikey': 'My_API_OpenWeather_Key',
'send_syslog': 'True',
'model': 'Bresser 7in1'
}
}
)

*Rémy LAVABRE*


Le dim. 25 févr. 2024 à 22:45, Tom Keffer  a écrit :

>From your description, you're installing it in the correct spot, however 
you're not giving us much information. Instead of just showing the single 
error line, it would be helpful to see the log from startup. The reason is 
that it will log the location of the user directory.

Set debug=1, then restart weewxd. Post the log *from startup* through the 
error.

On Sun, Feb 25, 2024 at 10:55 AM Remy Lavabre  wrote:

Hello,

weewx is installed in virtual PIP mode -> ~/weewx-data/... and 
~/weewx-venv/...
I manually added the xxx.py driver for my weather station in the 
~/weewx-data/bin/user directory.
It is declared in weewx.conf as "driver = usr.xxx", as was done in version 
4.x

When launching weewxd, I get the message:
   File "/home/pi/weewx-venv/lib/python3.8/site-packages/weewx/engine.py", 
line 104, in setupStation
 __import__(driver)
ModuleNotFoundError: *No module named 'usr'*

I tried "driver = xxx.py" without success

if I put my driver in 
~/weewx-venv/lib/python3.8/site-packages/weewx/drivers/xxx.py and I put 
driver = xxx.py in weewx.conf there is no longer the error.

Moral: Would it be possible to tell m

Re: [weewx-user] Problem with WeeWX5 "driver" directory

2024-02-28 Thread gjr80
Not quite sure this is the problem, as far as I know the following gives 
backward compatibility with setup.ExtensionInstaller:

# Very old extensions did:
#   from setup import ExtensionInstaller
# Redirect references to 'setup' to me instead.
sys.modules['setup'] = sys.modules[__name__]

Plus I am still using the old style in the Ecowitt driver installer which 
works just fine under v5 and python 3.6+.

Gary
On Thursday 29 February 2024 at 10:52:49 UTC+10 tke...@gmail.com wrote:

> I haven't tried it, but I'm thinking the problem is that the awekas 
> extension uses
>
> *from setup import ExtensionInstaller*
>
>
> which has been deprecated for a long time and will no longer work with V5. 
> It should be
>
> *from weecfg.extension import ExtensionInstaller*
>
>
> Try modifying the extension and see if that helps.
>
> On Wed, Feb 28, 2024 at 12:32 AM gjr80  wrote:
>
>> What does unzip -l AWEKAS.zip show? Does bin/user/awekaswx.py actually 
>> exist in the zip file?
>>
>> Gary
>> On Wednesday 28 February 2024 at 17:54:49 UTC+10 remy.l...@gmail.com 
>> wrote:
>>
>>> Hello Tom,
>>> First problem : when trying to install a driver in virtual 
>>> environnement :
>>>
>>> (weewx-venv) remy@remy-virtual-machine:~/weewx-data$ weectl extension 
>>> install AWEKAS.zip
>>> Using configuration file /home/remy/weewx-data/weewx.conf
>>> Install extension 'AWEKAS.zip' (y/n)? y
>>> Extracting from zip archive AWEKAS.zip
>>> Traceback (most recent call last):
>>>   File "/home/remy/weewx-venv/bin/weectl", line 8, in 
>>> sys.exit(main())
>>>   File "/home/remy/weewx-venv/lib/python3.8/site-packages/weectl.py", 
>>> line 66, in main
>>> namespace.func(namespace)
>>>   File 
>>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weectllib/__init__.py", 
>>> line 121, in dispatch
>>> namespace.action_func(config_dict, namespace)
>>>   File 
>>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weectllib/extension_cmd.py",
>>>  
>>> line 116, in install_extension
>>> ext.install_extension(namespace.source, no_confirm=namespace.yes)
>>>   File 
>>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
>>> line 138, in install_extension
>>> extension_name = self._install_from_file(extension_path, filetype)
>>>   File 
>>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
>>> line 168, in _install_from_file
>>> extension_name = self.install_from_dir(extension_dir)
>>>   File 
>>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
>>> line 185, in install_from_dir
>>> self._install_files(installer['files'], extension_dir)
>>>   File 
>>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
>>> line 269, in _install_files
>>> shutil.copy(source_path, destination_path)
>>>   File "/usr/lib/python3.8/shutil.py", line 418, in copy
>>> copyfile(src, dst, follow_symlinks=follow_symlinks)
>>>   File "/usr/lib/python3.8/shutil.py", line 264, in copyfile
>>> with open(src, 'rb') as fsrc, open(dst, 'wb') as fdst:
>>> FileNotFoundError: [Errno 2] No such file or directory: 
>>> '/tmp/tmprpxo6tw5/AWEKAS/bin/user/awekaswx.py'
>>>
>>> *and the install.py :*
>>>
>>> # installer for Awekas Bresser awekaswx driver
>>> # Copyright 2024 Remy LAVABRE
>>>
>>> from setup import ExtensionInstaller
>>>
>>> def loader():
>>> return awekaswxInstaller()
>>>
>>> class awekaswxInstaller(ExtensionInstaller):
>>> def __init__(self):
>>> super(awekaswxInstaller, self).__init__(
>>> version="1.3",
>>> name='awekaswx',
>>> description='Get Bresser 7in1 data on Awekas',
>>> author="Remy LAVABRE",
>>> author_email="remy.l...@gmail.com",
>>> files=[('bin/user', ['bin/user/awekaswx.py'])],
>>> config={
>>> 'awekaswx': {
>>> 'driver' : 'bin.user.awekaswx',
>>> 'poll_interval': '60',
>>> 'awekasapikey' :'My_API_Awekas_Key','
>>> 'openweatherapikey': 'My_API_OpenWeather_Key',
>>> 'send_syslog': 'True',
>>> 'model': 'Bresser 7in1'
>>> }
>>> }
>>> )
>>>
>>> *Rémy LAVABRE*
>>>
>>>
>>> Le dim. 25 févr. 2024 à 22:45, Tom Keffer  a écrit :
>>>
 From your description, you're installing it in the correct spot, 
 however you're not giving us much information. Instead of just showing the 
 single error line, it would be helpful to see the log from startup. The 
 reason is that it will log the location of the user directory.

 Set debug=1, then restart weewxd. Post the log *from startup* through 
 the error.

 On Sun, Feb 25, 2024 at 10:55 AM Remy Lavabre  
 wrote:

> Hello,
>
> weewx is installed in virtual PIP mode -> ~/weewx-data/... and 
> ~/weewx-venv/...
> I manually added the xxx.py driver for my weather station in the 

Re: [weewx-user] Problem with WeeWX5 "driver" directory

2024-02-28 Thread vince
I found an old extension of Gary’s the other day that needed setuptools to 
be able to install it…it has the same old syntax…

On Wednesday, February 28, 2024 at 4:52:49 PM UTC-8 Tom Keffer wrote:

> I haven't tried it, but I'm thinking the problem is that the awekas 
> extension uses
>
> *from setup import ExtensionInstaller*
>
>
> which has been deprecated for a long time and will no longer work with V5. 
> It should be
>
> *from weecfg.extension import ExtensionInstaller*
>
>
> Try modifying the extension and see if that helps.
>
> On Wed, Feb 28, 2024 at 12:32 AM gjr80  wrote:
>
>> What does unzip -l AWEKAS.zip show? Does bin/user/awekaswx.py actually 
>> exist in the zip file?
>>
>> Gary
>> On Wednesday 28 February 2024 at 17:54:49 UTC+10 remy.l...@gmail.com 
>> wrote:
>>
>>> Hello Tom,
>>> First problem : when trying to install a driver in virtual 
>>> environnement :
>>>
>>> (weewx-venv) remy@remy-virtual-machine:~/weewx-data$ weectl extension 
>>> install AWEKAS.zip
>>> Using configuration file /home/remy/weewx-data/weewx.conf
>>> Install extension 'AWEKAS.zip' (y/n)? y
>>> Extracting from zip archive AWEKAS.zip
>>> Traceback (most recent call last):
>>>   File "/home/remy/weewx-venv/bin/weectl", line 8, in 
>>> sys.exit(main())
>>>   File "/home/remy/weewx-venv/lib/python3.8/site-packages/weectl.py", 
>>> line 66, in main
>>> namespace.func(namespace)
>>>   File 
>>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weectllib/__init__.py", 
>>> line 121, in dispatch
>>> namespace.action_func(config_dict, namespace)
>>>   File 
>>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weectllib/extension_cmd.py",
>>>  
>>> line 116, in install_extension
>>> ext.install_extension(namespace.source, no_confirm=namespace.yes)
>>>   File 
>>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
>>> line 138, in install_extension
>>> extension_name = self._install_from_file(extension_path, filetype)
>>>   File 
>>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
>>> line 168, in _install_from_file
>>> extension_name = self.install_from_dir(extension_dir)
>>>   File 
>>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
>>> line 185, in install_from_dir
>>> self._install_files(installer['files'], extension_dir)
>>>   File 
>>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
>>> line 269, in _install_files
>>> shutil.copy(source_path, destination_path)
>>>   File "/usr/lib/python3.8/shutil.py", line 418, in copy
>>> copyfile(src, dst, follow_symlinks=follow_symlinks)
>>>   File "/usr/lib/python3.8/shutil.py", line 264, in copyfile
>>> with open(src, 'rb') as fsrc, open(dst, 'wb') as fdst:
>>> FileNotFoundError: [Errno 2] No such file or directory: 
>>> '/tmp/tmprpxo6tw5/AWEKAS/bin/user/awekaswx.py'
>>>
>>> *and the install.py :*
>>>
>>> # installer for Awekas Bresser awekaswx driver
>>> # Copyright 2024 Remy LAVABRE
>>>
>>> from setup import ExtensionInstaller
>>>
>>> def loader():
>>> return awekaswxInstaller()
>>>
>>> class awekaswxInstaller(ExtensionInstaller):
>>> def __init__(self):
>>> super(awekaswxInstaller, self).__init__(
>>> version="1.3",
>>> name='awekaswx',
>>> description='Get Bresser 7in1 data on Awekas',
>>> author="Remy LAVABRE",
>>> author_email="remy.l...@gmail.com",
>>> files=[('bin/user', ['bin/user/awekaswx.py'])],
>>> config={
>>> 'awekaswx': {
>>> 'driver' : 'bin.user.awekaswx',
>>> 'poll_interval': '60',
>>> 'awekasapikey' :'My_API_Awekas_Key','
>>> 'openweatherapikey': 'My_API_OpenWeather_Key',
>>> 'send_syslog': 'True',
>>> 'model': 'Bresser 7in1'
>>> }
>>> }
>>> )
>>>
>>> *Rémy LAVABRE*
>>>
>>>
>>> Le dim. 25 févr. 2024 à 22:45, Tom Keffer  a écrit :
>>>
 From your description, you're installing it in the correct spot, 
 however you're not giving us much information. Instead of just showing the 
 single error line, it would be helpful to see the log from startup. The 
 reason is that it will log the location of the user directory.

 Set debug=1, then restart weewxd. Post the log *from startup* through 
 the error.

 On Sun, Feb 25, 2024 at 10:55 AM Remy Lavabre  
 wrote:

> Hello,
>
> weewx is installed in virtual PIP mode -> ~/weewx-data/... and 
> ~/weewx-venv/...
> I manually added the xxx.py driver for my weather station in the 
> ~/weewx-data/bin/user directory.
> It is declared in weewx.conf as "driver = usr.xxx", as was done in 
> version 4.x
>
> When launching weewxd, I get the message:
>File 
> "/home/pi/weewx-venv/lib/python3.8/site-packages/weewx/engine.py", line 
> 104

Re: [weewx-user] Problem with WeeWX5 "driver" directory

2024-02-28 Thread Tom Keffer
I haven't tried it, but I'm thinking the problem is that the awekas
extension uses

*from setup import ExtensionInstaller*


which has been deprecated for a long time and will no longer work with V5.
It should be

*from weecfg.extension import ExtensionInstaller*


Try modifying the extension and see if that helps.

On Wed, Feb 28, 2024 at 12:32 AM gjr80  wrote:

> What does unzip -l AWEKAS.zip show? Does bin/user/awekaswx.py actually
> exist in the zip file?
>
> Gary
> On Wednesday 28 February 2024 at 17:54:49 UTC+10 remy.l...@gmail.com
> wrote:
>
>> Hello Tom,
>> First problem : when trying to install a driver in virtual environnement :
>>
>> (weewx-venv) remy@remy-virtual-machine:~/weewx-data$ weectl extension
>> install AWEKAS.zip
>> Using configuration file /home/remy/weewx-data/weewx.conf
>> Install extension 'AWEKAS.zip' (y/n)? y
>> Extracting from zip archive AWEKAS.zip
>> Traceback (most recent call last):
>>   File "/home/remy/weewx-venv/bin/weectl", line 8, in 
>> sys.exit(main())
>>   File "/home/remy/weewx-venv/lib/python3.8/site-packages/weectl.py",
>> line 66, in main
>> namespace.func(namespace)
>>   File
>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weectllib/__init__.py",
>> line 121, in dispatch
>> namespace.action_func(config_dict, namespace)
>>   File
>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weectllib/extension_cmd.py",
>> line 116, in install_extension
>> ext.install_extension(namespace.source, no_confirm=namespace.yes)
>>   File
>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py",
>> line 138, in install_extension
>> extension_name = self._install_from_file(extension_path, filetype)
>>   File
>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py",
>> line 168, in _install_from_file
>> extension_name = self.install_from_dir(extension_dir)
>>   File
>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py",
>> line 185, in install_from_dir
>> self._install_files(installer['files'], extension_dir)
>>   File
>> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py",
>> line 269, in _install_files
>> shutil.copy(source_path, destination_path)
>>   File "/usr/lib/python3.8/shutil.py", line 418, in copy
>> copyfile(src, dst, follow_symlinks=follow_symlinks)
>>   File "/usr/lib/python3.8/shutil.py", line 264, in copyfile
>> with open(src, 'rb') as fsrc, open(dst, 'wb') as fdst:
>> FileNotFoundError: [Errno 2] No such file or directory:
>> '/tmp/tmprpxo6tw5/AWEKAS/bin/user/awekaswx.py'
>>
>> *and the install.py :*
>>
>> # installer for Awekas Bresser awekaswx driver
>> # Copyright 2024 Remy LAVABRE
>>
>> from setup import ExtensionInstaller
>>
>> def loader():
>> return awekaswxInstaller()
>>
>> class awekaswxInstaller(ExtensionInstaller):
>> def __init__(self):
>> super(awekaswxInstaller, self).__init__(
>> version="1.3",
>> name='awekaswx',
>> description='Get Bresser 7in1 data on Awekas',
>> author="Remy LAVABRE",
>> author_email="remy.l...@gmail.com",
>> files=[('bin/user', ['bin/user/awekaswx.py'])],
>> config={
>> 'awekaswx': {
>> 'driver' : 'bin.user.awekaswx',
>> 'poll_interval': '60',
>> 'awekasapikey' :'My_API_Awekas_Key','
>> 'openweatherapikey': 'My_API_OpenWeather_Key',
>> 'send_syslog': 'True',
>> 'model': 'Bresser 7in1'
>> }
>> }
>> )
>>
>> *Rémy LAVABRE*
>>
>>
>> Le dim. 25 févr. 2024 à 22:45, Tom Keffer  a écrit :
>>
>>> From your description, you're installing it in the correct spot, however
>>> you're not giving us much information. Instead of just showing the single
>>> error line, it would be helpful to see the log from startup. The reason is
>>> that it will log the location of the user directory.
>>>
>>> Set debug=1, then restart weewxd. Post the log *from startup* through
>>> the error.
>>>
>>> On Sun, Feb 25, 2024 at 10:55 AM Remy Lavabre 
>>> wrote:
>>>
 Hello,

 weewx is installed in virtual PIP mode -> ~/weewx-data/... and
 ~/weewx-venv/...
 I manually added the xxx.py driver for my weather station in the
 ~/weewx-data/bin/user directory.
 It is declared in weewx.conf as "driver = usr.xxx", as was done in
 version 4.x

 When launching weewxd, I get the message:
File
 "/home/pi/weewx-venv/lib/python3.8/site-packages/weewx/engine.py", line
 104, in setupStation
  __import__(driver)
 ModuleNotFoundError: *No module named 'usr'*

 I tried "driver = xxx.py" without success

 if I put my driver in
 ~/weewx-venv/lib/python3.8/site-packages/weewx/drivers/xxx.py and I put
 driver = xxx.py in weewx.conf there is no longer the error.

 Moral: Would it be possible to tell me t

Re: [weewx-user] leap year and span

2024-02-28 Thread Tom Keffer
I don't know. How are you using the $span() tags? In a loop, I assume?

On Wed, Feb 28, 2024 at 3:25 PM František Slimařík 
wrote:

> Hello,
>
> is it possible that leap year causes issue in span tag? I am using these:
>
> $span($day_delta=365).days
> $span($year_delta=1).months
>
> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
> weewx.cheetahgenerator: Evaluation of template
> /etc/weewx/skins/neowx/year.html.tmpl failed with exception ' 'ValueError'>'
> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
> weewx.cheetahgenerator:  Ignoring template
> /etc/weewx/skins/neowx/year.html.tmpl
> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
> weewx.cheetahgenerator:  Reason: day is out of range for month
> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
> weewx.cheetahgenerator:   Traceback (most recent call last):
> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
> weewx.cheetahgenerator: File
> "/usr/share/weewx/weewx/cheetahgenerator.py", line 334, in generate
> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
> weewx.cheetahgenerator:   unicode_string =
> compiled_template.respond()
> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
> weewx.cheetahgenerator: File
> "_etc_weewx_skins_neowx_year_html_tmpl.py", line 1380, in respond
> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
> weewx.cheetahgenerator: File "/usr/share/weewx/weewx/tags.py", line
> 132, in span
> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
> weewx.cheetahgenerator:   year_delta=year_delta, boundary=boundary),
> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
> weewx.cheetahgenerator: File "/usr/share/weewx/weeutil/weeutil.py",
> line 402, in archiveSpanSpan
> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
> weewx.cheetahgenerator:   start_dt = time_dt.replace(year=year,
> month=month)
> Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR
> weewx.cheetahgenerator:   ValueError: day is out of range for month
>
> --
> 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+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/weewx-user/6ca52acb-9235-4154-9e01-ba5e23a9750dn%40googlegroups.com
> 
> .
>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/CAPq0zECBN016YJK8gbzfY_gM4rjGFxmFUDmjpHWEdGcfTH2Tog%40mail.gmail.com.


Re: [weewx-user] Broken installation after upgrade to v5.0.2

2024-02-28 Thread Tom Keffer
I hate to "pass the buck," but this looks like an issue with the new
WeatherLink Live driver.

The log entry gets cut off with the phrase "Caus", which I suspect would
give you the "cause." Take a look in your log.





On Wed, Feb 28, 2024 at 3:03 PM fLsh  wrote:

> Hi folks,
>
> I was happily running 4.10.2 on my Raspberry Pi 4 with many changes to
> skins, drivers and templates.
> Today I did an upgrade to 5.0.1 which was running too. Then I so in apt
> update that there is a public key missing which I resolved with the
> documentation. After that, 5.0.2 was available (or was just a coincidence
> maybe) and also upgrade the weatherllink_live driver bei Michael Schantl to
> 1.1.3.
> Now weewx will fail to start with attached error.
> In ournalctl I can see, that weewxd v.5.0.1 gets started and old driver
> 1.1.3.
> Can please somone help me on fixing that?
>
> In journalctl:
> -- Logs begin at Wed 2024-02-28 11:14:25 CET, end at Thu 2024-02-29
> 00:01:13 CET. --
> Feb 28 11:14:38 loxberry systemd[1]: Started WeeWX.
> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Initializing weewxd
> version 5.0.1
> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Command line:
> /usr/share/weewx/weewxd.py /etc/weewx/weewx.conf
> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Using Python 3.7.3
> (default, Oct 11 2023, 09:51:27)
> [GCC 8.3.0]
> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Located at
> /usr/bin/python3
> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Platform
> Linux-4.19.118-v7l+-armv7l-with-debian-10.13
> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Locale: 'de_DE.UTF-8'
> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Entry path:
> /usr/share/weewx/weewxd.py
> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: WEEWX_ROOT:
> /etc/weewx
> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Configuration file:
> /etc/weewx/weewx.conf
> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: User module:
> /etc/weewx/bin/user
> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Debug: 0
> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: Loading station
> type WeatherLinkLive (user.weatherlink_live)
> Feb 28 11:14:41 loxberry weewxd[234]: INFO user.weatherlink_live:
> Initializing driver: WeatherLinkLive v1.0.11
> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: StdConvert target
> unit is 0x1
> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.wxservices:
> StdWXCalculate will use data binding wx_binding
> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: Archive will use
> data binding wx_binding
> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: Record generation
> will be attempted in 'hardware'
> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: Using archive
> interval of 300 seconds (specified in weewx configuration)
> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.restx: StationRegistry:
> Registration not requested.
> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.restx: Wunderground-PWS:
> Data for station IFELLB13 will be posted
> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.restx: PWSweather:
> Posting not enabled.
> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.restx: CWOP: Posting not
> enabled.
> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.restx: WOW: Posting not
> enabled.
> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.restx: AWEKAS: Posting
> not enabled.
> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: 'pyephem'
> detected, extended almanac data is available
> Feb 28 11:14:41 loxberry /weewxd.py[234]: lowBattery: LowBattery alarm
> enabled. Count threshold is 10
> Feb 28 11:14:41 loxberry /weewxd.py[234]: alarm: Alarm set for expression:
> 'windGust > 35'
> Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Starting up weewx
> version 5.0.1
> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: Using binding
> 'wx_binding' to database 'weewx.sdb_new'
> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.manager: Starting
> backfill of daily summaries
> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.manager: Daily summaries
> up to date
> Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: Starting main
> packet loop.
> Feb 28 11:14:41 loxberry weewxd[234]: ERROR
> user.weatherlink_live.davis_http: HTTPConnectionPool(host='192.168.178.36',
> port=80): Max retries exceeded with url: /v1/current_conditions (Caus
> Feb 28 11:14:41 loxberry weewxd[234]: ERROR
> user.weatherlink_live.davis_http: HTTP conditions request failed. Retry #0
> follows shortly
> Feb 28 11:14:44 loxberry weewxd[234]: ERROR
> user.weatherlink_live.davis_http: HTTPConnectionPool(host='192.168.178.36',
> port=80): Max retries exceeded with url: /v1/current_conditions (Caus
> Feb 28 11:14:44 loxberry weewxd[234]: ERROR
> user.weatherlink_live.davis_http: HTTP conditions request failed. Retry #1
> follows shortly
> Feb 28 11:14:47 loxberry weewxd[234]: ERROR
> user.weatherlink_live.davis_http: HTTPConne

[weewx-user] leap year and span

2024-02-28 Thread František Slimařík
Hello,

is it possible that leap year causes issue in span tag? I am using these:

$span($day_delta=365).days
$span($year_delta=1).months

Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR 
weewx.cheetahgenerator: Evaluation of template 
/etc/weewx/skins/neowx/year.html.tmpl failed with exception ''
Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR 
weewx.cheetahgenerator:  Ignoring template 
/etc/weewx/skins/neowx/year.html.tmpl
Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR 
weewx.cheetahgenerator:  Reason: day is out of range for month
Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR 
weewx.cheetahgenerator:   Traceback (most recent call last):
Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR 
weewx.cheetahgenerator: File 
"/usr/share/weewx/weewx/cheetahgenerator.py", line 334, in generate
Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR 
weewx.cheetahgenerator:   unicode_string = 
compiled_template.respond()
Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR 
weewx.cheetahgenerator: File 
"_etc_weewx_skins_neowx_year_html_tmpl.py", line 1380, in respond
Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR 
weewx.cheetahgenerator: File "/usr/share/weewx/weewx/tags.py", line 
132, in span
Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR 
weewx.cheetahgenerator:   year_delta=year_delta, boundary=boundary),
Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR 
weewx.cheetahgenerator: File "/usr/share/weewx/weeutil/weeutil.py", 
line 402, in archiveSpanSpan
Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR 
weewx.cheetahgenerator:   start_dt = time_dt.replace(year=year, 
month=month)
Feb 29 00:10:43 rocky-weather-machine weewxd[405028]: ERROR 
weewx.cheetahgenerator:   ValueError: day is out of range for month

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/6ca52acb-9235-4154-9e01-ba5e23a9750dn%40googlegroups.com.


[weewx-user] Re: WeeWx Upgrade from v4 to v5

2024-02-28 Thread gjr80
The post with the log that shows the error was deleted ?

This look suspiciously like this problem 
. Did 
you some time in the past remove seemingly unused settings from 
[DisplayOptions] in the Seasons skin.conf? It seems that v5 is more 
sensitive to these settings.

GHary

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/8a0f51f1-d932-4e99-bd0b-6fc53da2a084n%40googlegroups.com.


[weewx-user] Broken installation after upgrade to v5.0.2

2024-02-28 Thread fLsh
Hi folks,

I was happily running 4.10.2 on my Raspberry Pi 4 with many changes to 
skins, drivers and templates.
Today I did an upgrade to 5.0.1 which was running too. Then I so in apt 
update that there is a public key missing which I resolved with the 
documentation. After that, 5.0.2 was available (or was just a coincidence 
maybe) and also upgrade the weatherllink_live driver bei Michael Schantl to 
1.1.3.
Now weewx will fail to start with attached error. 
In ournalctl I can see, that weewxd v.5.0.1 gets started and old driver 
1.1.3.
Can please somone help me on fixing that?

In journalctl:
-- Logs begin at Wed 2024-02-28 11:14:25 CET, end at Thu 2024-02-29 
00:01:13 CET. -- 
Feb 28 11:14:38 loxberry systemd[1]: Started WeeWX. 
Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Initializing weewxd 
version 5.0.1 
Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Command line: 
/usr/share/weewx/weewxd.py /etc/weewx/weewx.conf 
Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Using Python 3.7.3 
(default, Oct 11 2023, 09:51:27) 
[GCC 8.3.0] 
Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Located at 
/usr/bin/python3 
Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Platform 
Linux-4.19.118-v7l+-armv7l-with-debian-10.13 
Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Locale: 'de_DE.UTF-8' 
Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Entry path: 
/usr/share/weewx/weewxd.py 
Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: WEEWX_ROOT: /etc/weewx 
Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Configuration file: 
/etc/weewx/weewx.conf 
Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: User module: 
/etc/weewx/bin/user 
Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Debug: 0 
Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: Loading station 
type WeatherLinkLive (user.weatherlink_live) 
Feb 28 11:14:41 loxberry weewxd[234]: INFO user.weatherlink_live: 
Initializing driver: WeatherLinkLive v1.0.11 
Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: StdConvert target 
unit is 0x1 
Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.wxservices: StdWXCalculate 
will use data binding wx_binding 
Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: Archive will use 
data binding wx_binding 
Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: Record generation 
will be attempted in 'hardware' 
Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: Using archive 
interval of 300 seconds (specified in weewx configuration) 
Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.restx: StationRegistry: 
Registration not requested. 
Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.restx: Wunderground-PWS: 
Data for station IFELLB13 will be posted 
Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.restx: PWSweather: Posting 
not enabled. 
Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.restx: CWOP: Posting not 
enabled. 
Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.restx: WOW: Posting not 
enabled. 
Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.restx: AWEKAS: Posting not 
enabled. 
Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: 'pyephem' 
detected, extended almanac data is available 
Feb 28 11:14:41 loxberry /weewxd.py[234]: lowBattery: LowBattery alarm 
enabled. Count threshold is 10 
Feb 28 11:14:41 loxberry /weewxd.py[234]: alarm: Alarm set for expression: 
'windGust > 35' 
Feb 28 11:14:41 loxberry weewxd[234]: INFO __main__: Starting up weewx 
version 5.0.1 
Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: Using binding 
'wx_binding' to database 'weewx.sdb_new' 
Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.manager: Starting backfill 
of daily summaries 
Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.manager: Daily summaries 
up to date 
Feb 28 11:14:41 loxberry weewxd[234]: INFO weewx.engine: Starting main 
packet loop. 
Feb 28 11:14:41 loxberry weewxd[234]: ERROR 
user.weatherlink_live.davis_http: HTTPConnectionPool(host='192.168.178.36', 
port=80): Max retries exceeded with url: /v1/current_conditions (Caus
Feb 28 11:14:41 loxberry weewxd[234]: ERROR 
user.weatherlink_live.davis_http: HTTP conditions request failed. Retry #0 
follows shortly
Feb 28 11:14:44 loxberry weewxd[234]: ERROR 
user.weatherlink_live.davis_http: HTTPConnectionPool(host='192.168.178.36', 
port=80): Max retries exceeded with url: /v1/current_conditions (Caus
Feb 28 11:14:44 loxberry weewxd[234]: ERROR 
user.weatherlink_live.davis_http: HTTP conditions request failed. Retry #1 
follows shortly
Feb 28 11:14:47 loxberry weewxd[234]: ERROR 
user.weatherlink_live.davis_http: HTTPConnectionPool(host='192.168.178.36', 
port=80): Max retries exceeded with url: /v1/current_conditions (Caus
Feb 28 11:14:47 loxberry weewxd[234]: ERROR 
user.weatherlink_live.davis_http: HTTP conditions request failed. Retry #2 
follows shortly
Feb 28 11:14:49 loxberry weewxd[234]: ERROR 
user.weatherlink_live.scheduler: Error caught in scheduler tick. Not 
rescheduling
Feb 

[weewx-user] Re: WeeWx Upgrade from v4 to v5

2024-02-28 Thread vince
Did you modify the Seasons skin at all ? 

...and your log has your PWS password in it :-(

You might try enabling the Standard skin as a test and see if that works. 
 It's less automagical.  That would be a good data point.  Move it above 
Seasons in weewx.conf so it runs and hopefully succeeds before Seasons goes 
boom.  Make sure it writes to a subdirectory in your docroot so you don't 
overwrite previous successful runs.  You might want to seed the NOAA tree 
under there too to speed the test up.

Other thing to try would be to stash your skins tree (just in case) and try 
'*weectl station upgrade --what skins*' as per the upgrade guide 
(https://www.weewx.com/docs/5.0/quickstarts/pip/#customize) under the .deb 
tab there and use a known vanilla current Seasons skin.  You'll lose any 
customizations you might have made, but you'd know your db is ok if that 
works.  That instruction is not in the .deb upgrade section but it should 
work the same.  Your old skins 'should' be saved with a timestamped 
directory name for reverting if needed.

On Wednesday, February 28, 2024 at 2:11:21 PM UTC-8 Pete AndDebbie wrote:

> More Detailed Log
>
> (this from below log - might have something to do with it...)
> (  Feb 28 16:05:20 46141 weewxd[646]: ERROR weewx.cheetahgenerator: 
> Evaluation of template /etc/weewx/skins/Seasons/index.html.tmpl failed with 
> exception ''  )
>
>
>
> Feb 28 16:01:08 46141 weewxd[646]: DEBUG weeutil.ftpupload: Uploaded file 
> /var/www/html/weewx/smartphone/dayrain.png to /htdocs/smartphone/dayrain.png
> Feb 28 16:01:08 46141 weewxd[646]: DEBUG weeutil.ftpupload: 41 
> ./smartphone/weekhumidity.png 
> 307a070d48fb7e4de8a780b6239311648b03ab9685ef33d3f5d3a34825770be1
> Feb 28 16:01:08 46141 weewxd[646]: DEBUG weeutil.ftpupload: Uploaded file 
> /var/www/html/weewx/smartphone/weekhumidity.png to 
> /htdocs/smartphone/weekhumidity.png
> Feb 28 16:01:08 46141 weewxd[646]: DEBUG weeutil.ftpupload: 42 
> ./smartphone/weektempdew.png 
> 5da5f102ba22d0f71e29e7089cff8668958bf55eba9245dab375ec0b0ce65c0a
> Feb 28 16:01:09 46141 weewxd[646]: DEBUG weeutil.ftpupload: Uploaded file 
> /var/www/html/weewx/smartphone/weektempdew.png to 
> /htdocs/smartphone/weektempdew.png
> Feb 28 16:01:09 46141 weewxd[646]: DEBUG weeutil.ftpupload: 43 
> ./smartphone/weekrain.png 
> 4d1e938a7baa9ed1f2a4272ecf4402fd6f156e574cb9d75c6c572871ecfbe5ec
> Feb 28 16:01:10 46141 weewxd[646]: DEBUG weeutil.ftpupload: Uploaded file 
> /var/www/html/weewx/smartphone/weekrain.png to 
> /htdocs/smartphone/weekrain.png
> Feb 28 16:01:11 46141 weewxd[646]: INFO weewx.reportengine: ftpgenerator: 
> Ftp'd 44 files in 38.65 seconds
> Feb 28 16:01:11 46141 weewxd[646]: DEBUG weewx.reportengine: Report 
> 'RSYNC' not enabled. Skipping.
> Feb 28 16:01:11 46141 systemd[1]: session-3.scope: Succeeded.
> Feb 28 16:02:15 46141 systemd[1]: Started Session 5 of user root.
> Feb 28 16:05:01 46141 CRON[1435]: (root) CMD (/webcam/ftpfile.sh)
> Feb 28 16:05:11 46141 CRON[1434]: (CRON) info (No MTA installed, 
> discarding output)
> Feb 28 16:05:18 46141 weewxd[646]: INFO weewx.manager: Added record 
> 2024-02-28 16:05:00 CST (1709157900) to database 'weewx.sdb'
> Feb 28 16:05:18 46141 weewxd[646]: INFO weewx.manager: Added record 
> 2024-02-28 16:05:00 CST (1709157900) to daily summary in 'weewx.sdb'
> Feb 28 16:05:18 46141 weewxd[646]: DEBUG weewx.reportengine: Running 
> reports for latest time in the database.
> Feb 28 16:05:18 46141 /weewxd.py: weatherflowudp: MainThread: Listening 
> for UDP broadcasts to IP address 255.255.255.255 on port 50222, with 
> timeout 90 and share_socket False...
> Feb 28 16:05:18 46141 weewxd[646]: DEBUG weewx.reportengine: Running 
> report 'SeasonsReport'
> Feb 28 16:05:18 46141 weewxd[646]: DEBUG weewx.restx: CWOP: wait interval 
> (300 < 600) has not passed for record 2024-02-28 16:05:00 CST (1709157900)
> Feb 28 16:05:18 46141 weewxd[646]: DEBUG weewx.restx: Ambient: url: 
> https://weatherstation.wunderground.com/weatherstation/updateweatherstation.php?action=updateraw&ID=KFLPENSA303&PASSWORD=XXX&softwaretype=weewx-5.0.2&baromin=30.050&dateutc=2024-02-28%2022%3A05%3A00&dailyrainin=0.00&dewptf=66.6&rainin=0.00&humidity=085&tempf=71.2&solarradiation=126.80&UV=0.87&winddir=234&windgustmph=6.6&windspeedmph=2.9
> Feb 28 16:05:18 46141 weewxd[646]: DEBUG weewx.restx: Wunderground-PWS 
> url: '
> https://weatherstation.wunderground.com/weatherstation/updateweatherstation.php?action=updateraw&ID=KFLPENSA303&PASSWORD=r33mGg7W&softwaretype=weewx-5.0.2&baromin=30.050&dateutc=2024-02-28%2022%3A05%3A00&dailyrainin=0.00&dewptf=66.6&rainin=0.00&humidity=085&tempf=71.2&solarradiation=126.80&UV=0.87&winddir=234&windgustmph=6.6&windspeedmph=2.9
> '
> Feb 28 16:05:18 46141 weewxd[646]: DEBUG weewx.reportengine: Found 
> configuration file /etc/weewx/skins/Seasons/skin.conf for report 
> 'SeasonsReport'
> Feb 28 16:05:18 46141 weewxd[646]: DEBUG weewx.reportengine: Running 
> generators for report 'SeasonsReport' in directory 

[weewx-user] Re: WeeWx Upgrade from v4 to v5

2024-02-28 Thread Pete AndDebbie
More Detailed Log

(this from below log - might have something to do with it...)
(  Feb 28 16:05:20 46141 weewxd[646]: ERROR weewx.cheetahgenerator: 
Evaluation of template /etc/weewx/skins/Seasons/index.html.tmpl failed with 
exception ''  )



Feb 28 16:01:08 46141 weewxd[646]: DEBUG weeutil.ftpupload: Uploaded file 
/var/www/html/weewx/smartphone/dayrain.png to /htdocs/smartphone/dayrain.png
Feb 28 16:01:08 46141 weewxd[646]: DEBUG weeutil.ftpupload: 41 
./smartphone/weekhumidity.png 
307a070d48fb7e4de8a780b6239311648b03ab9685ef33d3f5d3a34825770be1
Feb 28 16:01:08 46141 weewxd[646]: DEBUG weeutil.ftpupload: Uploaded file 
/var/www/html/weewx/smartphone/weekhumidity.png to 
/htdocs/smartphone/weekhumidity.png
Feb 28 16:01:08 46141 weewxd[646]: DEBUG weeutil.ftpupload: 42 
./smartphone/weektempdew.png 
5da5f102ba22d0f71e29e7089cff8668958bf55eba9245dab375ec0b0ce65c0a
Feb 28 16:01:09 46141 weewxd[646]: DEBUG weeutil.ftpupload: Uploaded file 
/var/www/html/weewx/smartphone/weektempdew.png to 
/htdocs/smartphone/weektempdew.png
Feb 28 16:01:09 46141 weewxd[646]: DEBUG weeutil.ftpupload: 43 
./smartphone/weekrain.png 
4d1e938a7baa9ed1f2a4272ecf4402fd6f156e574cb9d75c6c572871ecfbe5ec
Feb 28 16:01:10 46141 weewxd[646]: DEBUG weeutil.ftpupload: Uploaded file 
/var/www/html/weewx/smartphone/weekrain.png to 
/htdocs/smartphone/weekrain.png
Feb 28 16:01:11 46141 weewxd[646]: INFO weewx.reportengine: ftpgenerator: 
Ftp'd 44 files in 38.65 seconds
Feb 28 16:01:11 46141 weewxd[646]: DEBUG weewx.reportengine: Report 'RSYNC' 
not enabled. Skipping.
Feb 28 16:01:11 46141 systemd[1]: session-3.scope: Succeeded.
Feb 28 16:02:15 46141 systemd[1]: Started Session 5 of user root.
Feb 28 16:05:01 46141 CRON[1435]: (root) CMD (/webcam/ftpfile.sh)
Feb 28 16:05:11 46141 CRON[1434]: (CRON) info (No MTA installed, discarding 
output)
Feb 28 16:05:18 46141 weewxd[646]: INFO weewx.manager: Added record 
2024-02-28 16:05:00 CST (1709157900) to database 'weewx.sdb'
Feb 28 16:05:18 46141 weewxd[646]: INFO weewx.manager: Added record 
2024-02-28 16:05:00 CST (1709157900) to daily summary in 'weewx.sdb'
Feb 28 16:05:18 46141 weewxd[646]: DEBUG weewx.reportengine: Running 
reports for latest time in the database.
Feb 28 16:05:18 46141 /weewxd.py: weatherflowudp: MainThread: Listening for 
UDP broadcasts to IP address 255.255.255.255 on port 50222, with timeout 90 
and share_socket False...
Feb 28 16:05:18 46141 weewxd[646]: DEBUG weewx.reportengine: Running report 
'SeasonsReport'
Feb 28 16:05:18 46141 weewxd[646]: DEBUG weewx.restx: CWOP: wait interval 
(300 < 600) has not passed for record 2024-02-28 16:05:00 CST (1709157900)
Feb 28 16:05:18 46141 weewxd[646]: DEBUG weewx.restx: Ambient: url: 
https://weatherstation.wunderground.com/weatherstation/updateweatherstation.php?action=updateraw&ID=KFLPENSA303&PASSWORD=XXX&softwaretype=weewx-5.0.2&baromin=30.050&dateutc=2024-02-28%2022%3A05%3A00&dailyrainin=0.00&dewptf=66.6&rainin=0.00&humidity=085&tempf=71.2&solarradiation=126.80&UV=0.87&winddir=234&windgustmph=6.6&windspeedmph=2.9
Feb 28 16:05:18 46141 weewxd[646]: DEBUG weewx.restx: Wunderground-PWS url: 
'https://weatherstation.wunderground.com/weatherstation/updateweatherstation.php?action=updateraw&ID=KFLPENSA303&PASSWORD=r33mGg7W&softwaretype=weewx-5.0.2&baromin=30.050&dateutc=2024-02-28%2022%3A05%3A00&dailyrainin=0.00&dewptf=66.6&rainin=0.00&humidity=085&tempf=71.2&solarradiation=126.80&UV=0.87&winddir=234&windgustmph=6.6&windspeedmph=2.9'
Feb 28 16:05:18 46141 weewxd[646]: DEBUG weewx.reportengine: Found 
configuration file /etc/weewx/skins/Seasons/skin.conf for report 
'SeasonsReport'
Feb 28 16:05:18 46141 weewxd[646]: DEBUG weewx.reportengine: Running 
generators for report 'SeasonsReport' in directory 
'/etc/weewx/skins/Seasons'
Feb 28 16:05:18 46141 weewxd[646]: DEBUG weewx.cheetahgenerator: Using 
search list ['weewx.cheetahgenerator.Almanac', 
'weewx.cheetahgenerator.Current', 'weewx.cheetahgenerator.DisplayOptions', 
'weewx.cheetahgenerator.Extras', 'weewx.cheetahgenerator.Gettext', 
'weewx.cheetahgenerator.JSONHelpers', 'weewx.cheetahgenerator.PlotInfo', 
'weewx.cheetahgenerator.SkinInfo', 'weewx.cheetahgenerator.Station', 
'weewx.cheetahgenerator.Stats', 'weewx.cheetahgenerator.UnitInfo']
Feb 28 16:05:18 46141 weewxd[646]: DEBUG weewx.manager: Daily summary 
version is 4.0
Feb 28 16:05:18 46141 weewxd[646]: INFO weewx.restx: Wunderground-PWS: 
Published record 2024-02-28 16:05:00 CST (1709157900)
Feb 28 16:05:20 46141 weewxd[646]: ERROR weewx.cheetahgenerator: Evaluation 
of template /etc/weewx/skins/Seasons/index.html.tmpl failed with exception 
''
Feb 28 16:05:20 46141 weewxd[646]: ERROR weewx.cheetahgenerator:  
Ignoring template /etc/weewx/skins/Seasons/index.html.tmpl
Feb 28 16:05:20 46141 weewxd[646]: ERROR weewx.cheetahgenerator:  
Reason: near "IS": syntax error
Feb 28 16:05:20 46141 weewxd[646]: ERROR weewx.cheetahgenerator:  
 Traceback (most recent call last):
Feb 28 16:05:20 46141 weewxd[646]: ERROR weewx

[weewx-user] Re: WeeWx Upgrade from v4 to v5

2024-02-28 Thread Pete AndDebbie
Here is the Log...

Did - systemctl weewx stopthen   systemclt weewx startand got 
below...

It was working 100% as version 4  - then upgrade to v5...no joy...

-pete

[image: WeeWx-Log.JPG]

On Wednesday, February 28, 2024 at 3:35:14 PM UTC-6 gjr80 wrote:

> Impossible to say without a log extract 
> 
> .
>
> Gary
>
> On Thursday 29 February 2024 at 07:00:21 UTC+10 debbiep...@gmail.com 
> wrote:
>
>> Have a strange problem after upgrading working WeeWx from v4 to v5
>>
>> See attached .JPG screen shot...
>> If you look closely, you can see the standard Graphs still being updated 
>> HOWEVER the Left Column of weather information has not been updated since 
>> 9:10AM today - it's now 3PM as I write this.  Am using the Tempest driver 
>> (works great on v4) can't figure out what I need to (also update?) to make 
>> WeeWx v5 update about every 5 minutes.
>>
>> Any hints?  Anybody else having upgrade issues from v4 to v5?
>>
>> -pete[image: Weewx-Upgrade.JPG]
>>
>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/6c96f12b-6407-4340-becf-0dba7bcdb416n%40googlegroups.com.


[weewx-user] Re: WeeWx Upgrade from v4 to v5

2024-02-28 Thread gjr80
Impossible to say without a log extract 

.

Gary

On Thursday 29 February 2024 at 07:00:21 UTC+10 debbiep...@gmail.com wrote:

> Have a strange problem after upgrading working WeeWx from v4 to v5
>
> See attached .JPG screen shot...
> If you look closely, you can see the standard Graphs still being updated 
> HOWEVER the Left Column of weather information has not been updated since 
> 9:10AM today - it's now 3PM as I write this.  Am using the Tempest driver 
> (works great on v4) can't figure out what I need to (also update?) to make 
> WeeWx v5 update about every 5 minutes.
>
> Any hints?  Anybody else having upgrade issues from v4 to v5?
>
> -pete[image: Weewx-Upgrade.JPG]
>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/9e54ad39-7b8a-4248-963c-4b06ff858dd0n%40googlegroups.com.


Re: [weewx-user] I'm desperate to fix my NOAA reports. Can I please pay someone to help fix my database and recover this data?

2024-02-28 Thread vince
I don't know why, but my reply was deleted by Google.   I did a test and 
your commands look ok and worked for me here, so you might want to check 
your wpm.conf file for errors.  You need a wpm_binding stanza defined under 
DataBindings and that database defined under Databases.

Post your [DataBindings] and [Databases] sections of wpm.conf if you can't 
see any errors.

It should look like the following.  The DataBindings tag's database needs 
to point to a defined tag under Databases

[DataBindings]
[[wpm_binding]]
database = archive_sqlite_wpm
table_name = archive
manager = weewx.manager.DaySummaryManager
schema = schemas.wview_extended.schema

[Databases]
[[archive_sqlite_wpm]]
database_name = wpm.sdb
database_type = SQLite

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/14958239-795d-4c8e-946a-e762bb2030bdn%40googlegroups.com.


[weewx-user] Re: Apt update source for weewx.

2024-02-28 Thread didier....@gmail.com
Hi again

Problem solved 

We need to re-import keys by this command:
curl -sSf 'https://weewx.com/keys.html' | sudo gpg --dearmor -o 
/etc/apt/trusted.gpg.d/weewx.gpg --yes

Le mercredi 28 février 2024 à 17:16:43 UTC+1, didier@gmail.com a écrit :

> Hi
>
> I have upgrade debian 10 to debian 11 bullseye, and I have 
> changed /etc/apt/sources.list.d/weewx.list  with:
> deb [arch=all] http://weewx.com/apt/python3 *buster InRelease*
> instead of deb [arch=all] http://weewx.com/apt/python3 *bullseye main*
>
> But after apt update I have a warning/error about a control of sign in due 
> to a no available public key (NO_PUBKEY E788768B9CB16E10)
>
> Where is my mistake?
>
> Thanks a lot
>
> Le samedi 2 juillet 2022 à 23:47:41 UTC+2, Peter Fletcher a écrit :
>
>> Thanks!
>>
>> On Saturday, July 2, 2022 at 5:38:23 PM UTC-4 matthew wall wrote:
>>
>>> On Saturday, July 2, 2022 at 4:14:37 PM UTC-4 Peter Fletcher wrote:
>>>
 The installation instructions add 'http://weewx.com/apt/python3 
 *buster* InRelease' to apt's list of sources for Debian installs, and 
 this works.

>>>
>>> you can replace 'buster' with whatever you want.
>>>
>>> we do not track specific debian (or ubuntu, or mint, or whatever) 
>>> releases.  basically we target two debian releases: squeeze (for python2) 
>>> and buster (for python3).
>>>
>>> the weewx python2 deb package first worked with debian 6 (squeeze), and 
>>> works with every subsequent debian release until the python2 packages are 
>>> no longer provided.
>>>
>>> the weewx python3 deb package first worked with debian 10 (buster) and 
>>> will continue to work with every subsequent debian release until debian 
>>> breaks the python3 packages.
>>>
>>> m
>>>  
>>>
>>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/f998f0fd-238d-4842-be60-231d325af07an%40googlegroups.com.


Re: [weewx-user] I'm desperate to fix my NOAA reports. Can I please pay someone to help fix my database and recover this data?

2024-02-28 Thread loeriver
I tried to follow the proposal of an extension of the DB schema, but as I 
am using a quite different setup (similar to / derived from the Brultech 
monitor) I failed in the step of updating.

My attempt was to add the until now calculated value "heating_COP" to the 
database.

Adding the column worked:

root@localhost:/home/weewx2# ./bin/weectl database add-column heating_COP 
--config=wpm.conf --binding=wpm_binding
Using configuration file wpm.conf
Add new column 'heating_COP' of type 'REAL' to database 'wpm.sdb' (y/n)? y
New column heating_COP of type REAL added to database.

But updating did not work, it insists in using the default binding that I 
do not use:

root@localhost:/home/weewx2# ./bin/weectl database calc-missing 
--config=wpm.conf --binding=wpm_binding
Using configuration file wpm.conf
Missing derived observations will be calculated for all records.
Proceed (y/n)? y
Calculating missing derived observations...
Error: 'Unknown data binding ''wx_binding'''
Perhaps StdWXCalculate is using a different binding. Check configuration 
file [StdWXCalculate] stanza
Nothing done. Aborting.

Any ideas?

vince schrieb am Sonntag, 25. Februar 2024 um 21:01:22 UTC+1:

> This has come up a lot of times vs. the Seasons skin if that's what you're 
> referring to.  v5 calculates things it expects are available in the db as 
> needed, which is slow.  In most cases adding the columns to the schema 
> makes the problem go away.  This seems to be coming up for folks starting 
> in v3 weewx who are using the original wview-compatible schema rather than 
> the wview_extended bigger schema that first appeared in v4 weewx.
>
> You can check to see if you're already running the extended schema in your 
> db already by just counting the number of fields:
>  echo "SELECT count() FROM PRAGMA_TABLE_INFO('archive');" | 
> sqlite3 weewx.sdb
>
> The extended schema will return a count of 114.   The original schema had 
> around 53 or so if I recall correctly.  If you're weewx 3.x you are 
> probably going to see 53 as your answer.
>
> If you are running the small original schema you can either figure out 
> which columns are missing and add just those, or update your db to the 
> newer/bigger schema and not worry it.  Given you have a fast PC to do this 
> on, personally I'd upgrade the db to the big one.  Doesn't take that long 
> if you throw some compute at it.
>
> On Sunday, February 25, 2024 at 11:30:14 AM UTC-8 loeriver wrote:
>
>> Sorry for this late question:
>>
>> I went through this performance issue also and to have an apples to 
>> apples comparison I set up weewx 4.10.2 and 5.0.2 on the same computer and 
>> had it running with a large db (280MB). 
>>
>> For 4.10.2 file generation takes around 0.3s, for 5.0.2 it takes 13s (on 
>> a well-equipped PC, on my Raspi-type system it is >100s).
>>
>> Following the explanation from Tom Keffer ("... In V4, this would not 
>> have even been attempted." ...) I would expect that in the output for 
>> v4.10.2 some data should be missing / empty or different compared to the 
>> 5.0.2 output. But this I do not see: Can somebody point me to the data I 
>> should compare for this?
>>
>> WindnFog schrieb am Samstag, 20. Januar 2024 um 14:14:08 UTC+1:
>>
>>> Rewording Tom's post to align with one of my professors decades ago, 
>>> "That will work, but let's do it the right way." Using 'weectl database' 
>>> (followed by the proper parameters) is the right way. Humidex is now stored 
>>> in the database, and '$alltime.humidex.max' takes a split second to return 
>>> the correct result. My Rube Goldberg software machine has been dismantled.
>>>
>>> - Paul VE1DX
>>>
>>> On Friday, January 19, 2024 at 10:55:50 AM UTC-4 Tom Keffer wrote:
>>>
 I mean this in the gentlest way, but this is basically what the SQLite 
 database is doing for you: saving various values in a file where they can 
 be retrieved via a general query statement.

 On Fri, Jan 19, 2024 at 6:16 AM WindnFog  wrote:

> I encountered the same problem trying to calculate the all time 
> humidex in the index.html.tmpl template.  This was taking about 3 minutes 
> on a Pi 4. Rather than add humidex to the database (probably the best 
> solution), I calculated all-time humidex once a day using a small program 
> and invoking it with cron. I saved it in a text file that I could then 
> use 
> the Cheetah include statement to read it into index.the html.tmpl 
> template.  This runs in 2 seconds on a Pi 4 and 1 second on a pi 5; if 
> you 
> have an algorithm for appTemp, a similar approach might work.  I was not 
> comfortable with modifying the database because that's not my area of 
> expertise:
>
> #!/usr/bin/env python3
> # -*- coding: utf-8 -*-
>
> """
> Program:WeeWX Humidex calculator
> Author: Paul M Dunphy
> Date:   12 December 2023
> Version:1.0.0
> Description:This

[weewx-user] Re: Apt update source for weewx.

2024-02-28 Thread didier....@gmail.com
Hi

I have upgrade debian 10 to debian 11 bullseye, and I have 
changed /etc/apt/sources.list.d/weewx.list  with:
deb [arch=all] http://weewx.com/apt/python3 *buster InRelease*
instead of deb [arch=all] http://weewx.com/apt/python3 *bullseye main*

But after apt update I have a warning/error about a control of sign in due 
to a no available public key (NO_PUBKEY E788768B9CB16E10)

Where is my mistake?

Thanks a lot

Le samedi 2 juillet 2022 à 23:47:41 UTC+2, Peter Fletcher a écrit :

> Thanks!
>
> On Saturday, July 2, 2022 at 5:38:23 PM UTC-4 matthew wall wrote:
>
>> On Saturday, July 2, 2022 at 4:14:37 PM UTC-4 Peter Fletcher wrote:
>>
>>> The installation instructions add 'http://weewx.com/apt/python3 *buster* 
>>> InRelease' to apt's list of sources for Debian installs, and this works.
>>>
>>
>> you can replace 'buster' with whatever you want.
>>
>> we do not track specific debian (or ubuntu, or mint, or whatever) 
>> releases.  basically we target two debian releases: squeeze (for python2) 
>> and buster (for python3).
>>
>> the weewx python2 deb package first worked with debian 6 (squeeze), and 
>> works with every subsequent debian release until the python2 packages are 
>> no longer provided.
>>
>> the weewx python3 deb package first worked with debian 10 (buster) and 
>> will continue to work with every subsequent debian release until debian 
>> breaks the python3 packages.
>>
>> m
>>  
>>
>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/84f075bc-eb94-4fbb-858c-b731f385411fn%40googlegroups.com.


[weewx-user] Re: WeeWX 5.0.2 voltages with 6 digits after the decimal point

2024-02-28 Thread Mike G.
Yes, that was it. 

Thank you grj80, I was also able to assign the signal quality of other 
unknown devices.

Have a nice day and stay healthy.

gjr80 schrieb am Dienstag, 27. Februar 2024 um 20:29:12 UTC:

> The problem is WeeWX does not know whether your sensor battery fields are 
> temperatures, pressures or voltages etc so WeeWX presents the data as it 
> comes out of the database and with no units labels. To have WeeWX take care 
> of formatting and unit labels each field needs to be assigned to a WeeWX 
> unit group, the Ecowitt gateway driver does this automatically for all 
> WeeWX fields in the default file map, but if you decide to change the field 
> mapping you are responsible for making the unit group assignments yourself. 
> There are a number of ways you can do this, but the easiest is to add a few 
> lines of code to bin/user/extensions.py (the location of 
> bin/user/extensions.py is dependent on how you installed WeeWX, refer to 
> Location 
> of WeeWX components 
>  
> in the User's Guide). Try adding the following to extensions.py:
>
> import weewx.units
> weewx.units.obs_group_dict['soilMoistBattx'] = 'group_volt'
>
> add a weewx.units.obs_group_dict entry for each field you have added. 
> Once you have made the changes save extensions.py and restart WeeWX. 
> WeeWX will then apply the default group_voltage formatting and unit 
> labelling for your sensor battery fields.
>
> Gary
> On Wednesday 28 February 2024 at 03:20:55 UTC+10 mike.g...@gmail.com 
> wrote:
>
>> Hello.
>>
>> I have a clean Debian 12 and WeeWX 5.0.2 installation and am currently 
>> configuring the ecowitt devices (GW1100, WH65, WH51, WH31, WN34, WH55 and 
>> WH57). 
>>
>> I am using the Ecowitt Gateway v0.6.1 from gjr80 as the driver.
>>
>> The voltages of soilTemp and soilMoist should be displayed under " 
>> Sensors". 
>> The missing columns "soilMoistBattx" and "soilTempBattx" have been added 
>> to the SQL database. 
>>
>> Now the voltages on the left are displayed with 6 digits after the 
>> decimal point. 
>> The driver and the graphics on the right correctly show 2 digits after 
>> the decimal point. 
>>
>> Whats wrong? How can I fix this?
>>
>> Greetings, Mike
>>
>> [image: Screenshot 2024-02-22 at 12-36-32 Test City.png]
>>
>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/b1792035-c261-407f-859c-be707d5b0c6an%40googlegroups.com.


Re: [weewx-user] Problem with WeeWX5 "driver" directory

2024-02-28 Thread gjr80
What does unzip -l AWEKAS.zip show? Does bin/user/awekaswx.py actually 
exist in the zip file?

Gary
On Wednesday 28 February 2024 at 17:54:49 UTC+10 remy.l...@gmail.com wrote:

> Hello Tom,
> First problem : when trying to install a driver in virtual environnement :
>
> (weewx-venv) remy@remy-virtual-machine:~/weewx-data$ weectl extension 
> install AWEKAS.zip
> Using configuration file /home/remy/weewx-data/weewx.conf
> Install extension 'AWEKAS.zip' (y/n)? y
> Extracting from zip archive AWEKAS.zip
> Traceback (most recent call last):
>   File "/home/remy/weewx-venv/bin/weectl", line 8, in 
> sys.exit(main())
>   File "/home/remy/weewx-venv/lib/python3.8/site-packages/weectl.py", line 
> 66, in main
> namespace.func(namespace)
>   File 
> "/home/remy/weewx-venv/lib/python3.8/site-packages/weectllib/__init__.py", 
> line 121, in dispatch
> namespace.action_func(config_dict, namespace)
>   File 
> "/home/remy/weewx-venv/lib/python3.8/site-packages/weectllib/extension_cmd.py",
>  
> line 116, in install_extension
> ext.install_extension(namespace.source, no_confirm=namespace.yes)
>   File 
> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
> line 138, in install_extension
> extension_name = self._install_from_file(extension_path, filetype)
>   File 
> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
> line 168, in _install_from_file
> extension_name = self.install_from_dir(extension_dir)
>   File 
> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
> line 185, in install_from_dir
> self._install_files(installer['files'], extension_dir)
>   File 
> "/home/remy/weewx-venv/lib/python3.8/site-packages/weecfg/extension.py", 
> line 269, in _install_files
> shutil.copy(source_path, destination_path)
>   File "/usr/lib/python3.8/shutil.py", line 418, in copy
> copyfile(src, dst, follow_symlinks=follow_symlinks)
>   File "/usr/lib/python3.8/shutil.py", line 264, in copyfile
> with open(src, 'rb') as fsrc, open(dst, 'wb') as fdst:
> FileNotFoundError: [Errno 2] No such file or directory: 
> '/tmp/tmprpxo6tw5/AWEKAS/bin/user/awekaswx.py'
>
> *and the install.py :*
>
> # installer for Awekas Bresser awekaswx driver
> # Copyright 2024 Remy LAVABRE
>
> from setup import ExtensionInstaller
>
> def loader():
> return awekaswxInstaller()
>
> class awekaswxInstaller(ExtensionInstaller):
> def __init__(self):
> super(awekaswxInstaller, self).__init__(
> version="1.3",
> name='awekaswx',
> description='Get Bresser 7in1 data on Awekas',
> author="Remy LAVABRE",
> author_email="remy.l...@gmail.com",
> files=[('bin/user', ['bin/user/awekaswx.py'])],
> config={
> 'awekaswx': {
> 'driver' : 'bin.user.awekaswx',
> 'poll_interval': '60',
> 'awekasapikey' :'My_API_Awekas_Key','
> 'openweatherapikey': 'My_API_OpenWeather_Key',
> 'send_syslog': 'True',
> 'model': 'Bresser 7in1'
> }
> }
> )
>
> *Rémy LAVABRE*
>
>
> Le dim. 25 févr. 2024 à 22:45, Tom Keffer  a écrit :
>
>> From your description, you're installing it in the correct spot, however 
>> you're not giving us much information. Instead of just showing the single 
>> error line, it would be helpful to see the log from startup. The reason is 
>> that it will log the location of the user directory.
>>
>> Set debug=1, then restart weewxd. Post the log *from startup* through 
>> the error.
>>
>> On Sun, Feb 25, 2024 at 10:55 AM Remy Lavabre  
>> wrote:
>>
>>> Hello,
>>>
>>> weewx is installed in virtual PIP mode -> ~/weewx-data/... and 
>>> ~/weewx-venv/...
>>> I manually added the xxx.py driver for my weather station in the 
>>> ~/weewx-data/bin/user directory.
>>> It is declared in weewx.conf as "driver = usr.xxx", as was done in 
>>> version 4.x
>>>
>>> When launching weewxd, I get the message:
>>>File 
>>> "/home/pi/weewx-venv/lib/python3.8/site-packages/weewx/engine.py", line 
>>> 104, in setupStation
>>>  __import__(driver)
>>> ModuleNotFoundError: *No module named 'usr'*
>>>
>>> I tried "driver = xxx.py" without success
>>>
>>> if I put my driver in 
>>> ~/weewx-venv/lib/python3.8/site-packages/weewx/drivers/xxx.py and I put 
>>> driver = xxx.py in weewx.conf there is no longer the error.
>>>
>>> Moral: Would it be possible to tell me the exact location where to put 
>>> my driver in the user directory and how to declare it in weewx.conf ?
>>>
>>> Thank you...
>>>
>>> -- 
>>> 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 on the web visit 
>>> https://groups.google.com/d/msgid/weewx-user/