4.10.1 Error 'driver'

171 views
Skip to first unread message

Little Old Me

unread,
Jan 31, 2023, 2:44:23 AM1/31/23
to weewx-user
After upgrading to version 4.10.1 this error is occurring originally installed from the apt repository on Ubuntu 22.04.

INFO __main__: Initializing weewx version 4.10.1
INFO __main__: Using Python 3.10.6 (main, Nov 14 2022, 16:10:14) [GCC 11.3.0]
INFO __main__: Located at /bin/python3
INFO __main__: Platform Linux-5.15.0-58-generic-x86_64-with-glibc2.35
INFO __main__: Locale is 'en_US.UTF-8'
INFO __main__: Using configuration file /etc/weewx/weewx.conf
INFO __main__: Debug is 1
INFO __main__: PID file is /var/run/weewx.pid
DEBUG __main__: Initializing engine
CRITICAL __main__: Caught unrecoverable exception:
CRITICAL __main__:     ****  'driver'
CRITICAL __main__:     ****  Traceback (most recent call last):
CRITICAL __main__:     ****    File "/usr/share/weewx/weewxd", line 148, in main
CRITICAL __main__:     ****      engine = weewx.engine.StdEngine(config_dict)
CRITICAL __main__:     ****    File "/usr/share/weewx/weewx/engine.py", line 81, in __init__
CRITICAL __main__:     ****      self.setupStation(config_dict)
CRITICAL __main__:     ****    File "/usr/share/weewx/weewx/engine.py", line 103, in setupStation
CRITICAL __main__:     ****      driver = config_dict[station_type]['driver']
CRITICAL __main__:     ****    File "/usr/lib/python3/dist-packages/configobj.py", line 554, in __getitem__
CRITICAL __main__:     ****      val = dict.__getitem__(self, key)
CRITICAL __main__:     ****  KeyError: 'driver'
CRITICAL __main__:     ****  Exiting.
    ...done.
Started LSB: weewx weather system.

Tom Keffer

unread,
Jan 31, 2023, 8:10:07 AM1/31/23
to weewx...@googlegroups.com
Do you recall the exact steps you took when you upgraded? When the installer asked whether to keep your old config file or use a new one, which did you choose?

Also, take a look in /etc/weewx. Are there multiple versions of weewx.conf? Post the results of

ls -l /etc/weewx

Compare them. One of them may be your old config file.

If all else fails, you can try

wee_config --reconfigure

to fix the file you have.

--
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/fe4ef9c5-76ea-47c2-87c0-544471914335n%40googlegroups.com.

Little Old Me

unread,
Jan 31, 2023, 9:37:01 PM1/31/23
to weewx-user
Thanks for the reply I had it replace the weewx.conf. I didn't have much time for anything today so i just ran reconfigure and then copied the sensors back over looks like all is well right now I'll be able to take a closer look a bit later.

matthew wall

unread,
Feb 1, 2023, 11:23:12 AM2/1/23
to weewx-user
On Tuesday, January 31, 2023 at 9:37:01 PM UTC-5 little...@gmail.com wrote:
> Thanks for the reply I had it replace the weewx.conf. I didn't have much time for anything today so 
> i just ran reconfigure and then copied the sensors back over looks like all is well right now I'll be 
> able to take a closer look a bit later.

the update process should have left two copies of your weewx.conf file in /etc/weewx.  one is the weewx.conf file from *before* you did the update, and the other is the weewx.conf file from *after* the update.  there could be other weewx.conf files in there too, from previous updates.  there will be only one called 'weewx.conf' - the others will have timestamp or other extensions to indicate where they came from.

it would be helpful to see the weewx.conf as modified by the update process, and the weewx.conf file from before the update process.

it would also help to see any messages in your syslog (/var/log/syslog) from when you did the weewx update.  these will probably have 'apt' or 'dpkg' as the process name.

m
Reply all
Reply to author
Forward
0 new messages