[weewx-user] New Router, New Fiber and 4.1 Weewx

2020-09-01 Thread John S
Weewx 4.1.1 running on ubuntu 18.04 with a Vantage PRO station.
   INFO __main__: Initializing weewx version 4.1.1
   Using Python 2.7.17 (default, Jul 20 2020, 15:37:01) #012[GCC 7.5.0]
   Platform Linux-4.15.0-112-generic-x86_64-with-Ubuntu-18.04-bionic
   weewx.drivers.vantage: Driver version is 3.2.1

I waited for a long time for fiber to be installed in the neighborhood and 
when it happened I knew there would be a few challenges due to the new 
modem.
I documented all my firewall settings from the old router and after a bit 
of twiddling was able to punch in the right setup on the new SMART/RG 
SR516ac for all my needs.
Or so I thought, weewx would intermittently fail with a driver load error 
*ERROR weewx.drivers.vantage: ip-read error: timed out*
and 
*ERROR weewx.drivers.vantage: LOOP try #4; error: Expected 99 characters; 
got zero instead*
and
*ERROR weewx.drivers.vantage: Socket error while opening port 2 to 
ethernet host 192.168.42.66.*
* CRITICAL __main__: Unable to load driver: [Errno 113] No route to host*

I had set that Vantage to a static IP address from the pool on the router.
So I upgraded to 4.1.1 just to see if there was any advantage there. It 
reacted pretty much the same, unpredictable disconnects which required a 
restart.
I rechecked my router setup, I had opened port 22 and so I added 2. 
That helped a little bit but I was still getting dropped.

I finally changed a couple of things in the weewx.conf:
# How long to wait before timing out a socket (FTP, HTTP) connection
# was 60
socket_timeout = 360
and
# How long to wait for a response from the station before giving up (in
# seconds; must be greater than 2) (was 10)
timeout = 100

With these two changes my setup doesn't lose its connection and keeps 
trying to connect. I can see in the signal quality graphic on line that 
there are some burps but it seems to recover well, currently up and running 
over 8 days. I'm hopeful that this is it, and will continue to function 
properly.

I also hope this might help others who can't maintain a good connection to 
their Vantage PRO. 

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/a9a50fa2-e14d-42af-902b-7f8288bfeb43o%40googlegroups.com.


[weewx-user] Upgrading to the weewx_extended schema

2020-09-01 Thread wwwd...@gmail.com
I've been running weewx for years and wanted to finally upgrade to the new 
extended schema -- primarily so I can use the weewx-purple extension. After 
digging through the docs and the mailing list archive, I couldn't find 
anything that showed a way to do this, so I figured I would share my 
process here. 

Is there an easier way to do this that I just overlooked in the docs?

The commands below were all run on Raspbian Buster, but should work on 
anything running Debian. Most of them will work on any Linux system. The 
dump and import can take quite some time, depending on what system you are 
running weewx on.

   1. Install the sqlite3 and libsqlite3-mod-impexp packages (impexp will 
   let you export sqlite3 with column names)
  - sudo apt-get install sqlite3 libsqlite3-mod-impexp
   2. Stop weewx
  - sudo sytemctl stop weewx
   3. Move the existing database out of the way - this will also give us a 
   backup just in case
  - cd /var/lib/weewx
  - sudo mv weewx.sdb weewx.sdb-20200901
   4. Dump the database using the above sqlite3 module:
  - echo -e ".load libsqlite3_mod_impexp\nselect 
  export_sql('weewx-import.sql','1')" | sudo sqlite3 weewx.sdb-20200901
  5. Use your favorite editor to change the schema in weewx.conf. The 
   important line is the last one below, you have to change the schema to use 
   schemas.wview_extended.schema.
  - 
  - [DataBindings]
  - 
  - [[wx_binding]]
  - # The database must match one of the sections in 
  [Databases].
  - # This is likely to be the only option you would want to 
  change.
  - database = archive_sqlite
  - # The name of the table within the database
  - table_name = archive
  - # The manager handles aggregation of data for historical 
  summaries
  - manager = weewx.wxmanager.WXDaySummaryManager
  - # The schema defines the structure of the database.
  - # It is *only* used when the database is created.
  - #schema = schemas.wview.schema
  - schema = schemas.wview_extended.schema
   6. Start weewx to create an empty database with the new schema, then 
   stop weewx
  - sudo systemctl start weewx && sleep 5 && sudo systemctl stop weewx
  7. Import the old data into the new database
  - sudo sqlite3 weewx.sdb < weewx-import.sql
  8. Start weewx
  - sudo systemctl start weewx
  
Watch the logs for any issues. If things go bad, stop weewx, move the 
database backup back to weewx.sdb and revert the change to weewx.conf. That 
will get you back to where  you started.

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/6b954977-6825-4c92-a256-fd480f071e97n%40googlegroups.com.


[weewx-user] Re: Migrating/Importing WD data in MySql DB to WeeWx MySql DB

2020-09-01 Thread gjr80
Didn’t take your post as a complaint, sorry if I came across in a manner 
that gave that impression. Just wanted to point out that development of the 
WD module was based on a very small sample of data rather than from some 
written specification. If the problem was a malformed data file that caused 
wee_import to abort we may be able to harden wee_import skip the malformed 
lines. If the problem is a new format/structure in the data file that 
wee_import rejected then we may need to rework the WD module to handle this 
new format/structure.

If you want to send any relevant log entries/errors and a copy of a 
misbehaving data file by direct email thats fine by me.

Gary

On Wednesday, 2 September 2020 at 08:15:51 UTC+10 Andrew M wrote:

> Please don't take what i have written as a complaint. 
> I appreciate all the hard work it took in the creation of WeeWx and all 
> the contributors to the forum.
>
> I have not looked at the content of those files it choked on to see if it 
> has good data in it. Let me first do that. I will reply back once I have 
> done that.
>
> Thank you.
>
> andrew
>
> On Tuesday, September 1, 2020 at 5:20:30 PM UTC-4 gjr80 wrote:
>
>> If you to provide some details on problems the handful of files 
>> experienced I am happy to look at wee_import to see if any changes can be 
>> made to improve its handling of such files. The WD import module of 
>> wee_import was developed based on a handful of WD log files found on the 
>> internet, so it is quite possible there are some corner cases that may 
>> cause wee_import to reject a file.
>>
>> Gary
>>
>> On Wednesday, 2 September 2020 at 07:08:20 UTC+10 Andrew M wrote:
>>
>>> After many, many hours the wee-import processed all but a handful 
>>> of files. Have several that choked on the import.
>>> Ended up with 3,873,678 records.
>>>
>>> Next I need to validate that the data imported to look for any potential 
>>> bad data.
>>>
>>>
>>>
>>> On Friday, August 21, 2020 at 7:31:36 PM UTC-4 Andrew M wrote:
>>>
 Thank you for the response.

 I actually changed up how I am going about this. My WD ran on a 
 Windows10 box. I had a RaspPi box sitting in a box so i decided to use 
 that 
 for WeeWx.
 I was formatting the hard drive on the Win10 machine when i had the 
 thought that I should just put Debian on that and use that for WeeWx. 
 Which I did. This machine is a little faster that the RaspPi , so one I 
 have other things straight I will use that for the conversion. Migrating 
 the MySql from WD to the tables that WeeWX has is probably doable, but 
 really don't want to sit down and think about it that much. I will just 
 let 
 the current weather collect on the RaspPi box and then once the import is 
 done on the now Debian box I can combine the two DB much easier.

 I have 60k rows on the MySQL DB with my current webhost, but more than 
 that saved external to that on a hard drive from a previous webhost that I 
 never moved. 



 On Wednesday, August 19, 2020 at 8:37:29 PM UTC-4 gjr80 wrote:

> Sorry can't help you with MySQL to MySQL migration. 
>
> Regards wee_import though, yes it can be slow. When I wrote the WD 
> import module the WD user who first used it in anger had something like 
> (from memory) 10 years of data to import. The import had to be done in 
> batches (again from memory) of 2-3 years each (wee_import uses 
> transactions on the database but does keep track of duplicate timestamps 
> and a few other things so memory usage does grow as the span of the 
> import 
> grows). I found one email from the user with the results of the first 
> batch 
> import and 1.4 millions records were imported on a Raspberry Pi in 58 
> minutes. Al things considered I find that reasonable.
>
> There are a couple of things you can do to speed up wee_import. You 
> can tweak a the tranche setting in the import config file, this 
> alters the size of the transactions (in records) that wee_import uses. 
> The 
> default is 250, you could raise this which will result in fewer db 
> transactions but it will likely increase memory usage so you may need to 
> do 
> the import in smaller batches. One other approach if using a slow(ish) 
> RPi 
> as your WeeWX machine is to do just the import on a faster machine and 
> then 
> copy the imported data to the WeeWX RPi. Granted this is simpler when 
> using 
> SQLite but depending on your setup could be adapted for MySQL.
>
> You say you have 60 000 odd MySQL records, that does not seem like 
> much, how does that correlate with the number of entries in the WD log 
> files?
>
> Gary
>
> On Thursday, 20 August 2020 08:48:46 UTC+10, Andrew M wrote:
>>
>> I started to use the wee_import process to process all my WD log 
>> files to WeeWx MySqlDB, and it 

[weewx-user] Re: Migrating/Importing WD data in MySql DB to WeeWx MySql DB

2020-09-01 Thread Andrew M
Please don't take what i have written as a complaint. 
I appreciate all the hard work it took in the creation of WeeWx and all the 
contributors to the forum.

I have not looked at the content of those files it choked on to see if it 
has good data in it. Let me first do that. I will reply back once I have 
done that.

Thank you.

andrew

On Tuesday, September 1, 2020 at 5:20:30 PM UTC-4 gjr80 wrote:

> If you to provide some details on problems the handful of files 
> experienced I am happy to look at wee_import to see if any changes can be 
> made to improve its handling of such files. The WD import module of 
> wee_import was developed based on a handful of WD log files found on the 
> internet, so it is quite possible there are some corner cases that may 
> cause wee_import to reject a file.
>
> Gary
>
> On Wednesday, 2 September 2020 at 07:08:20 UTC+10 Andrew M wrote:
>
>> After many, many hours the wee-import processed all but a handful 
>> of files. Have several that choked on the import.
>> Ended up with 3,873,678 records.
>>
>> Next I need to validate that the data imported to look for any potential 
>> bad data.
>>
>>
>>
>> On Friday, August 21, 2020 at 7:31:36 PM UTC-4 Andrew M wrote:
>>
>>> Thank you for the response.
>>>
>>> I actually changed up how I am going about this. My WD ran on a 
>>> Windows10 box. I had a RaspPi box sitting in a box so i decided to use that 
>>> for WeeWx.
>>> I was formatting the hard drive on the Win10 machine when i had the 
>>> thought that I should just put Debian on that and use that for WeeWx. 
>>> Which I did. This machine is a little faster that the RaspPi , so one I 
>>> have other things straight I will use that for the conversion. Migrating 
>>> the MySql from WD to the tables that WeeWX has is probably doable, but 
>>> really don't want to sit down and think about it that much. I will just let 
>>> the current weather collect on the RaspPi box and then once the import is 
>>> done on the now Debian box I can combine the two DB much easier.
>>>
>>> I have 60k rows on the MySQL DB with my current webhost, but more than 
>>> that saved external to that on a hard drive from a previous webhost that I 
>>> never moved. 
>>>
>>>
>>>
>>> On Wednesday, August 19, 2020 at 8:37:29 PM UTC-4 gjr80 wrote:
>>>
 Sorry can't help you with MySQL to MySQL migration. 

 Regards wee_import though, yes it can be slow. When I wrote the WD 
 import module the WD user who first used it in anger had something like 
 (from memory) 10 years of data to import. The import had to be done in 
 batches (again from memory) of 2-3 years each (wee_import uses 
 transactions on the database but does keep track of duplicate timestamps 
 and a few other things so memory usage does grow as the span of the import 
 grows). I found one email from the user with the results of the first 
 batch 
 import and 1.4 millions records were imported on a Raspberry Pi in 58 
 minutes. Al things considered I find that reasonable.

 There are a couple of things you can do to speed up wee_import. You 
 can tweak a the tranche setting in the import config file, this alters 
 the size of the transactions (in records) that wee_import uses. The 
 default 
 is 250, you could raise this which will result in fewer db transactions 
 but 
 it will likely increase memory usage so you may need to do the import in 
 smaller batches. One other approach if using a slow(ish) RPi as your WeeWX 
 machine is to do just the import on a faster machine and then copy the 
 imported data to the WeeWX RPi. Granted this is simpler when using SQLite 
 but depending on your setup could be adapted for MySQL.

 You say you have 60 000 odd MySQL records, that does not seem like 
 much, how does that correlate with the number of entries in the WD log 
 files?

 Gary

 On Thursday, 20 August 2020 08:48:46 UTC+10, Andrew M wrote:
>
> I started to use the wee_import process to process all my WD log files 
> to WeeWx MySqlDB, and it was taking a long time. It seems like If I have 
> many years of data it will take that long to import them into WeeWx 
> MySqlDB.
>
> I then thought, oh wait, i already have the WD data in a MySql DB, so 
> why am i doing this process.
>
> Now I have to figure out how I can gracefully import all the WD data I 
> have in a MySQL DB to the one I set up for WeeWx. Both are on the same 
> hosted server. Different DB names.
>
> There is one table for WD and multiple tables for WeeWx so  have no 
> idea on where to begin with this. I have ~60,000 rows of data in the WD 
> MySQL DB table.
>
> Does anyone have a graceful way of migrating the WD MySQL DB into a 
> WeeWX DB?
>
> Am I overlooking something in the documentation or in group?
>
> Thank you.
>
>
>

-- 
You received this message becaus

[weewx-user] Re: Migrating/Importing WD data in MySql DB to WeeWx MySql DB

2020-09-01 Thread gjr80
If you to provide some details on problems the handful of files experienced 
I am happy to look at wee_import to see if any changes can be made to 
improve its handling of such files. The WD import module of wee_import was 
developed based on a handful of WD log files found on the internet, so it 
is quite possible there are some corner cases that may cause wee_import to 
reject a file.

Gary

On Wednesday, 2 September 2020 at 07:08:20 UTC+10 Andrew M wrote:

> After many, many hours the wee-import processed all but a handful 
> of files. Have several that choked on the import.
> Ended up with 3,873,678 records.
>
> Next I need to validate that the data imported to look for any potential 
> bad data.
>
>
>
> On Friday, August 21, 2020 at 7:31:36 PM UTC-4 Andrew M wrote:
>
>> Thank you for the response.
>>
>> I actually changed up how I am going about this. My WD ran on a Windows10 
>> box. I had a RaspPi box sitting in a box so i decided to use that for WeeWx.
>> I was formatting the hard drive on the Win10 machine when i had the 
>> thought that I should just put Debian on that and use that for WeeWx. 
>> Which I did. This machine is a little faster that the RaspPi , so one I 
>> have other things straight I will use that for the conversion. Migrating 
>> the MySql from WD to the tables that WeeWX has is probably doable, but 
>> really don't want to sit down and think about it that much. I will just let 
>> the current weather collect on the RaspPi box and then once the import is 
>> done on the now Debian box I can combine the two DB much easier.
>>
>> I have 60k rows on the MySQL DB with my current webhost, but more than 
>> that saved external to that on a hard drive from a previous webhost that I 
>> never moved. 
>>
>>
>>
>> On Wednesday, August 19, 2020 at 8:37:29 PM UTC-4 gjr80 wrote:
>>
>>> Sorry can't help you with MySQL to MySQL migration. 
>>>
>>> Regards wee_import though, yes it can be slow. When I wrote the WD 
>>> import module the WD user who first used it in anger had something like 
>>> (from memory) 10 years of data to import. The import had to be done in 
>>> batches (again from memory) of 2-3 years each (wee_import uses 
>>> transactions on the database but does keep track of duplicate timestamps 
>>> and a few other things so memory usage does grow as the span of the import 
>>> grows). I found one email from the user with the results of the first batch 
>>> import and 1.4 millions records were imported on a Raspberry Pi in 58 
>>> minutes. Al things considered I find that reasonable.
>>>
>>> There are a couple of things you can do to speed up wee_import. You can 
>>> tweak a the tranche setting in the import config file, this alters the 
>>> size of the transactions (in records) that wee_import uses. The default is 
>>> 250, you could raise this which will result in fewer db transactions but it 
>>> will likely increase memory usage so you may need to do the import in 
>>> smaller batches. One other approach if using a slow(ish) RPi as your WeeWX 
>>> machine is to do just the import on a faster machine and then copy the 
>>> imported data to the WeeWX RPi. Granted this is simpler when using SQLite 
>>> but depending on your setup could be adapted for MySQL.
>>>
>>> You say you have 60 000 odd MySQL records, that does not seem like much, 
>>> how does that correlate with the number of entries in the WD log files?
>>>
>>> Gary
>>>
>>> On Thursday, 20 August 2020 08:48:46 UTC+10, Andrew M wrote:

 I started to use the wee_import process to process all my WD log files 
 to WeeWx MySqlDB, and it was taking a long time. It seems like If I have 
 many years of data it will take that long to import them into WeeWx 
 MySqlDB.

 I then thought, oh wait, i already have the WD data in a MySql DB, so 
 why am i doing this process.

 Now I have to figure out how I can gracefully import all the WD data I 
 have in a MySQL DB to the one I set up for WeeWx. Both are on the same 
 hosted server. Different DB names.

 There is one table for WD and multiple tables for WeeWx so  have no 
 idea on where to begin with this. I have ~60,000 rows of data in the WD 
 MySQL DB table.

 Does anyone have a graceful way of migrating the WD MySQL DB into a 
 WeeWX DB?

 Am I overlooking something in the documentation or in group?

 Thank you.




-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/4543ed66-c783-4f14-ab5f-0ca5fffc6177n%40googlegroups.com.


[weewx-user] Re: Migrating/Importing WD data in MySql DB to WeeWx MySql DB

2020-09-01 Thread Andrew M
After many, many hours the wee-import processed all but a handful of files. 
Have several that choked on the import.
Ended up with 3,873,678 records.

Next I need to validate that the data imported to look for any potential 
bad data.



On Friday, August 21, 2020 at 7:31:36 PM UTC-4 Andrew M wrote:

> Thank you for the response.
>
> I actually changed up how I am going about this. My WD ran on a Windows10 
> box. I had a RaspPi box sitting in a box so i decided to use that for WeeWx.
> I was formatting the hard drive on the Win10 machine when i had the 
> thought that I should just put Debian on that and use that for WeeWx. 
> Which I did. This machine is a little faster that the RaspPi , so one I 
> have other things straight I will use that for the conversion. Migrating 
> the MySql from WD to the tables that WeeWX has is probably doable, but 
> really don't want to sit down and think about it that much. I will just let 
> the current weather collect on the RaspPi box and then once the import is 
> done on the now Debian box I can combine the two DB much easier.
>
> I have 60k rows on the MySQL DB with my current webhost, but more than 
> that saved external to that on a hard drive from a previous webhost that I 
> never moved. 
>
>
>
> On Wednesday, August 19, 2020 at 8:37:29 PM UTC-4 gjr80 wrote:
>
>> Sorry can't help you with MySQL to MySQL migration. 
>>
>> Regards wee_import though, yes it can be slow. When I wrote the WD 
>> import module the WD user who first used it in anger had something like 
>> (from memory) 10 years of data to import. The import had to be done in 
>> batches (again from memory) of 2-3 years each (wee_import uses 
>> transactions on the database but does keep track of duplicate timestamps 
>> and a few other things so memory usage does grow as the span of the import 
>> grows). I found one email from the user with the results of the first batch 
>> import and 1.4 millions records were imported on a Raspberry Pi in 58 
>> minutes. Al things considered I find that reasonable.
>>
>> There are a couple of things you can do to speed up wee_import. You can 
>> tweak a the tranche setting in the import config file, this alters the 
>> size of the transactions (in records) that wee_import uses. The default is 
>> 250, you could raise this which will result in fewer db transactions but it 
>> will likely increase memory usage so you may need to do the import in 
>> smaller batches. One other approach if using a slow(ish) RPi as your WeeWX 
>> machine is to do just the import on a faster machine and then copy the 
>> imported data to the WeeWX RPi. Granted this is simpler when using SQLite 
>> but depending on your setup could be adapted for MySQL.
>>
>> You say you have 60 000 odd MySQL records, that does not seem like much, 
>> how does that correlate with the number of entries in the WD log files?
>>
>> Gary
>>
>> On Thursday, 20 August 2020 08:48:46 UTC+10, Andrew M wrote:
>>>
>>> I started to use the wee_import process to process all my WD log files 
>>> to WeeWx MySqlDB, and it was taking a long time. It seems like If I have 
>>> many years of data it will take that long to import them into WeeWx MySqlDB.
>>>
>>> I then thought, oh wait, i already have the WD data in a MySql DB, so 
>>> why am i doing this process.
>>>
>>> Now I have to figure out how I can gracefully import all the WD data I 
>>> have in a MySQL DB to the one I set up for WeeWx. Both are on the same 
>>> hosted server. Different DB names.
>>>
>>> There is one table for WD and multiple tables for WeeWx so  have no idea 
>>> on where to begin with this. I have ~60,000 rows of data in the WD MySQL DB 
>>> table.
>>>
>>> Does anyone have a graceful way of migrating the WD MySQL DB into a 
>>> WeeWX DB?
>>>
>>> Am I overlooking something in the documentation or in group?
>>>
>>> Thank you.
>>>
>>>
>>>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/2c9ffe0b-6490-466a-a807-decf40a04d68n%40googlegroups.com.


Re: [weewx-user] weewx upgrade from python2 to python3

2020-09-01 Thread bgra...@umw.edu
Thanks to everyone for the help.
Bob

On Tuesday, September 1, 2020 at 2:50:51 PM UTC-4 wwwd...@gmail.com wrote:

> I just went through the same thing, as was mentioned above make sure all 
> of your plugins have been updated to the latest version. I had a few 
> plugins that I no longer run as they hadn't been upgraded and after a look 
> at the code the work to upgrade them was more than I was willing to tackle. 
> WeeWX-WD for example (although someone has a work-in-progress repo where 
> it's being worked on, but doesn't have any releases yet -- I did an install 
> from a GitHub clone and it seems to be working so far).
>
> At least for the two simple plugins I wrote I just had to change Queue to 
> queue and replace urllib2 with urllib.request.
>
> On Tuesday, September 1, 2020 at 11:32:49 AM UTC-7 tke...@gmail.com wrote:
>
>> Same issue, except this time, it's cmon. Your version has not been ported 
>> to Python 3. Fortunately, a newer version is available which has.
>>
>> On Tue, Sep 1, 2020 at 11:28 AM bgra...@umw.edu  wrote:
>>
>>> Hello,
>>> Seeing the discussion of python3, I thought I would do the switch myself 
>>> but ran into some errors. See below:
>>>
>>> +++
>>> /var/log/weewx.log:
>>> Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Initializing weewx 
>>> version 4.1.1
>>> Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Using Python 3.6.9 
>>> (default, Jul 17 2020, 12:50:27) #012[GCC 8.4.0]
>>> Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Platform 
>>> Linux-4.15.0-115-generic-x86_64-with-Ubuntu-18.04-bionic
>>> Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Locale is 'en_US.UTF-8'
>>> Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Using configuration 
>>> file /home/weewx/weewx.conf
>>> Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Debug is 0
>>> Sep  1 11:51:21 n4mrv weewx[3283] INFO weewx.engine: Loading station 
>>> type Vantage (weewx.drivers.vantage)
>>> Sep  1 11:51:21 n4mrv weewx[3283] INFO weewx.engine: StdConvert target 
>>> unit is 0x1
>>> Sep  1 11:51:21 n4mrv weewx[3283] INFO weewx.wxservices: The following 
>>> values will be calculated: pressure=prefer_hardware, 
>>> barometer=prefer_hardware, altimeter=prefer_hardware, 
>>> windchill=prefer_hardware, heatindex=prefer_hardware, 
>>> dewpoint=prefer_hardware, inDewpoint=prefer_hardware, 
>>> rainRate=prefer_hardware, maxSolarRad=prefer_hardware, 
>>> cloudbase=prefer_hardware, humidex=prefer_hardware, 
>>> appTemp=prefer_hardware, ET=prefer_hardware, windrun=prefer_hardware
>>> Sep  1 11:51:21 n4mrv weewx[3283] INFO weewx.wxservices: The following 
>>> algorithms will be used for calculations: altimeter=aaASOS, maxSolarRad=RS
>>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: Caught 
>>> unrecoverable exception:
>>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   invalid 
>>> syntax (cmon.py, line 315)
>>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   Traceback 
>>> (most recent call last):
>>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: File 
>>> "./bin/weewxd", line 148, in main
>>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   
>>> engine = weewx.engine.StdEngine(config_dict)
>>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: File 
>>> "/home/weewx/bin/weewx/engine.py", line 75, in __init__
>>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   
>>> self.loadServices(config_dict)
>>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: File 
>>> "/home/weewx/bin/weewx/engine.py", line 138, in loadServices
>>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   obj = 
>>> weeutil.weeutil.get_object(svc)(self,config_dict)
>>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: File 
>>> "/home/weewx/bin/weeutil/weeutil.py", line 1093, in get_object
>>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   mod = 
>>> __import__(module)
>>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: File 
>>> "/home/weewx/bin/user/cmon.py", line 315
>>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   
>>> except (ValueError, IOError, KeyError), e:
>>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: 
>>> ^
>>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   
>>> SyntaxError: invalid syntax
>>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   Exiting.
>>> +++
>>>
>>> weewx 4.1.1 was running fine (VantagePro2) with Python 2.7.17. I 
>>> installed the prerequisites for python3 (3.6.9) according to your 
>>> instructions in the guide and then from the 4.1.1 directory ran python3 
>>> ./setup build and install. No errors noticed until I restarted weewx and 
>>> got the above errors before it exited.
>>>
>>> I'm not much of a programmer so I really don't see what happened here 
>>> and would

Re: [weewx-user] weewx upgrade from python2 to python3

2020-09-01 Thread wwwd...@gmail.com
I just went through the same thing, as was mentioned above make sure all of 
your plugins have been updated to the latest version. I had a few plugins 
that I no longer run as they hadn't been upgraded and after a look at the 
code the work to upgrade them was more than I was willing to tackle. 
WeeWX-WD for example (although someone has a work-in-progress repo where 
it's being worked on, but doesn't have any releases yet -- I did an install 
from a GitHub clone and it seems to be working so far).

At least for the two simple plugins I wrote I just had to change Queue to 
queue and replace urllib2 with urllib.request.

On Tuesday, September 1, 2020 at 11:32:49 AM UTC-7 tke...@gmail.com wrote:

> Same issue, except this time, it's cmon. Your version has not been ported 
> to Python 3. Fortunately, a newer version is available which has.
>
> On Tue, Sep 1, 2020 at 11:28 AM bgra...@umw.edu  wrote:
>
>> Hello,
>> Seeing the discussion of python3, I thought I would do the switch myself 
>> but ran into some errors. See below:
>>
>> +++
>> /var/log/weewx.log:
>> Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Initializing weewx 
>> version 4.1.1
>> Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Using Python 3.6.9 
>> (default, Jul 17 2020, 12:50:27) #012[GCC 8.4.0]
>> Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Platform 
>> Linux-4.15.0-115-generic-x86_64-with-Ubuntu-18.04-bionic
>> Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Locale is 'en_US.UTF-8'
>> Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Using configuration file 
>> /home/weewx/weewx.conf
>> Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Debug is 0
>> Sep  1 11:51:21 n4mrv weewx[3283] INFO weewx.engine: Loading station type 
>> Vantage (weewx.drivers.vantage)
>> Sep  1 11:51:21 n4mrv weewx[3283] INFO weewx.engine: StdConvert target 
>> unit is 0x1
>> Sep  1 11:51:21 n4mrv weewx[3283] INFO weewx.wxservices: The following 
>> values will be calculated: pressure=prefer_hardware, 
>> barometer=prefer_hardware, altimeter=prefer_hardware, 
>> windchill=prefer_hardware, heatindex=prefer_hardware, 
>> dewpoint=prefer_hardware, inDewpoint=prefer_hardware, 
>> rainRate=prefer_hardware, maxSolarRad=prefer_hardware, 
>> cloudbase=prefer_hardware, humidex=prefer_hardware, 
>> appTemp=prefer_hardware, ET=prefer_hardware, windrun=prefer_hardware
>> Sep  1 11:51:21 n4mrv weewx[3283] INFO weewx.wxservices: The following 
>> algorithms will be used for calculations: altimeter=aaASOS, maxSolarRad=RS
>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: Caught unrecoverable 
>> exception:
>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   invalid 
>> syntax (cmon.py, line 315)
>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   Traceback 
>> (most recent call last):
>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: File 
>> "./bin/weewxd", line 148, in main
>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   engine 
>> = weewx.engine.StdEngine(config_dict)
>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: File 
>> "/home/weewx/bin/weewx/engine.py", line 75, in __init__
>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   
>> self.loadServices(config_dict)
>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: File 
>> "/home/weewx/bin/weewx/engine.py", line 138, in loadServices
>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   obj = 
>> weeutil.weeutil.get_object(svc)(self,config_dict)
>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: File 
>> "/home/weewx/bin/weeutil/weeutil.py", line 1093, in get_object
>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   mod = 
>> __import__(module)
>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: File 
>> "/home/weewx/bin/user/cmon.py", line 315
>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   except 
>> (ValueError, IOError, KeyError), e:
>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: 
>> ^
>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   
>> SyntaxError: invalid syntax
>> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   Exiting.
>> +++
>>
>> weewx 4.1.1 was running fine (VantagePro2) with Python 2.7.17. I 
>> installed the prerequisites for python3 (3.6.9) according to your 
>> instructions in the guide and then from the 4.1.1 directory ran python3 
>> ./setup build and install. No errors noticed until I restarted weewx and 
>> got the above errors before it exited.
>>
>> I'm not much of a programmer so I really don't see what happened here and 
>> would appreciate it if some one could point out what I either did wrong or 
>> haven't done enough of.
>>
>> Thanks.
>> Bob Grattan
>> http://grattans.org/wx
>>
>> On Tuesday, September 1, 2020 at 2:04:53 PM UTC-4 tke.

Re: [weewx-user] weewx upgrade from python2 to python3

2020-09-01 Thread Tom Keffer
Same issue, except this time, it's cmon. Your version has not been ported
to Python 3. Fortunately, a newer version is available which has.

On Tue, Sep 1, 2020 at 11:28 AM bgra...@umw.edu  wrote:

> Hello,
> Seeing the discussion of python3, I thought I would do the switch myself
> but ran into some errors. See below:
>
> +++
> /var/log/weewx.log:
> Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Initializing weewx
> version 4.1.1
> Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Using Python 3.6.9
> (default, Jul 17 2020, 12:50:27) #012[GCC 8.4.0]
> Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Platform
> Linux-4.15.0-115-generic-x86_64-with-Ubuntu-18.04-bionic
> Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Locale is 'en_US.UTF-8'
> Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Using configuration file
> /home/weewx/weewx.conf
> Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Debug is 0
> Sep  1 11:51:21 n4mrv weewx[3283] INFO weewx.engine: Loading station type
> Vantage (weewx.drivers.vantage)
> Sep  1 11:51:21 n4mrv weewx[3283] INFO weewx.engine: StdConvert target
> unit is 0x1
> Sep  1 11:51:21 n4mrv weewx[3283] INFO weewx.wxservices: The following
> values will be calculated: pressure=prefer_hardware,
> barometer=prefer_hardware, altimeter=prefer_hardware,
> windchill=prefer_hardware, heatindex=prefer_hardware,
> dewpoint=prefer_hardware, inDewpoint=prefer_hardware,
> rainRate=prefer_hardware, maxSolarRad=prefer_hardware,
> cloudbase=prefer_hardware, humidex=prefer_hardware,
> appTemp=prefer_hardware, ET=prefer_hardware, windrun=prefer_hardware
> Sep  1 11:51:21 n4mrv weewx[3283] INFO weewx.wxservices: The following
> algorithms will be used for calculations: altimeter=aaASOS, maxSolarRad=RS
> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: Caught unrecoverable
> exception:
> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   invalid
> syntax (cmon.py, line 315)
> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   Traceback
> (most recent call last):
> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: File
> "./bin/weewxd", line 148, in main
> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   engine
> = weewx.engine.StdEngine(config_dict)
> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: File
> "/home/weewx/bin/weewx/engine.py", line 75, in __init__
> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: 
> self.loadServices(config_dict)
> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: File
> "/home/weewx/bin/weewx/engine.py", line 138, in loadServices
> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   obj =
> weeutil.weeutil.get_object(svc)(self,config_dict)
> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: File
> "/home/weewx/bin/weeutil/weeutil.py", line 1093, in get_object
> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   mod =
> __import__(module)
> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: File
> "/home/weewx/bin/user/cmon.py", line 315
> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   except
> (ValueError, IOError, KeyError), e:
> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:
> ^
> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: 
> SyntaxError: invalid syntax
> Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   Exiting.
> +++
>
> weewx 4.1.1 was running fine (VantagePro2) with Python 2.7.17. I installed
> the prerequisites for python3 (3.6.9) according to your instructions in the
> guide and then from the 4.1.1 directory ran python3 ./setup build and
> install. No errors noticed until I restarted weewx and got the above errors
> before it exited.
>
> I'm not much of a programmer so I really don't see what happened here and
> would appreciate it if some one could point out what I either did wrong or
> haven't done enough of.
>
> Thanks.
> Bob Grattan
> http://grattans.org/wx
>
> On Tuesday, September 1, 2020 at 2:04:53 PM UTC-4 tke...@gmail.com wrote:
>
>> But PID 727 is the old instance, which still ran opsgenie. We want to see
>> what happens without opsgenie.
>>
>> Try it again. This time, follow the directions in the Wiki article Help!
>> Posting to weewx-user
>> ,
>> except for step #6, start weewxd using
>>
>> *sudo /etc/init.d/weewx start*
>>
>> -tk
>>
>> On Tue, Sep 1, 2020 at 8:16 AM 'Season Ticket' via weewx-user <
>> weewx...@googlegroups.com> wrote:
>>
>>> I've removed Opsgenie from the service list.  however I still get
>>> nothing in the logs via the daemon.  if you notice the time stamps at the
>>> end of each log are the same
>>> *"Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL
>>> __main__:   Exiting.  "  *- in both cases.
>>>
>>> On Tuesday, 1 Septe

Re: [weewx-user] weewx upgrade from python2 to python3

2020-09-01 Thread bgra...@umw.edu
Hello,
Seeing the discussion of python3, I thought I would do the switch myself 
but ran into some errors. See below:

+++
/var/log/weewx.log:
Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Initializing weewx version 
4.1.1
Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Using Python 3.6.9 
(default, Jul 17 2020, 12:50:27) #012[GCC 8.4.0]
Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Platform 
Linux-4.15.0-115-generic-x86_64-with-Ubuntu-18.04-bionic
Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Locale is 'en_US.UTF-8'
Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Using configuration file 
/home/weewx/weewx.conf
Sep  1 11:51:21 n4mrv weewx[3283] INFO __main__: Debug is 0
Sep  1 11:51:21 n4mrv weewx[3283] INFO weewx.engine: Loading station type 
Vantage (weewx.drivers.vantage)
Sep  1 11:51:21 n4mrv weewx[3283] INFO weewx.engine: StdConvert target unit 
is 0x1
Sep  1 11:51:21 n4mrv weewx[3283] INFO weewx.wxservices: The following 
values will be calculated: pressure=prefer_hardware, 
barometer=prefer_hardware, altimeter=prefer_hardware, 
windchill=prefer_hardware, heatindex=prefer_hardware, 
dewpoint=prefer_hardware, inDewpoint=prefer_hardware, 
rainRate=prefer_hardware, maxSolarRad=prefer_hardware, 
cloudbase=prefer_hardware, humidex=prefer_hardware, 
appTemp=prefer_hardware, ET=prefer_hardware, windrun=prefer_hardware
Sep  1 11:51:21 n4mrv weewx[3283] INFO weewx.wxservices: The following 
algorithms will be used for calculations: altimeter=aaASOS, maxSolarRad=RS
Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: Caught unrecoverable 
exception:
Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   invalid 
syntax (cmon.py, line 315)
Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   Traceback 
(most recent call last):
Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: File 
"./bin/weewxd", line 148, in main
Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   engine = 
weewx.engine.StdEngine(config_dict)
Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: File 
"/home/weewx/bin/weewx/engine.py", line 75, in __init__
Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   
self.loadServices(config_dict)
Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: File 
"/home/weewx/bin/weewx/engine.py", line 138, in loadServices
Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   obj = 
weeutil.weeutil.get_object(svc)(self,config_dict)
Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: File 
"/home/weewx/bin/weeutil/weeutil.py", line 1093, in get_object
Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   mod = 
__import__(module)
Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: File 
"/home/weewx/bin/user/cmon.py", line 315
Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   except 
(ValueError, IOError, KeyError), e:
Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__: 
^
Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   SyntaxError: 
invalid syntax
Sep  1 11:51:21 n4mrv weewx[3283] CRITICAL __main__:   Exiting.
+++

weewx 4.1.1 was running fine (VantagePro2) with Python 2.7.17. I installed 
the prerequisites for python3 (3.6.9) according to your instructions in the 
guide and then from the 4.1.1 directory ran python3 ./setup build and 
install. No errors noticed until I restarted weewx and got the above errors 
before it exited.

I'm not much of a programmer so I really don't see what happened here and 
would appreciate it if some one could point out what I either did wrong or 
haven't done enough of.

Thanks.
Bob Grattan
http://grattans.org/wx

On Tuesday, September 1, 2020 at 2:04:53 PM UTC-4 tke...@gmail.com wrote:

> But PID 727 is the old instance, which still ran opsgenie. We want to see 
> what happens without opsgenie. 
>
> Try it again. This time, follow the directions in the Wiki article Help! 
> Posting to weewx-user 
> , except 
> for step #6, start weewxd using
>
> *sudo /etc/init.d/weewx start*
>
> -tk
>
> On Tue, Sep 1, 2020 at 8:16 AM 'Season Ticket' via weewx-user <
> weewx...@googlegroups.com> wrote:
>
>> I've removed Opsgenie from the service list.  however I still get nothing 
>> in the logs via the daemon.  if you notice the time stamps at the end of 
>> each log are the same
>> *"Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL 
>> __main__:   Exiting.  "  *- in both cases.
>>
>> On Tuesday, 1 September 2020 at 15:36:48 UTC+1 tke...@gmail.com wrote:
>>
>>> So, the log does say something! The extension 'opsgenie' has not been 
>>> ported to Python 3.
>>>
>>> On Tue, Sep 1, 2020 at 6:13 AM 'Season Ticket' via weewx-user <
>>> weewx...@googlegroups.com> wrote:
>>>
 here are the logs

 pi@raspberrypi:~ 

Re: [weewx-user] weewx upgrade from python2 to python3

2020-09-01 Thread Tom Keffer
But PID 727 is the old instance, which still ran opsgenie. We want to see
what happens without opsgenie.

Try it again. This time, follow the directions in the Wiki article Help!
Posting to weewx-user
, except
for step #6, start weewxd using

*sudo /etc/init.d/weewx start*

-tk

On Tue, Sep 1, 2020 at 8:16 AM 'Season Ticket' via weewx-user <
weewx-user@googlegroups.com> wrote:

> I've removed Opsgenie from the service list.  however I still get nothing
> in the logs via the daemon.  if you notice the time stamps at the end of
> each log are the same
> *"Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>  Exiting.  "  *- in both cases.
>
> On Tuesday, 1 September 2020 at 15:36:48 UTC+1 tke...@gmail.com wrote:
>
>> So, the log does say something! The extension 'opsgenie' has not been
>> ported to Python 3.
>>
>> On Tue, Sep 1, 2020 at 6:13 AM 'Season Ticket' via weewx-user <
>> weewx...@googlegroups.com> wrote:
>>
>>> here are the logs
>>>
>>> pi@raspberrypi:~ $ sudo systemctl status weewx
>>> ● weewx.service - LSB: weewx weather system
>>>Loaded: loaded (/etc/init.d/weewx; generated; vendor preset: enabled)
>>>Active: active (exited) since Tue 2020-09-01 09:14:20 BST; 4h 57min
>>> ago
>>>  Docs: man:systemd-sysv-generator(8)
>>>   Process: 548 ExecStop=/etc/init.d/weewx stop (code=exited,
>>> status=0/SUCCESS)
>>>   Process: 692 ExecStart=/etc/init.d/weewx start (code=exited,
>>> status=0/SUCCESS)
>>>CGroup: /system.slice/weewx.service
>>>
>>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>>>  self.loadServices(config_dict)
>>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>>>File "/usr/share/weewx/weewx/engine.py", line 138, in
>>> loadServices
>>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>>>  obj = weeutil.weeutil.get_object(svc)(self,config_dict)
>>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>>>File "/usr/share/weewx/weeutil/weeutil.py", line 1093, in
>>> get_object
>>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>>>  mod = __import__(module)
>>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>>>File "/usr/share/weewx/user/opsgenie.py", line 61
>>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>>>  except KeyError, e:
>>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>>> ^
>>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>>>  SyntaxError: invalid syntax
>>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>>>  Exiting.
>>> pi@raspberrypi:~ $ sudo /etc/init.d/weewx start
>>> [ ok ] Starting weewx (via systemctl): weewx.service.
>>> pi@raspberrypi:~ $ sudo systemctl status weewx
>>> ● weewx.service - LSB: weewx weather system
>>>Loaded: loaded (/etc/init.d/weewx; generated; vendor preset: enabled)
>>>Active: active (exited) since Tue 2020-09-01 09:14:20 BST; 4h 58min
>>> ago
>>>  Docs: man:systemd-sysv-generator(8)
>>>   Process: 548 ExecStop=/etc/init.d/weewx stop (code=exited,
>>> status=0/SUCCESS)
>>>   Process: 692 ExecStart=/etc/init.d/weewx start (code=exited,
>>> status=0/SUCCESS)
>>>CGroup: /system.slice/weewx.service
>>>
>>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>>>  self.loadServices(config_dict)
>>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>>>File "/usr/share/weewx/weewx/engine.py", line 138, in
>>> loadServices
>>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>>>  obj = weeutil.weeutil.get_object(svc)(self,config_dict)
>>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>>>File "/usr/share/weewx/weeutil/weeutil.py", line 1093, in
>>> get_object
>>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>>>  mod = __import__(module)
>>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>>>File "/usr/share/weewx/user/opsgenie.py", line 61
>>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>>>  except KeyError, e:
>>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>>> ^
>>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>>>  SyntaxError: invalid syntax
>>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>>>  Exiting.
>>>
>>>
>>> On Tuesday, 1 September 2020 at 13:32:15 UTC+1 tke...@gmail.com wrote:
>>>
 What are the results of the command

 *sudo systemctl status weewx*

 Then try it again

Re: [weewx-user] weewx upgrade from python2 to python3

2020-09-01 Thread 'Season Ticket' via weewx-user
I've removed Opsgenie from the service list.  however I still get nothing 
in the logs via the daemon.  if you notice the time stamps at the end of 
each log are the same
*"Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
     Exiting.  "  *- in both cases.

On Tuesday, 1 September 2020 at 15:36:48 UTC+1 tke...@gmail.com wrote:

> So, the log does say something! The extension 'opsgenie' has not been 
> ported to Python 3.
>
> On Tue, Sep 1, 2020 at 6:13 AM 'Season Ticket' via weewx-user <
> weewx...@googlegroups.com> wrote:
>
>> here are the logs
>>
>> pi@raspberrypi:~ $ sudo systemctl status weewx
>> ● weewx.service - LSB: weewx weather system
>>Loaded: loaded (/etc/init.d/weewx; generated; vendor preset: enabled)
>>Active: active (exited) since Tue 2020-09-01 09:14:20 BST; 4h 57min ago
>>  Docs: man:systemd-sysv-generator(8)
>>   Process: 548 ExecStop=/etc/init.d/weewx stop (code=exited, 
>> status=0/SUCCESS)
>>   Process: 692 ExecStart=/etc/init.d/weewx start (code=exited, 
>> status=0/SUCCESS)
>>CGroup: /system.slice/weewx.service
>>
>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
>>  self.loadServices(config_dict)
>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
>>File "/usr/share/weewx/weewx/engine.py", line 138, in 
>> loadServices
>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
>>  obj = weeutil.weeutil.get_object(svc)(self,config_dict)
>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
>>File "/usr/share/weewx/weeutil/weeutil.py", line 1093, in 
>> get_object
>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
>>  mod = __import__(module)
>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
>>File "/usr/share/weewx/user/opsgenie.py", line 61
>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
>>  except KeyError, e:
>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
>> ^
>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
>>  SyntaxError: invalid syntax
>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
>>  Exiting.
>> pi@raspberrypi:~ $ sudo /etc/init.d/weewx start
>> [ ok ] Starting weewx (via systemctl): weewx.service.
>> pi@raspberrypi:~ $ sudo systemctl status weewx
>> ● weewx.service - LSB: weewx weather system
>>Loaded: loaded (/etc/init.d/weewx; generated; vendor preset: enabled)
>>Active: active (exited) since Tue 2020-09-01 09:14:20 BST; 4h 58min ago
>>  Docs: man:systemd-sysv-generator(8)
>>   Process: 548 ExecStop=/etc/init.d/weewx stop (code=exited, 
>> status=0/SUCCESS)
>>   Process: 692 ExecStart=/etc/init.d/weewx start (code=exited, 
>> status=0/SUCCESS)
>>CGroup: /system.slice/weewx.service
>>
>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
>>  self.loadServices(config_dict)
>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
>>File "/usr/share/weewx/weewx/engine.py", line 138, in 
>> loadServices
>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
>>  obj = weeutil.weeutil.get_object(svc)(self,config_dict)
>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
>>File "/usr/share/weewx/weeutil/weeutil.py", line 1093, in 
>> get_object
>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
>>  mod = __import__(module)
>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
>>File "/usr/share/weewx/user/opsgenie.py", line 61
>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
>>  except KeyError, e:
>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
>> ^
>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
>>  SyntaxError: invalid syntax
>> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:  
>>  Exiting.
>>
>>
>> On Tuesday, 1 September 2020 at 13:32:15 UTC+1 tke...@gmail.com wrote:
>>
>>> What are the results of the command
>>>
>>> *sudo systemctl status weewx*
>>>
>>> Then try it again after trying to start weewxd:
>>>
>>> *sudo /etc/init.d/weewx start*
>>> *sudo systemctl status weewx*
>>>
>>>
>>>
>>>
>>> On Tue, Sep 1, 2020 at 5:08 AM 'Season Ticket' via weewx-user <
>>> weewx...@googlegroups.com> wrote:
>>>
 ok thanks I didn't know that the recompile would be done automatically.

 here is the content of /etc/default/weewx
 pi@raspberrypi:~ $ more /etc/default/weewx
 WEEWX_PYTHON=/usr/bin/python3
 WEEWX_BINDIR=/usr/share/weewx
 WEEWX_BIN=/usr/bin

Re: [weewx-user] weewx upgrade from python2 to python3

2020-09-01 Thread Tom Keffer
So, the log does say something! The extension 'opsgenie' has not been
ported to Python 3.

On Tue, Sep 1, 2020 at 6:13 AM 'Season Ticket' via weewx-user <
weewx-user@googlegroups.com> wrote:

> here are the logs
>
> pi@raspberrypi:~ $ sudo systemctl status weewx
> ● weewx.service - LSB: weewx weather system
>Loaded: loaded (/etc/init.d/weewx; generated; vendor preset: enabled)
>Active: active (exited) since Tue 2020-09-01 09:14:20 BST; 4h 57min ago
>  Docs: man:systemd-sysv-generator(8)
>   Process: 548 ExecStop=/etc/init.d/weewx stop (code=exited,
> status=0/SUCCESS)
>   Process: 692 ExecStart=/etc/init.d/weewx start (code=exited,
> status=0/SUCCESS)
>CGroup: /system.slice/weewx.service
>
> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>    self.loadServices(config_dict)
> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>  File "/usr/share/weewx/weewx/engine.py", line 138, in loadServices
> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>    obj = weeutil.weeutil.get_object(svc)(self,config_dict)
> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>  File "/usr/share/weewx/weeutil/weeutil.py", line 1093, in
> get_object
> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>    mod = __import__(module)
> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>  File "/usr/share/weewx/user/opsgenie.py", line 61
> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>    except KeyError, e:
> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>   ^
> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>    SyntaxError: invalid syntax
> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>    Exiting.
> pi@raspberrypi:~ $ sudo /etc/init.d/weewx start
> [ ok ] Starting weewx (via systemctl): weewx.service.
> pi@raspberrypi:~ $ sudo systemctl status weewx
> ● weewx.service - LSB: weewx weather system
>Loaded: loaded (/etc/init.d/weewx; generated; vendor preset: enabled)
>Active: active (exited) since Tue 2020-09-01 09:14:20 BST; 4h 58min ago
>  Docs: man:systemd-sysv-generator(8)
>   Process: 548 ExecStop=/etc/init.d/weewx stop (code=exited,
> status=0/SUCCESS)
>   Process: 692 ExecStart=/etc/init.d/weewx start (code=exited,
> status=0/SUCCESS)
>CGroup: /system.slice/weewx.service
>
> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>    self.loadServices(config_dict)
> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>  File "/usr/share/weewx/weewx/engine.py", line 138, in loadServices
> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>    obj = weeutil.weeutil.get_object(svc)(self,config_dict)
> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>  File "/usr/share/weewx/weeutil/weeutil.py", line 1093, in
> get_object
> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>    mod = __import__(module)
> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>  File "/usr/share/weewx/user/opsgenie.py", line 61
> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>    except KeyError, e:
> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>   ^
> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>    SyntaxError: invalid syntax
> Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
>    Exiting.
>
>
> On Tuesday, 1 September 2020 at 13:32:15 UTC+1 tke...@gmail.com wrote:
>
>> What are the results of the command
>>
>> *sudo systemctl status weewx*
>>
>> Then try it again after trying to start weewxd:
>>
>> *sudo /etc/init.d/weewx start*
>> *sudo systemctl status weewx*
>>
>>
>>
>>
>> On Tue, Sep 1, 2020 at 5:08 AM 'Season Ticket' via weewx-user <
>> weewx...@googlegroups.com> wrote:
>>
>>> ok thanks I didn't know that the recompile would be done automatically.
>>>
>>> here is the content of /etc/default/weewx
>>> pi@raspberrypi:~ $ more /etc/default/weewx
>>> WEEWX_PYTHON=/usr/bin/python3
>>> WEEWX_BINDIR=/usr/share/weewx
>>> WEEWX_BIN=/usr/bin/weewxd
>>> WEEWX_CFG=/etc/weewx/weewx.conf
>>>
>>> and
>>>
>>> pi@raspberrypi:~ $ ls -altr /usr/bin/weewxd
>>> -rwxr-xr-x 1 root root 279 Jun  1 23:16 /usr/bin/weewxd
>>> pi@raspberrypi:~ $ ls -altr /usr/bin/python3
>>> lrwxrwxrwx 1 root root 9 Jan 20  2017 /usr/bin/python3 -> python3.5
>>> pi@raspberrypi:~ $ ls -altr /usr/bin/python2
>>> lrwxrwxrwx 1 root root 9 Jan 24  2017 /usr/bin/python2 -> python2.7
>>> pi@raspberrypi:~ $ ls -altr /usr/share/weewx
>>> total 284
>>> -rwxr-xr-x   1 root root 23741 Jun  1 23:16 wunderfixer
>>> -rwxr-xr-x   1 root 

Re: [weewx-user] weewx upgrade from python2 to python3

2020-09-01 Thread 'Season Ticket' via weewx-user
here are the logs

pi@raspberrypi:~ $ sudo systemctl status weewx
● weewx.service - LSB: weewx weather system
   Loaded: loaded (/etc/init.d/weewx; generated; vendor preset: enabled)
   Active: active (exited) since Tue 2020-09-01 09:14:20 BST; 4h 57min ago
 Docs: man:systemd-sysv-generator(8)
  Process: 548 ExecStop=/etc/init.d/weewx stop (code=exited, 
status=0/SUCCESS)
  Process: 692 ExecStart=/etc/init.d/weewx start (code=exited, 
status=0/SUCCESS)
   CGroup: /system.slice/weewx.service

Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
   self.loadServices(config_dict)
Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
 File "/usr/share/weewx/weewx/engine.py", line 138, in loadServices
Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
   obj = weeutil.weeutil.get_object(svc)(self,config_dict)
Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
 File "/usr/share/weewx/weeutil/weeutil.py", line 1093, in 
get_object
Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
   mod = __import__(module)
Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
 File "/usr/share/weewx/user/opsgenie.py", line 61
Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
   except KeyError, e:
Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
  ^
Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
   SyntaxError: invalid syntax
Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
   Exiting.
pi@raspberrypi:~ $ sudo /etc/init.d/weewx start
[ ok ] Starting weewx (via systemctl): weewx.service.
pi@raspberrypi:~ $ sudo systemctl status weewx
● weewx.service - LSB: weewx weather system
   Loaded: loaded (/etc/init.d/weewx; generated; vendor preset: enabled)
   Active: active (exited) since Tue 2020-09-01 09:14:20 BST; 4h 58min ago
 Docs: man:systemd-sysv-generator(8)
  Process: 548 ExecStop=/etc/init.d/weewx stop (code=exited, 
status=0/SUCCESS)
  Process: 692 ExecStart=/etc/init.d/weewx start (code=exited, 
status=0/SUCCESS)
   CGroup: /system.slice/weewx.service

Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
   self.loadServices(config_dict)
Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
 File "/usr/share/weewx/weewx/engine.py", line 138, in loadServices
Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
   obj = weeutil.weeutil.get_object(svc)(self,config_dict)
Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
 File "/usr/share/weewx/weeutil/weeutil.py", line 1093, in 
get_object
Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
   mod = __import__(module)
Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
 File "/usr/share/weewx/user/opsgenie.py", line 61
Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
   except KeyError, e:
Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
  ^
Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
   SyntaxError: invalid syntax
Sep 01 09:14:20 raspberrypi python3[727]: weewx[727] CRITICAL __main__:
   Exiting.


On Tuesday, 1 September 2020 at 13:32:15 UTC+1 tke...@gmail.com wrote:

> What are the results of the command
>
> *sudo systemctl status weewx*
>
> Then try it again after trying to start weewxd:
>
> *sudo /etc/init.d/weewx start*
> *sudo systemctl status weewx*
>
>
>
>
> On Tue, Sep 1, 2020 at 5:08 AM 'Season Ticket' via weewx-user <
> weewx...@googlegroups.com> wrote:
>
>> ok thanks I didn't know that the recompile would be done automatically.
>>
>> here is the content of /etc/default/weewx
>> pi@raspberrypi:~ $ more /etc/default/weewx
>> WEEWX_PYTHON=/usr/bin/python3
>> WEEWX_BINDIR=/usr/share/weewx
>> WEEWX_BIN=/usr/bin/weewxd
>> WEEWX_CFG=/etc/weewx/weewx.conf
>>
>> and
>>
>> pi@raspberrypi:~ $ ls -altr /usr/bin/weewxd
>> -rwxr-xr-x 1 root root 279 Jun  1 23:16 /usr/bin/weewxd
>> pi@raspberrypi:~ $ ls -altr /usr/bin/python3
>> lrwxrwxrwx 1 root root 9 Jan 20  2017 /usr/bin/python3 -> python3.5
>> pi@raspberrypi:~ $ ls -altr /usr/bin/python2
>> lrwxrwxrwx 1 root root 9 Jan 24  2017 /usr/bin/python2 -> python2.7
>> pi@raspberrypi:~ $ ls -altr /usr/share/weewx
>> total 284
>> -rwxr-xr-x   1 root root 23741 Jun  1 23:16 wunderfixer
>> -rwxr-xr-x   1 root root  9840 Jun  1 23:16 weewxd
>> -rwxr-xr-x   1 root root  3806 Jun  1 23:16 wee_reports
>> -rwxr-xr-x   1 root root 38823 Jun  1 23:16 wee_import
>> -rwxr-xr-x   1 root root  3157 Jun  1 23:16 wee_extension
>> -rwxr-xr-x   1 root root  2195 Jun  1 23:16 wee_device
>> -rwxr-xr-x

Re: [weewx-user] weewx upgrade from python2 to python3

2020-09-01 Thread Tom Keffer
What are the results of the command

*sudo systemctl status weewx*

Then try it again after trying to start weewxd:

*sudo /etc/init.d/weewx start*
*sudo systemctl status weewx*




On Tue, Sep 1, 2020 at 5:08 AM 'Season Ticket' via weewx-user <
weewx-user@googlegroups.com> wrote:

> ok thanks I didn't know that the recompile would be done automatically.
>
> here is the content of /etc/default/weewx
> pi@raspberrypi:~ $ more /etc/default/weewx
> WEEWX_PYTHON=/usr/bin/python3
> WEEWX_BINDIR=/usr/share/weewx
> WEEWX_BIN=/usr/bin/weewxd
> WEEWX_CFG=/etc/weewx/weewx.conf
>
> and
>
> pi@raspberrypi:~ $ ls -altr /usr/bin/weewxd
> -rwxr-xr-x 1 root root 279 Jun  1 23:16 /usr/bin/weewxd
> pi@raspberrypi:~ $ ls -altr /usr/bin/python3
> lrwxrwxrwx 1 root root 9 Jan 20  2017 /usr/bin/python3 -> python3.5
> pi@raspberrypi:~ $ ls -altr /usr/bin/python2
> lrwxrwxrwx 1 root root 9 Jan 24  2017 /usr/bin/python2 -> python2.7
> pi@raspberrypi:~ $ ls -altr /usr/share/weewx
> total 284
> -rwxr-xr-x   1 root root 23741 Jun  1 23:16 wunderfixer
> -rwxr-xr-x   1 root root  9840 Jun  1 23:16 weewxd
> -rwxr-xr-x   1 root root  3806 Jun  1 23:16 wee_reports
> -rwxr-xr-x   1 root root 38823 Jun  1 23:16 wee_import
> -rwxr-xr-x   1 root root  3157 Jun  1 23:16 wee_extension
> -rwxr-xr-x   1 root root  2195 Jun  1 23:16 wee_device
> -rwxr-xr-x   1 root root 16776 Jun  1 23:16 wee_debug
> -rwxr-xr-x   1 root root 43183 Jun  1 23:16 wee_database
> -rwxr-xr-x   1 root root  5637 Jun  1 23:16 wee_config
> -rw-r--r--   1 root root 32452 Jun  1 23:16 six.py
> -rw-r--r--   1 root root  2888 Jun  1 23:16 daemon.py
> drwxr-xr-x 237 root root 12288 Aug 29 22:38 ..
> drwxr-xr-x   2 root root  4096 Sep  1 09:10 weeimport
> -rw-r--r--   1 root root 31099 Sep  1 09:10 six.pyc
> -rw-r--r--   1 root root  2712 Sep  1 09:10 daemon.pyc
> drwxr-xr-x   2 root root  4096 Sep  1 09:11 weeplot
> drwxr-xr-x  11 root root  4096 Sep  1 09:14 .
> drwxr-xr-x   3 root root  4096 Sep  1 09:14 weecfg
> drwxr-xr-x   2 root root  4096 Sep  1 09:14 __pycache__
> drwxr-xr-x   3 root root  4096 Sep  1 09:14 weeutil
> drwxr-xr-x   3 root root  4096 Sep  1 09:14 weedb
> drwxr-xr-x   4 root root  4096 Sep  1 09:14 weewx
> drwxr-xr-x   4 root root  4096 Sep  1 09:14 user
> drwxr-xr-x   3 root root  4096 Sep  1 09:14 schemas
> pi@raspberrypi:~ $ ls -altr /etc/weewx/weewx.conf
> -rw-r--r-- 1 root root 31815 Sep  1 09:22 /etc/weewx/weewx.conf
>
>
>
> On Tuesday, 1 September 2020 at 12:40:31 UTC+1 tke...@gmail.com wrote:
>
>> You're making things harder than it needs to be! No need to recompile
>> anything. That is done automatically by the interpreter.
>>
>> 1. What is in /etc/default/weewx?
>>
>> 2. In /etc/default/weewx, the variable WEEWX_BIN points to the copy of
>> weewxd to be used. *Make sure it exists*. If it does not, this will
>> cause /etc/init.d/weewx to exit without warning.
>>
>> -tk
>>
>> On Tue, Sep 1, 2020 at 1:39 AM 'Season Ticket' via weewx-user <
>> weewx...@googlegroups.com> wrote:
>>
>>> thanks for your persistence with this.
>>> I reinstalled because I expected that the code would need to be
>>> recompiled with python3.
>>> I can revert back to python2  by,  a) changing the /etc/defaults/weewx
>>> to reference python2 and then reinstall again using "sudo dpkg -i
>>> python-weewx_4.1.1-1_all.deb"
>>> I tried again this time with only changing the /etc/defaults/weewx file
>>> and running weewxd.
>>>
>>> This time I got some errors due to the following:
>>>  user.alarm_multi.MyAlarm,
>>>  user.opsgenie.OpsGenieAlerts, user.opsgenie.OpsGenieHeartbeat
>>> which I have removed and now weewxd works fine
>>>
>>> However when I start the daemon "sudo /etc/init.d/weewx start" I still
>>> get nothing,   no process is started and no logs.  Any ideas?
>>>
>>>
>>> On Monday, 31 August 2020 at 23:49:51 UTC+1 tke...@gmail.com wrote:
>>>
 Any particular reason why you tried to reinstall weewx? And, the
 version you reinstalled is for python2.

 NB: there is only one code base for weewx. There is no separate Python
 2 and Python 3 versions. The only difference between the two packages is in
 which prerequisites get installed. But, the actually weewx code base is
 identical.

 That is why you only needed to install the new prerequisites.

 Surely there is something in the logs. What happens if you try to run
 weewxd directly from the command line?


 On Mon, Aug 31, 2020 at 3:26 PM 'Season Ticket' via weewx-user <
 weewx...@googlegroups.com> wrote:

>
> I changed /etc/default/weewx to use /usr/bin/python3
> then
>
> sudo dpkg -i python-weewx_4.1.1-1_all.deb
>
> but now weewx won't start and no logs in /var/log/syslog
> On Monday, 31 August 2020 at 23:06:15 UTC+1 tke...@gmail.com wrote:
>
>> I'm assuming you want to keep everything the same, except you want to
>> run under Python 3. So, all you have to do is make sure python3 gets
>> invoked, instead o

Re: [weewx-user] weewx upgrade from python2 to python3

2020-09-01 Thread 'Season Ticket' via weewx-user
ok thanks I didn't know that the recompile would be done automatically.

here is the content of /etc/default/weewx
pi@raspberrypi:~ $ more /etc/default/weewx
WEEWX_PYTHON=/usr/bin/python3
WEEWX_BINDIR=/usr/share/weewx
WEEWX_BIN=/usr/bin/weewxd
WEEWX_CFG=/etc/weewx/weewx.conf

and

pi@raspberrypi:~ $ ls -altr /usr/bin/weewxd
-rwxr-xr-x 1 root root 279 Jun  1 23:16 /usr/bin/weewxd
pi@raspberrypi:~ $ ls -altr /usr/bin/python3
lrwxrwxrwx 1 root root 9 Jan 20  2017 /usr/bin/python3 -> python3.5
pi@raspberrypi:~ $ ls -altr /usr/bin/python2
lrwxrwxrwx 1 root root 9 Jan 24  2017 /usr/bin/python2 -> python2.7
pi@raspberrypi:~ $ ls -altr /usr/share/weewx
total 284
-rwxr-xr-x   1 root root 23741 Jun  1 23:16 wunderfixer
-rwxr-xr-x   1 root root  9840 Jun  1 23:16 weewxd
-rwxr-xr-x   1 root root  3806 Jun  1 23:16 wee_reports
-rwxr-xr-x   1 root root 38823 Jun  1 23:16 wee_import
-rwxr-xr-x   1 root root  3157 Jun  1 23:16 wee_extension
-rwxr-xr-x   1 root root  2195 Jun  1 23:16 wee_device
-rwxr-xr-x   1 root root 16776 Jun  1 23:16 wee_debug
-rwxr-xr-x   1 root root 43183 Jun  1 23:16 wee_database
-rwxr-xr-x   1 root root  5637 Jun  1 23:16 wee_config
-rw-r--r--   1 root root 32452 Jun  1 23:16 six.py
-rw-r--r--   1 root root  2888 Jun  1 23:16 daemon.py
drwxr-xr-x 237 root root 12288 Aug 29 22:38 ..
drwxr-xr-x   2 root root  4096 Sep  1 09:10 weeimport
-rw-r--r--   1 root root 31099 Sep  1 09:10 six.pyc
-rw-r--r--   1 root root  2712 Sep  1 09:10 daemon.pyc
drwxr-xr-x   2 root root  4096 Sep  1 09:11 weeplot
drwxr-xr-x  11 root root  4096 Sep  1 09:14 .
drwxr-xr-x   3 root root  4096 Sep  1 09:14 weecfg
drwxr-xr-x   2 root root  4096 Sep  1 09:14 __pycache__
drwxr-xr-x   3 root root  4096 Sep  1 09:14 weeutil
drwxr-xr-x   3 root root  4096 Sep  1 09:14 weedb
drwxr-xr-x   4 root root  4096 Sep  1 09:14 weewx
drwxr-xr-x   4 root root  4096 Sep  1 09:14 user
drwxr-xr-x   3 root root  4096 Sep  1 09:14 schemas
pi@raspberrypi:~ $ ls -altr /etc/weewx/weewx.conf
-rw-r--r-- 1 root root 31815 Sep  1 09:22 /etc/weewx/weewx.conf



On Tuesday, 1 September 2020 at 12:40:31 UTC+1 tke...@gmail.com wrote:

> You're making things harder than it needs to be! No need to recompile 
> anything. That is done automatically by the interpreter.
>
> 1. What is in /etc/default/weewx? 
>
> 2. In /etc/default/weewx, the variable WEEWX_BIN points to the copy of 
> weewxd to be used. *Make sure it exists*. If it does not, this will cause 
> /etc/init.d/weewx to exit without warning.
>
> -tk
>
> On Tue, Sep 1, 2020 at 1:39 AM 'Season Ticket' via weewx-user <
> weewx...@googlegroups.com> wrote:
>
>> thanks for your persistence with this.
>> I reinstalled because I expected that the code would need to be 
>> recompiled with python3.  
>> I can revert back to python2  by,  a) changing the /etc/defaults/weewx to 
>> reference python2 and then reinstall again using "sudo dpkg -i 
>> python-weewx_4.1.1-1_all.deb"
>> I tried again this time with only changing the /etc/defaults/weewx file 
>> and running weewxd.  
>>
>> This time I got some errors due to the following:
>>  user.alarm_multi.MyAlarm,
>>  user.opsgenie.OpsGenieAlerts, user.opsgenie.OpsGenieHeartbeat
>> which I have removed and now weewxd works fine
>>
>> However when I start the daemon "sudo /etc/init.d/weewx start" I still 
>> get nothing,   no process is started and no logs.  Any ideas?
>>
>>
>> On Monday, 31 August 2020 at 23:49:51 UTC+1 tke...@gmail.com wrote:
>>
>>> Any particular reason why you tried to reinstall weewx? And, the version 
>>> you reinstalled is for python2.
>>>
>>> NB: there is only one code base for weewx. There is no separate Python 2 
>>> and Python 3 versions. The only difference between the two packages is in 
>>> which prerequisites get installed. But, the actually weewx code base is 
>>> identical.
>>>
>>> That is why you only needed to install the new prerequisites.
>>>
>>> Surely there is something in the logs. What happens if you try to run 
>>> weewxd directly from the command line?
>>>
>>>
>>> On Mon, Aug 31, 2020 at 3:26 PM 'Season Ticket' via weewx-user <
>>> weewx...@googlegroups.com> wrote:
>>>

 I changed /etc/default/weewx to use /usr/bin/python3
 then 

 sudo dpkg -i python-weewx_4.1.1-1_all.deb

 but now weewx won't start and no logs in /var/log/syslog
 On Monday, 31 August 2020 at 23:06:15 UTC+1 tke...@gmail.com wrote:

> I'm assuming you want to keep everything the same, except you want to 
> run under Python 3. So, all you have to do is make sure python3 gets 
> invoked, instead of python2. How to do that depends on your install 
> method.
>
> A, If you did a *package install* using apt-get, you will need to go 
> into /etc/default/weewx and change option WEEWX_PYTHON to
>
> WEEWX_PYTHON=/usr/bin/python3
>
> B. If you did a *setup.py install*, you will have to change the very 
> first line of /home/weewx/bin/weewxd to read
>
> #!/usr/bin/python3
>

Re: [weewx-user] weewx upgrade from python2 to python3

2020-09-01 Thread Tom Keffer
You're making things harder than it needs to be! No need to recompile
anything. That is done automatically by the interpreter.

1. What is in /etc/default/weewx?

2. In /etc/default/weewx, the variable WEEWX_BIN points to the copy of
weewxd to be used. *Make sure it exists*. If it does not, this will cause
/etc/init.d/weewx to exit without warning.

-tk

On Tue, Sep 1, 2020 at 1:39 AM 'Season Ticket' via weewx-user <
weewx-user@googlegroups.com> wrote:

> thanks for your persistence with this.
> I reinstalled because I expected that the code would need to be recompiled
> with python3.
> I can revert back to python2  by,  a) changing the /etc/defaults/weewx to
> reference python2 and then reinstall again using "sudo dpkg -i
> python-weewx_4.1.1-1_all.deb"
> I tried again this time with only changing the /etc/defaults/weewx file
> and running weewxd.
>
> This time I got some errors due to the following:
>  user.alarm_multi.MyAlarm,
>  user.opsgenie.OpsGenieAlerts, user.opsgenie.OpsGenieHeartbeat
> which I have removed and now weewxd works fine
>
> However when I start the daemon "sudo /etc/init.d/weewx start" I still get
> nothing,   no process is started and no logs.  Any ideas?
>
>
> On Monday, 31 August 2020 at 23:49:51 UTC+1 tke...@gmail.com wrote:
>
>> Any particular reason why you tried to reinstall weewx? And, the version
>> you reinstalled is for python2.
>>
>> NB: there is only one code base for weewx. There is no separate Python 2
>> and Python 3 versions. The only difference between the two packages is in
>> which prerequisites get installed. But, the actually weewx code base is
>> identical.
>>
>> That is why you only needed to install the new prerequisites.
>>
>> Surely there is something in the logs. What happens if you try to run
>> weewxd directly from the command line?
>>
>>
>> On Mon, Aug 31, 2020 at 3:26 PM 'Season Ticket' via weewx-user <
>> weewx...@googlegroups.com> wrote:
>>
>>>
>>> I changed /etc/default/weewx to use /usr/bin/python3
>>> then
>>>
>>> sudo dpkg -i python-weewx_4.1.1-1_all.deb
>>>
>>> but now weewx won't start and no logs in /var/log/syslog
>>> On Monday, 31 August 2020 at 23:06:15 UTC+1 tke...@gmail.com wrote:
>>>
 I'm assuming you want to keep everything the same, except you want to
 run under Python 3. So, all you have to do is make sure python3 gets
 invoked, instead of python2. How to do that depends on your install method.

 A, If you did a *package install* using apt-get, you will need to go
 into /etc/default/weewx and change option WEEWX_PYTHON to

 WEEWX_PYTHON=/usr/bin/python3

 B. If you did a *setup.py install*, you will have to change the very
 first line of /home/weewx/bin/weewxd to read

 #!/usr/bin/python3

 Same with other utilities.

 -tk

 On Mon, Aug 31, 2020 at 2:55 PM 'Season Ticket' via weewx-user <
 weewx...@googlegroups.com> wrote:

> if I choose these instructions  what do I change home to,  weewx.conf
> is in /etc/weewx?
> To specify an install location different from the default /home/weewx,
> modify the parameter home in the setup.cfg file. Mac users will want to
> change it to /Users/Shared/weewx.
> On Monday, 31 August 2020 at 22:08:58 UTC+1 tke...@gmail.com wrote:
>
>> Take a look at the prerequisite requirements for the setup.py
>> instructions . Specifically:
>>
>> sudo apt update
>>
>> # Requiredsudo apt install python3-configobj
>> sudo apt install python3-pil
>> sudo apt install python3-serial
>> sudo apt install python3-usb
>>
>> # The following tests for distutils and installs if not present:
>> python3 -c "import distutils" 2>/dev/null || sudo apt install 
>> python3-distutils
>>
>> # Install pip3 and cheetah3:
>> sudo apt install python3-pip
>> sudo pip3 install cheetah3
>>
>> # Optional: for extended almanac informationsudo apt install 
>> python3-ephem
>>
>> # Required if you are using MySQL (MariaDB):sudo apt install mysql-client
>> sudo apt install python3-mysqldb
>>
>>
>> On Mon, Aug 31, 2020 at 1:55 PM 'Season Ticket' via weewx-user <
>> weewx...@googlegroups.com> wrote:
>>
>>> i'm running weewx on raspbian v9,  with python 2.7 weewx 4.1.1,  and
>>> I'm trying to upgrade to python3.  I already have python version 3.5.3
>>> installed.
>>>
>>> what do I need to do to run weewx under python3?
>>>
>>>
>>> PRETTY_NAME="Raspbian GNU/Linux 9 (stretch)"
>>> NAME="Raspbian GNU/Linux"
>>> VERSION_ID="9"
>>> VERSION="9 (stretch)"
>>> ID=raspbian
>>> ID_LIKE=debian
>>> HOME_URL="http://www.raspbian.org/";
>>> SUPPORT_URL="http://www.raspbian.org/RaspbianForums";
>>> BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs";
>>>
>>> pi@raspberrypi:~ $ python --version
>>> Python 2.7.13
>>>
>>>

Re: [weewx-user] Weekly page not showing wind gust max data in table

2020-09-01 Thread Graham Eddy
→ see $span($day_delta=7) for rolling 7 days (vs $week for since start of week)

> On 1 Sep 2020, at 7:27 am, Tom Keffer  wrote:
> 
> NB: The weekly statistics start Sunday. It is not the same as "last 7 days."

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/EFFAA039-08E6-4111-9FBF-75EFA26FD760%40gmail.com.


[weewx-user] Re: Migration to MySQL - WeeWX with errors in syslog

2020-09-01 Thread gjr80
Thanks!

Gary

On Tuesday, 1 September 2020 at 20:50:34 UTC+10 uwe.sc...@gmail.com wrote:

> Done :-)
>
> gjr80 schrieb am Montag, 31. August 2020 um 22:31:36 UTC+2:
>
>> You are correct, though that wiki article was first written quite some 
>> time ago when the only schema shipped with WeeWX was ‘wview’. The article 
>> should be updated to highlight there are now two schemas shipped with 
>> WeeWX. Anyone can edit the wiki, hint hint
>>
>> Gary
>> On Tuesday, 1 September 2020 at 04:00:43 UTC+10 uwe.sc...@gmail.com 
>> wrote:
>>
>>> Answering myself:
>>>
>>> I think i have found the error. The description of the DB change seem to 
>>> be wrong:
>>> https://github.com/weewx/weewx/wiki/Transfer%20from%20sqlite%20to%20MySQL
>>>
>>> This part should be: 
>>> schemas.wview_*extended*.schema 
>>>
>>> Uwe S. schrieb am Montag, 31. August 2020 um 19:18:31 UTC+2:
>>>
 I've contacted the developer of Belchertown skin.
 He said that a row is missing in a table. It should be in with the 
 extended schema which is used in my installation (V4.1.x).
 Unfortunately there's nothing what he can do as it should work and he 
 asked to open a thread in this group.

 If anyone can help, would be appreciated

 Thanks

 Uwe S. schrieb am Montag, 31. August 2020 um 18:23:21 UTC+2:

> Seem to be related to the Belchertown skin. Once uninstalled, the 
> errors do not come up again. So i might need to ask the developer of the 
> skin
>
> Uwe S. schrieb am Montag, 31. August 2020 um 18:09:27 UTC+2:
>
>> Dear all, 
>>
>> i was going to move to MySQL as DB engine.
>> For this i followed the steps and transferred the DB content to MySQL 
>> using the wee_database option.
>>
>> So far it went through, WeeWX restarted and added records to the 
>> archive tabie.
>>
>> But there are errors in the syslog which are reoccuring on every run:
>>
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine: Caught 
>> unrecoverable exception in generator 
>> 'user.belchertown.HighchartsJsonGenerator'
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
>> Error trying to use database binding wx_binding to graph observation 
>> maxSolarRad. Error was: maxSolarRad.
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
>> Traceback (most recent call last):
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
>> File "/usr/share/weewx/user/belchertown.py", line 2325, in 
>> get_observation_data
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
>> (time_start_vt, time_stop_vt, obs_vt) = 
>> archive.getSqlVectors(TimeSpan(start_ts, end_ts), obs_lookup, 
>> aggregate_type, aggregate_interval)
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
>> File "/usr/share/weewx/weewx/manager.py", line 452, in getSqlVectors
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
>> aggregate_type, aggregate_interval)
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
>> File "/usr/share/weewx/weewx/xtypes.py", line 91, in get_series
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
>> raise weewx.UnknownType(obs_type)
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
>> weewx.UnknownType: maxSolarRad
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine: 
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
>> During handling of the above exception, another exception occurred:
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine: 
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
>> Traceback (most recent call last):
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
>> File "/usr/share/weewx/weewx/reportengine.py", line 197, in run
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
>> obj.start()
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
>> File "/usr/share/weewx/weewx/reportengine.py", line 280, in start
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
>> self.run()
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
>> File "/usr/share/weewx/user/belchertown.py", line 1823, in run
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
>> series_data = self.get_observation_data(binding, archive, 
>> observation_type, 
>> minstamp, maxstamp, aggregate_type, aggregate_interval, time_length, 
>> xAxis_groupby, xAxis_categories, mirrored_value, 
>> weatherRange_obs_lookup, 
>> wind_rose_color)
>> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
>> File "/usr/share/weewx/user/belchertown.py", 

Re: [weewx-user] Weekly page not showing wind gust max data in table

2020-09-01 Thread Phil Green
Hello Tom,
Thanks for the clarification, I thought the Weekly stats were a rolling 7 
days not from Sunday. 
Thanks for great software & support. 
Regards
Phil


On Monday, August 31, 2020 at 10:27:44 PM UTC+1 tke...@gmail.com wrote:

> NB: The weekly statistics start *Sunday*. It is not the same as "last 7 
> days."
>
> The week started early Sunday morning at , 30 August. From your graph, 
> the wind speed was zero all Sunday morning. So, max gust this week would be 
> zero.
>
> Or, am I misunderstanding your problem?
>
> On Mon, Aug 31, 2020 at 1:18 AM Phil Green  wrote:
>
>> Hello,
>> I have just spotted and issue with the reporting of the max wind gust on 
>> the weekly setting in the table at the left of my webpage.
>> I have altered the skin to show when the gust occurred.
>> The table is correct for month & year.
>> The graphical data is correct on the right hand side.
>> Can I check the data manually in the data base?
>> See attached screen shots.
>> Regards
>> Phil
>>
>> -- 
>> 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/a3e4cc3d-98c7-4c59-8393-2bb5ededf9ccn%40googlegroups.com
>>  
>> 
>> .
>>
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/4aea9ae1-cd1c-4047-8eaa-9c72b3caf6b6n%40googlegroups.com.


[weewx-user] Re: Migration to MySQL - WeeWX with errors in syslog

2020-09-01 Thread Uwe S.
Done :-)

gjr80 schrieb am Montag, 31. August 2020 um 22:31:36 UTC+2:

> You are correct, though that wiki article was first written quite some 
> time ago when the only schema shipped with WeeWX was ‘wview’. The article 
> should be updated to highlight there are now two schemas shipped with 
> WeeWX. Anyone can edit the wiki, hint hint
>
> Gary
> On Tuesday, 1 September 2020 at 04:00:43 UTC+10 uwe.sc...@gmail.com wrote:
>
>> Answering myself:
>>
>> I think i have found the error. The description of the DB change seem to 
>> be wrong:
>> https://github.com/weewx/weewx/wiki/Transfer%20from%20sqlite%20to%20MySQL
>>
>> This part should be: 
>> schemas.wview_*extended*.schema 
>>
>> Uwe S. schrieb am Montag, 31. August 2020 um 19:18:31 UTC+2:
>>
>>> I've contacted the developer of Belchertown skin.
>>> He said that a row is missing in a table. It should be in with the 
>>> extended schema which is used in my installation (V4.1.x).
>>> Unfortunately there's nothing what he can do as it should work and he 
>>> asked to open a thread in this group.
>>>
>>> If anyone can help, would be appreciated
>>>
>>> Thanks
>>>
>>> Uwe S. schrieb am Montag, 31. August 2020 um 18:23:21 UTC+2:
>>>
 Seem to be related to the Belchertown skin. Once uninstalled, the 
 errors do not come up again. So i might need to ask the developer of the 
 skin

 Uwe S. schrieb am Montag, 31. August 2020 um 18:09:27 UTC+2:

> Dear all, 
>
> i was going to move to MySQL as DB engine.
> For this i followed the steps and transferred the DB content to MySQL 
> using the wee_database option.
>
> So far it went through, WeeWX restarted and added records to the 
> archive tabie.
>
> But there are errors in the syslog which are reoccuring on every run:
>
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine: Caught 
> unrecoverable exception in generator 
> 'user.belchertown.HighchartsJsonGenerator'
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
> Error trying to use database binding wx_binding to graph observation 
> maxSolarRad. Error was: maxSolarRad.
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
> Traceback (most recent call last):
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  File 
> "/usr/share/weewx/user/belchertown.py", line 2325, in get_observation_data
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
> (time_start_vt, time_stop_vt, obs_vt) = 
> archive.getSqlVectors(TimeSpan(start_ts, end_ts), obs_lookup, 
> aggregate_type, aggregate_interval)
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  File 
> "/usr/share/weewx/weewx/manager.py", line 452, in getSqlVectors
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
> aggregate_type, aggregate_interval)
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  File 
> "/usr/share/weewx/weewx/xtypes.py", line 91, in get_series
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
> raise weewx.UnknownType(obs_type)
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
> weewx.UnknownType: maxSolarRad
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine: 
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
> During handling of the above exception, another exception occurred:
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine: 
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
> Traceback (most recent call last):
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  File 
> "/usr/share/weewx/weewx/reportengine.py", line 197, in run
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
> obj.start()
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  File 
> "/usr/share/weewx/weewx/reportengine.py", line 280, in start
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
> self.run()
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  File 
> "/usr/share/weewx/user/belchertown.py", line 1823, in run
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
> series_data = self.get_observation_data(binding, archive, 
> observation_type, 
> minstamp, maxstamp, aggregate_type, aggregate_interval, time_length, 
> xAxis_groupby, xAxis_categories, mirrored_value, weatherRange_obs_lookup, 
> wind_rose_color)
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  File 
> "/usr/share/weewx/user/belchertown.py", line 2327, in get_observation_data
> Aug 31 18:05:35 WeeWX weewx[18750] ERROR weewx.reportengine:  
> raise Warning( "Error trying to use database binding %s to graph 
> observation %s. Error was: 

[weewx-user] Re: randomly stops adding data

2020-09-01 Thread YB322
Just a quick update in case it helps someone.

I was reminded that there was a power outage around the same time this 
started happening. Not one to believe in coincidence, I restored the 
database from a backup of the day before the power outage, and filled the 
missing data using wee_import from WU.

So far it has been 2 days since I have experienced the issue. Possibly 
there was some kind of database corruption.

Gary - Thanks for your help, appreciate it.

Adam

On Sunday, 30 August 2020 at 12:14:34 pm UTC+10 YB322 wrote:

> Yes, that is the unit I am using. I use the WS View to configure it, the 
> is no option to update the timezone, it may have been an option when I 
> first setup, it was a while ago I don't remember if it was. I will try a 
> factory rest on the station and re-configure and see if there is.
>
> Thanks again for the help.
>
> On Sunday, 30 August 2020 at 10:11:39 am UTC+10 gjr80 wrote:
>
>> Thought the 9 hour difference seemed familiar but thought it was the 
>> other side of GMT. I'm in Brisbane.
>>
>> That's interesting about no timezone because the WU format packet coming 
>> from your station includes a UTC format date-time string so the station 
>> must somehow know what timezone it is in. Actually, just did a google for 
>> Pantech 2900 on the desktop this time, is it one of these 
>> ?
>>  
>> If so do you use the WS View app to configure? I have only used the WS View 
>> app to configure a GW1000 and in the device settings on WS View there is a 
>> timezone.
>>
>> Gary
>> On Sunday, 30 August 2020 at 09:23:49 UTC+10 YB322 wrote:
>>
>>> Thanks Gary,
>>>
>>> Timezone is Sydney\Australia (AEST - UTC+10). The station doesn't have a 
>>> timezone setting just date and time, which does look correct.
>>>
>>> It is really strange the setup had been working well for years and just 
>>> started doing it this week. I created a new server with Ubuntu 20.04 as a 
>>> troubleshooting step, but as you can see the issue came with it.
>>>
>>> Really appreciate you taking the time.
>>>
>>> Adam
>>>
>>> On Saturday, 29 August 2020 at 8:53:09 pm UTC+10 gjr80 wrote:
>>>
 Adam,

 Definitely a time issue, what timezone are you in and is the timezone 
 set correctly in you stations console?

 Gary
 On Saturday, 29 August 2020 at 20:25:41 UTC+10 YB322 wrote:

> Thanks Gary
>
> Appreciate you taking a look. I have stared at the log for the last 
> week and not noticed that one.
>
> I have pasted the debug here  https://pastebin.com/vrsDg0G6 
>
> unit is a PanTech WH2900. It does have a time setting, although it 
> does look correct.
>
> Thanks
> Adam
>
> On Saturday, 29 August 2020 at 8:11:44 pm UTC+10 gjr80 wrote:
>
>> Hi,
>>
>> I’d say you are suffering from a little temporal displacement:
>>
>> Aug 29 08:00:38 weewx weewx[2328] DEBUG user.interceptor: raw packet: 
>> {'dateTime': *1598684400*, 'usUnits': 1, 'rain_total': 0.0, 
>> 'temperature_in': 64.6, 'temperature_out': 47.7, 'dewpoint': 41.5, 
>> 'windchill': 46.8, 'humidity_in': 40.0, 'humidity_out': 79.0, 
>> 'wind_speed': 
>> 3.4, 'wind_gust': 5.8, 'wind_dir': 267.0, 'pressure': 30.65, 
>> 'barometer': 
>> 30.21, 'solar_radiation': 189.98, 'uv': 2.0, 'rain': 0.0}
>> Aug 29 08:00:38 weewx weewx[2328] DEBUG user.interceptor: mapped 
>> packet: {'dateTime': *1598684400*, 'usUnits': 1, 'pressure': 30.65, 
>> 'barometer': 30.21, 'outHumidity': 79.0, 'inHumidity': 40.0, 'outTemp': 
>> 47.7, 'inTemp': 64.6, 'windSpeed': 3.4, 'windGust': 5.8, 'windDir': 
>> 267.0, 
>> 'radiation': 189.98, 'dewpoint': 41.5, 'windchill': 46.8, 'rain': 0.0, 
>> 'UV': 2.0}
>> Aug 29 08:00:38 weewx weewx[2328] INFO weewx.manager: Added record 
>> 2020-08-29 08:00:00 AEST (*1598652000*) to database 'weewx.sdb'
>> Aug 29 08:00:38 weewx weewx[2328] INFO weewx.manager: Added record 
>> 2020-08-29 08:00:00 AEST (*1598652000*) to daily summary in 
>> 'weewx.sdb'
>>
>> What station do you have? Does it have a clock and if so is it set 
>> correctly? Might help to see a wee_debug 
>>  report. When 
>> posting the wee_debug report check the content for sensitive info such 
>> as 
>> usernames, passwords and API keys before posting, wee_debug should 
>> obfuscate such data but it’s not perfect.
>>
>> Gary
>>
>> On Saturday, 29 August 2020 at 19:10:06 UTC+10 YB322 wrote:
>>
>>> G'day everyone
>>>
>>> I have been experiencing an issue for the last week, and so far have 
>>> not been able to determine the cause. I was hoping someone may have 
>>> some 
>>> ideas.
>>>
>>> I am running the interceptor driver (
>>> https://github.com/matthewwal

Re: [weewx-user] weewx upgrade from python2 to python3

2020-09-01 Thread 'Season Ticket' via weewx-user
thanks for your persistence with this.
I reinstalled because I expected that the code would need to be recompiled 
with python3.  
I can revert back to python2  by,  a) changing the /etc/defaults/weewx to 
reference python2 and then reinstall again using "sudo dpkg -i 
python-weewx_4.1.1-1_all.deb"
I tried again this time with only changing the /etc/defaults/weewx file and 
running weewxd.  

This time I got some errors due to the following:
 user.alarm_multi.MyAlarm,
 user.opsgenie.OpsGenieAlerts, user.opsgenie.OpsGenieHeartbeat
which I have removed and now weewxd works fine

However when I start the daemon "sudo /etc/init.d/weewx start" I still get 
nothing,   no process is started and no logs.  Any ideas?


On Monday, 31 August 2020 at 23:49:51 UTC+1 tke...@gmail.com wrote:

> Any particular reason why you tried to reinstall weewx? And, the version 
> you reinstalled is for python2.
>
> NB: there is only one code base for weewx. There is no separate Python 2 
> and Python 3 versions. The only difference between the two packages is in 
> which prerequisites get installed. But, the actually weewx code base is 
> identical.
>
> That is why you only needed to install the new prerequisites.
>
> Surely there is something in the logs. What happens if you try to run 
> weewxd directly from the command line?
>
>
> On Mon, Aug 31, 2020 at 3:26 PM 'Season Ticket' via weewx-user <
> weewx...@googlegroups.com> wrote:
>
>>
>> I changed /etc/default/weewx to use /usr/bin/python3
>> then 
>>
>> sudo dpkg -i python-weewx_4.1.1-1_all.deb
>>
>> but now weewx won't start and no logs in /var/log/syslog
>> On Monday, 31 August 2020 at 23:06:15 UTC+1 tke...@gmail.com wrote:
>>
>>> I'm assuming you want to keep everything the same, except you want to 
>>> run under Python 3. So, all you have to do is make sure python3 gets 
>>> invoked, instead of python2. How to do that depends on your install method.
>>>
>>> A, If you did a *package install* using apt-get, you will need to go 
>>> into /etc/default/weewx and change option WEEWX_PYTHON to
>>>
>>> WEEWX_PYTHON=/usr/bin/python3
>>>
>>> B. If you did a *setup.py install*, you will have to change the very 
>>> first line of /home/weewx/bin/weewxd to read
>>>
>>> #!/usr/bin/python3
>>>
>>> Same with other utilities. 
>>>
>>> -tk
>>>
>>> On Mon, Aug 31, 2020 at 2:55 PM 'Season Ticket' via weewx-user <
>>> weewx...@googlegroups.com> wrote:
>>>
 if I choose these instructions  what do I change home to,  weewx.conf 
 is in /etc/weewx?
 To specify an install location different from the default /home/weewx, 
 modify the parameter home in the setup.cfg file. Mac users will want to 
 change it to /Users/Shared/weewx.  
 On Monday, 31 August 2020 at 22:08:58 UTC+1 tke...@gmail.com wrote:

> Take a look at the prerequisite requirements for the setup.py 
> instructions . Specifically:
>
> sudo apt update
>
> # Requiredsudo apt install python3-configobj
> sudo apt install python3-pil
> sudo apt install python3-serial
> sudo apt install python3-usb
>
> # The following tests for distutils and installs if not present:
> python3 -c "import distutils" 2>/dev/null || sudo apt install 
> python3-distutils
>
> # Install pip3 and cheetah3:
> sudo apt install python3-pip
> sudo pip3 install cheetah3
>
> # Optional: for extended almanac informationsudo apt install python3-ephem
>
> # Required if you are using MySQL (MariaDB):sudo apt install mysql-client
> sudo apt install python3-mysqldb
>
>
> On Mon, Aug 31, 2020 at 1:55 PM 'Season Ticket' via weewx-user <
> weewx...@googlegroups.com> wrote:
>
>> i'm running weewx on raspbian v9,  with python 2.7 weewx 4.1.1,  and 
>> I'm trying to upgrade to python3.  I already have python version 3.5.3 
>> installed.
>>
>> what do I need to do to run weewx under python3?
>>
>>
>> PRETTY_NAME="Raspbian GNU/Linux 9 (stretch)"
>> NAME="Raspbian GNU/Linux"
>> VERSION_ID="9"
>> VERSION="9 (stretch)"
>> ID=raspbian
>> ID_LIKE=debian
>> HOME_URL="http://www.raspbian.org/";
>> SUPPORT_URL="http://www.raspbian.org/RaspbianForums";
>> BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs";
>>
>> pi@raspberrypi:~ $ python --version
>> Python 2.7.13
>>
>> pi@raspberrypi:~ $ python3 --version
>> Python 3.5.3
>>
>>
>> wee_config --version
>> 4.1.1
>>
>>
>> -- 
>> 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/a8ad9b18-aaf9-4267-ae4a-0ab78337df6an%40googlegroups.com
>>  
>>