It's is not your config, it looks like WU has changed the header content in 
one (or more) of their API responses. I should be able to have a look 
tonite and provide a fix.

Gary

On Wednesday, 25 October 2023 at 08:06:04 UTC+10 weewx-user wrote:

The most annoying thing is that I have errors with wee_import to feed my 
mysql database:

*sylvain@gandalf:~/weewx-venv/lib/python3.11/site-packages>** python3 
wee_import.py --config=/home/sylvain/weewx-data/weewx.conf 
--import-config=/home/sylvain /weewx-data/util/import/wu-example.conf 
--dry-run --from=2022-7-12 --to=2023-10-24 --verbose*
Using WeeWX configuration file /home/sylvain/weewx-data/weewx.conf
Starting wee_import...
Observation history for Weather Underground station 'I********' will be 
imported.
The following options will be used:
      config=/home/sylvain/weewx-data/weewx.conf, 
import-config=/home/sylvain/weewx-data/util/import/wu-example.conf
      station=I*******, from=2022-7-12, to=2023-10-24
      apiKey=****************************0b80
      dry-run=True, calc_missing=True, ignore_invalid_data=True
      slice=250, interval=x, wind_direction=[0.0, 360.0]
Using database binding 'wx_binding', which is bound to database 'weewx'
Destination table 'archive' unit system is '0x11' (METRICWX).
Missing derived observations will be calculated.
Observations timestamped after 2022-07-12 00:00:00 CEST (1657576800) and up 
to and
including 2023-10-25 00:00:00 CEST (1698184800) will be imported.
This is a dry run, imported data will not be saved to archive.
Starting dry run import...
Records covering multiple periods have been identified for import.
Period 1...
Obtaining raw import data for period 1 ...
Traceback (most recent call last):
   File 
"/home/sylvain/weewx-venv/lib/python3.11/site-packages/wee_import.py", line 
899, in <module>
     hand()
   File 
"/home/sylvain/weewx-venv/lib/python3.11/site-packages/wee_import.py", line 
829, in main
     source_obj.run()
   File 
"/home/sylvain/weewx-venv/lib/python3.11/site-packages/weeimport/weeimport.py", 
line 375, in run
     _raw_data = self.getRawData(period)
                 ^^^^^^^^^^^^^^^^^^^^^
   File 
"/home/sylvain/weewx-venv/lib/python3.11/site-packages/weeimport/wuimport.py", 
line 249, in getRawData
     _raw_data = f.read().decode(char_set)
                 ^^^^^^^^^^^^^^^^^^^^^^^
TypeError: decode() argument 'encoding' must be str, not None


What did I configure incorrectly?

-- 
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 on the web visit 
https://groups.google.com/d/msgid/weewx-user/2e3fb89a-15da-4124-b8ef-09d61a8b038bn%40googlegroups.com.

Reply via email to