Starting wee_import...Cumulus monthly log files in the '/var/tmp/cumulus' directory will be imported
The following options will be used:
config=/etc/weewx/weewx.conf, import-config=/var/tmp/cumulus.conf
from=None, to=None
dry-run=True, calc_missing=True, ignore_invalid_data=True
tranche=250, interval=derive
UV=True, radiation=True
Using database binding 'wx_binding', which is bound to database 'weewx'
Destination table 'archive' unit system is '0x01' (US).
Missing derived observations will be calculated.
This is a dry run, imported data will not be saved to archive.
Obtaining raw import data for period 1...
Raw import data read successfully for period 1.
Mapping raw import data for period 1...
Traceback (most recent call last):
File "/usr/bin/wee_import", line 834, in <module>
main()
File "/usr/bin/wee_import", line 784, in main
source_obj.run()
File "/usr/share/weewx/weeimport/weeimport.py", line 350, in run
_mapped_data = self.mapRawData(_raw_data, self.archive_unit_sys)
File "/usr/share/weewx/weeimport/weeimport.py", line 664, in mapRawData
_temp = float(_row[self.map[_field]['field_name']].strip())
AttributeError: 'NoneType' object has no attribute 'strip'Enter code here... try:
_temp = float(_row[self.map[_field]['field_name']].strip())
except TypeError:
# perhaps we have a None, so return None for our field
_temp = None
try:
_temp = float(_row[self.map[_field]['field_name']].strip())
except (TypeError, AttributeError):
# perhaps we have a None, so return None for our field
_temp = None--
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/0KF7U8svBEA/unsubscribe.
To unsubscribe from this group and all its topics, send an email to weewx-user+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/a6282230-9da3-4521-b750-12881c12cd1c%40googlegroups.com.
To unsubscribe from this group and all its topics, send an email to weewx...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/a6282230-9da3-4521-b750-12881c12cd1c%40googlegroups.com.
Yep it seems to be working fine. Tried it with a dryrun and no more errors. Thanks again for the help.
I'm glad I have discovered weewx. Currently toying with the Cheetah generator to reproduce some files I need.