My mistake - must remember to read carefully and digest before posting.  
Sorry!!  


On Friday, 27 January 2017 15:54:18 UTC+2, gjr80 wrote:

> Andrew,
>
> Have a look in /home/weewx/util/import/cumulus-example.conf, delimiter and 
> decimal options.
>
> Gary
>
> On Friday, 27 January 2017 23:49:43 UTC+10, Andrew Milner wrote:
>>
>> Gary
>> One thing I noticed when looking at the cumulus file was that the decimal 
>> separator seemed to be ',' rather than '.', as well as the '-' instead of 
>> '/'.  Perhaps there should be formatting options in the cumulus file for 
>> dates like the csv - and what about the numeric decimal formats - maybe 
>> that should be specifiable in both csv and cumulus imports.
>>
>> Just thoughts!!
>>
>> Andrew
>>
>>
>> On Friday, 27 January 2017 15:28:52 UTC+2, gjr80 wrote:
>>
>>> Hi,
>>>
>>> It looks like I need to add a date delimiter option to cumulus.conf, 
>>> your monthly log file uses d-m-y whereas wee_import is expecting d/m/y 
>>> - first time I have seen anything other than /. Unfortunately, CSV import 
>>> is the only import that currently let's you specify the date-time format 
>>> used in the file(s) to be imported. It will be a couple of days before I 
>>> can fix that issue, so in the interim attached is a modified 
>>> cumulusimport.py that will accept d-m-y (and only d-m-y). If you wish 
>>> to use it:
>>>
>>>    1. rename your existing cumulusimport.py (it should be in 
>>>    /home/weewx/bin/weeimport or /usr/share/weewx/weeimport - depending 
>>>    on your install type) to cumulusimport_orig.py
>>>    2. copy the attached cumulusimport.py in its place.
>>>
>>> Fortunately, I thought I would run a test import with your data and 
>>> config file and the modified cumulusimport.py and I discovered another 
>>> error when importing from Cumulus (perhaps not too many have importd from 
>>> Cumulus since wee_import was released). This time the error is in 
>>> weeimport.py. I have attached a modified weeimport.py that fixes the 
>>> issue. Same process for installing the modified weeimport.py:
>>>
>>>    1. rename the existing weeimport.py to weeimport_orig.py 
>>>    2. copy the attached weeimport.py in its place
>>>
>>> Your import should be error free now (it was for me!). I hope to get 
>>> both fixes in the next weeWX release.
>>>
>>> Gary
>>>
>>> On Friday, 27 January 2017 21:49:50 UTC+10, Thomas Olausson wrote:
>>>>
>>>> Hi,
>>>>
>>>> I'm trying to import old archve data from Cumulus and it seems like the 
>>>> date and time format in the archive is a problem.
>>>> One monthly archive file and cumulus.conf file are appended.
>>>> I would like to know which datetime formats that wee_import can handle 
>>>> so that I, if possible, can edit the time and date in the archives t suit 
>>>> wee_import.
>>>> Below is copy of console output.
>>>>
>>>> Best regards
>>>> Thomas Olausson
>>>>
>>>> pi@raspi3:~ $ wee_import --import-config=/var/tmp/cumulus.conf --dry-run
>>>> Starting wee_import...
>>>> Cumulus monthly log files in the '/home/pi/Downloads/cumulus' directory 
>>>> will be imported
>>>> Using database binding 'wx_binding', which is bound to database 
>>>> 'weewx.sdb'
>>>> 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.
>>>> **** Invalid 'datetime' field. Cannot convert '21-01-10 00:20' to 
>>>> timestamp.
>>>> **** Nothing done, exiting.
>>>>
>>>>

-- 
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.
For more options, visit https://groups.google.com/d/optout.

Reply via email to