hello TOM, Here are the logs, are they okay?
$ sudo journalctl -u weewx -f | tee /tmp/mylog -- Journal begins at Fri 2025-03-28 22:45:41 CET. -- déc. 29 20:55:50 RPi-WS-Byows weewxd[6531]: self._load(infile, configspec) déc. 29 20:55:50 RPi-WS-Byows weewxd[6531]: File "/usr/lib/python3/dist-packages/configobj.py", line 1287, in _load déc. 29 20:55:50 RPi-WS-Byows weewxd[6531]: content = self._handle_bom(content) déc. 29 20:55:50 RPi-WS-Byows weewxd[6531]: File "/usr/lib/python3/dist-packages/configobj.py", line 1437, in _handle_bom déc. 29 20:55:50 RPi-WS-Byows weewxd[6531]: return self._decode(infile, self.encoding) déc. 29 20:55:50 RPi-WS-Byows weewxd[6531]: File "/usr/lib/python3/dist-packages/configobj.py", line 1517, in _decode déc. 29 20:55:50 RPi-WS-Byows weewxd[6531]: infile[i] = line.decode(encoding) déc. 29 20:55:50 RPi-WS-Byows weewxd[6531]: UnicodeDecodeError: 'utf-8' codec can't decode byte 0xa0 in position 55: invalid start byte déc. 29 20:55:50 RPi-WS-Byows systemd[1]: weewx.service: Main process exited, code=exited, status=1/FAILURE déc. 29 20:55:50 RPi-WS-Byows systemd[1]: weewx.service: Failed with result 'exit-code'. déc. 29 21:00:11 RPi-WS-Byows systemd[1]: Started WeeWX. déc. 29 21:00:11 RPi-WS-Byows weewxd[7003]: Traceback (most recent call last): déc. 29 21:00:11 RPi-WS-Byows weewxd[7003]: File "/usr/share/weewx/weewxd.py", line 226, in <module> déc. 29 21:00:11 RPi-WS-Byows weewxd[7003]: main() déc. 29 21:00:11 RPi-WS-Byows weewxd[7003]: File "/usr/share/weewx/weewxd.py", line 76, in main déc. 29 21:00:11 RPi-WS-Byows weewxd[7003]: config_path, config_dict, log = weeutil.startup.start_a pp(namespace.log_label, déc. 29 21:00:11 RPi-WS-Byows weewxd[7003]: File "/usr/share/weewx/weeutil/startup.py", line 86, in start_app déc. 29 21:00:11 RPi-WS-Byows weewxd[7003]: config_path, config_dict = weecfg.read_config(config_option, [config_arg]) déc. 29 21:00:11 RPi-WS-Byows weewxd[7003]: File "/usr/share/weewx/weecfg/__init__.py", line 150, in read_config déc. 29 21:00:11 RPi-WS-Byows weewxd[7003]: config_dict = configobj.ConfigObj(config_path, déc. 29 21:00:11 RPi-WS-Byows weewxd[7003]: File "/usr/lib/python3/dist-packages/configobj.py", line 1229, in __init__ déc. 29 21:00:11 RPi-WS-Byows weewxd[7003]: self._load(infile, configspec) déc. 29 21:00:11 RPi-WS-Byows weewxd[7003]: File "/usr/lib/python3/dist-packages/configobj.py", line 1287, in _load déc. 29 21:00:11 RPi-WS-Byows weewxd[7003]: content = self._handle_bom(content) déc. 29 21:00:11 RPi-WS-Byows weewxd[7003]: File "/usr/lib/python3/dist-packages/configobj.py", line 1437, in _handle_bom déc. 29 21:00:11 RPi-WS-Byows weewxd[7003]: return self._decode(infile, self.encoding) déc. 29 21:00:11 RPi-WS-Byows weewxd[7003]: File "/usr/lib/python3/dist-packages/configobj.py", line 1517, in _decode déc. 29 21:00:11 RPi-WS-Byows weewxd[7003]: infile[i] = line.decode(encoding) déc. 29 21:00:11 RPi-WS-Byows weewxd[7003]: UnicodeDecodeError: 'utf-8' codec can't decode byte 0xa0 in position 55: invalid start byte déc. 29 21:00:11 RPi-WS-Byows systemd[1]: weewx.service: Main process exited, code=exited, status=1/FAILURE déc. 29 21:00:11 RPi-WS-Byows systemd[1]: weewx.service: Failed with result 'exit-code'. Patrick On Monday, December 29, 2025 at 8:40:32 PM UTC+1 Tom Keffer wrote: > You need to post more of the log. See the wiki article *How to produce a > useful log > <https://github.com/weewx/weewx/wiki/view-logs#how-to-produce-a-useful-log-report>* > . > > Based on the small excerpt that you included in your post, I'd say that > it's your configuration file, weewx.conf, that's corrupted, not the > database. Specifically, a character 55 bytes in. > > But without a full log, it's hard to say. > > -tk > > On Mon, Dec 29, 2025 at 11:32 AM [email protected] <[email protected]> > wrote: > >> >> It's me again. Perhaps an error occurred due to the sudden power outage >> and corrupted some files. >> If I replace them with the original files, is that a good idea? >> >> patrick >> On Monday, December 29, 2025 at 8:19:21 PM UTC+1 [email protected] wrote: >> >>> hello, >>> I'm contacting you because I've searched everywhere. There was a power >>> outage at my house, and when it came back on, the Raspberry Pi booted up, >>> but when I tried to access the weather station, I got errors. I checked >>> all the files affected by the error, but nothing seemed out of the >>> ordinary. Searching >>> online, I saw that other people had encountered this problem, perhaps due >>> to the database! I have a backup of my database (performed every 15 >>> days). Do you have any ideas? >>> I've attached the logs. >>> >>> Have a good evening. >>> >>> Patrick >>> >>> logs after restart weewx. >>> >>> Dec 29 20:09:04 RPi-WS-Byows weewxd[710]: Traceback (most recent call >>> last): >>> Dec 29 20:09:04 RPi-WS-Byows weewxd[710]: File >>> "/usr/share/weewx/weewxd.py", line 226, in <module> >>> Dec 29 20:09:04 RPi-WS-Byows weewxd[710]: main() >>> Dec 29 20:09:04 RPi-WS-Byows weewxd[710]: File >>> "/usr/share/weewx/weewxd.py", line 76, in main >>> Dec 29 20:09:04 RPi-WS-Byows weewxd[710]: config_path, config_dict, >>> log = weeutil.startup.start_app(namespace.log_label, >>> Dec 29 20:09:04 RPi-WS-Byows weewxd[710]: File >>> "/usr/share/weewx/weeutil/startup.py", line 86, in start_app >>> Dec 29 20:09:04 RPi-WS-Byows weewxd[710]: config_path, config_dict = >>> weecfg.read_config(config_option, [config_arg]) >>> Dec 29 20:09:04 RPi-WS-Byows weewxd[710]: File >>> "/usr/share/weewx/weecfg/__init__.py", line 150, in read_config >>> Dec 29 20:09:04 RPi-WS-Byows weewxd[710]: config_dict = >>> configobj.ConfigObj(config_path, >>> Dec 29 20:09:04 RPi-WS-Byows weewxd[710]: File >>> "/usr/lib/python3/dist-packages/configobj.py", line 1229, in __init__ >>> Dec 29 20:09:04 RPi-WS-Byows weewxd[710]: self._load(infile, >>> configspec) >>> Dec 29 20:09:04 RPi-WS-Byows weewxd[710]: File >>> "/usr/lib/python3/dist-packages/configobj.py", line 1287, in _load >>> Dec 29 20:09:04 RPi-WS-Byows weewxd[710]: content = >>> self._handle_bom(content) >>> Dec 29 20:09:04 RPi-WS-Byows weewxd[710]: File >>> "/usr/lib/python3/dist-packages/configobj.py", line 1437, in _handle_bom >>> Dec 29 20:09:04 RPi-WS-Byows weewxd[710]: return >>> self._decode(infile, self.encoding) >>> Dec 29 20:09:04 RPi-WS-Byows weewxd[710]: File >>> "/usr/lib/python3/dist-packages/configobj.py", line 1517, in _decode >>> Dec 29 20:09:04 RPi-WS-Byows weewxd[710]: infile[i] = >>> line.decode(encoding) >>> Dec 29 20:09:04 RPi-WS-Byows weewxd[710]: UnicodeDecodeError: 'utf-8' >>> codec can't decode byte 0xa0 in position 55: invalid start byte >>> >> -- >> 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 [email protected]. >> To view this discussion visit >> https://groups.google.com/d/msgid/weewx-user/a391cf33-00d4-4e30-8c0d-f9a280a97950n%40googlegroups.com >> >> <https://groups.google.com/d/msgid/weewx-user/a391cf33-00d4-4e30-8c0d-f9a280a97950n%40googlegroups.com?utm_medium=email&utm_source=footer> >> . >> > -- 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 [email protected]. To view this discussion visit https://groups.google.com/d/msgid/weewx-user/07505cfd-bf4b-4973-9956-82f5d1b1d613n%40googlegroups.com.
