In my previous post I thought that it would be better to send the errors 
via an image, however, I am not sure that was the best way.  In any event, 
here are the errors from the output of "systemctl status weewx":

root@zeebytes:/etc/weewx# systemctl status weewx 
● weewx.service - LSB: weewx weather system
   Loaded: loaded (/etc/init.d/weewx; generated)
   Active: active (exited) since Wed 2021-01-27 14:34:43 EST; 10s ago
     Docs: man:systemd-sysv-generator(8)
  Process: 31379 ExecStart=/etc/init.d/weewx start (code=exited, 
status=0/SUCCESS)

Jan 27 14:34:43 zeebytes.org python3[31396]: weewx[31396] CRITICAL 
__main__:     ****      self.loadServices(config_dict)
Jan 27 14:34:43 zeebytes.org python3[31396]: weewx[31396] CRITICAL 
__main__:     ****    File "/usr/share/weewx/weewx/engine.py", lin
Jan 27 14:34:43 zeebytes.org python3[31396]: weewx[31396] CRITICAL 
__main__:     ****      obj = weeutil.weeutil.get_object(svc)(self
Jan 27 14:34:43 zeebytes.org python3[31396]: weewx[31396] CRITICAL 
__main__:     ****    File "/usr/share/weewx/weeutil/weeutil.py", 
Jan 27 14:34:43 zeebytes.org python3[31396]: weewx[31396] CRITICAL 
__main__:     ****      mod = __import__(module)
Jan 27 14:34:43 zeebytes.org python3[31396]: weewx[31396] CRITICAL 
__main__:     ****    File "/usr/share/weewx/user/weather34.py", l
Jan 27 14:34:43 zeebytes.org python3[31396]: weewx[31396] CRITICAL 
__main__:     ****      except Exception, e:
Jan 27 14:34:43 zeebytes.org python3[31396]: weewx[31396] CRITICAL 
__main__:     ****                      ^
Jan 27 14:34:43 zeebytes.org python3[31396]: weewx[31396] CRITICAL 
__main__:     ****  SyntaxError: invalid syntax
Jan 27 14:34:43 zeebytes.org python3[31396]: weewx[31396] CRITICAL 
__main__:     ****  Exiting.

Please reply with any suggestions.

Thanks,

Gordon Dickens

On Wednesday, January 27, 2021 at 2:44:40 PM UTC-5 Gordon Dickens wrote:

> Thanks to Tom, Rainer and Colin for your prompt replies!
>
> I followed the instructions verbatim in the Debian guide as Tom 
> suggested.  Afterwards, I get the following dialog with the command 
> "systemctl status weewx":
> [image: weewx_status_errors.png]
>
> I also tried to reinstall with the command "apt --reinstall install 
> weewx"  but the results were the same.
>
> Tom, where did I go wrong and what do you recommend?
>
> I made a complete system backup before I attempted the migration. So, if I 
> need to, I can revert to the Python2 version but I would rather fix it now.
>
> Thanks,
>
> Gordon
>
> On Tuesday, January 26, 2021 at 5:17:17 PM UTC-5 [email protected] wrote:
>
>> Yes, that will work, but it also assumes that all the prerequisites have 
>> been installed. The Python 3 prereqs are different from Python 2.
>>
>> On Tue, Jan 26, 2021 at 2:12 PM Colin Larsen <[email protected]> wrote:
>>
>>> I remember I had to change /etc/default/weewx it to tell Weewx to start 
>>> with Python3
>>>
>>> WEEWX_PYTHON=python2    <== change to python3
>>>
>>> WEEWX_BINDIR=/usr/share/weewx
>>>
>>> WEEWX_BIN=/usr/bin/weewxd
>>>
>>> WEEWX_CFG=/etc/weewx/weewx.conf
>>>
>>> Colin
>>>
>>> On Wed, 27 Jan 2021 at 11:04, Tom Keffer <[email protected]> wrote:
>>>
>>>> Easiest is to just follow the install directions in the Debian guide 
>>>> <http://www.weewx.com/docs/debian.htm>:
>>>>
>>>>
>>>>
>>>>
>>>> *wget -qO - https://weewx.com/apt/weewx-python3.list 
>>>> <https://weewx.com/apt/weewx-python3.list> | sudo tee 
>>>> /etc/apt/sources.list.d/weewx.listsudo apt-get updatesudo apt-get install 
>>>> weewx*
>>>>
>>>>
>>>> On Tue, Jan 26, 2021 at 1:58 PM Gordon Dickens <[email protected]> 
>>>> wrote:
>>>>
>>>>> How do I make weewx use python3 instead of python2?  I initially 
>>>>> installed weewx on Debian using the Debian package over a year ago and it 
>>>>> was originally setup to use python2. I recently upgraded to weewx 4.3.0 
>>>>> with the Belchertown skin version 1.2 and so I want to also upgrade to 
>>>>> python3.   The normal way to change default packages in Debian is with 
>>>>> the 
>>>>> update-alternatives command, however, when I set python3 as the default, 
>>>>> weewx continues to use python2 as seen from the command, "ps aux | grep 
>>>>> weewx" whose output contains:
>>>>>
>>>>> python2 /usr/share/weewx/weewxd --daemon --pidfile=/var/run/weewx.pid 
>>>>> /etc/weewx/weewx.conf
>>>>>
>>>>> So, the service is started with python2.  How do I change the weewx 
>>>>> service to use python3?
>>>>>
>>>>> Thanks,
>>>>>
>>>>> Gordon
>>>>>
>>>>> -- 
>>>>> You received this message because you are subscribed to the Google 
>>>>> Groups "weewx-user" group.
>>>>> To unsubscribe from this group and stop receiving emails from it, send 
>>>>> an email to [email protected].
>>>>> To view this discussion on the web visit 
>>>>> https://groups.google.com/d/msgid/weewx-user/807bfd14-5724-4116-b369-c7d2d49f15b9n%40googlegroups.com
>>>>>  
>>>>> <https://groups.google.com/d/msgid/weewx-user/807bfd14-5724-4116-b369-c7d2d49f15b9n%40googlegroups.com?utm_medium=email&utm_source=footer>
>>>>> .
>>>>>
>>>> -- 
>>>> You received this message because you are subscribed to the Google 
>>>> Groups "weewx-user" group.
>>>> To unsubscribe from this group and stop receiving emails from it, send 
>>>> an email to [email protected].
>>>> To view this discussion on the web visit 
>>>> https://groups.google.com/d/msgid/weewx-user/CAPq0zEA76i1OPAqpLZqC4AYf%2BxLY%3DTiu2FB%3DgD51Fc635PpHuQ%40mail.gmail.com
>>>>  
>>>> <https://groups.google.com/d/msgid/weewx-user/CAPq0zEA76i1OPAqpLZqC4AYf%2BxLY%3DTiu2FB%3DgD51Fc635PpHuQ%40mail.gmail.com?utm_medium=email&utm_source=footer>
>>>> .
>>>>
>>> -- 
>>> You received this message because you are subscribed to the Google 
>>> Groups "weewx-user" group.
>>> To unsubscribe from this group and stop receiving emails from it, send 
>>> an email to [email protected].
>>>
>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/weewx-user/CACjxfUv6LcGyjQWjPKfD6hPfyLJj8NuHeBBfxMx2_nPdrauw_A%40mail.gmail.com
>>>  
>>> <https://groups.google.com/d/msgid/weewx-user/CACjxfUv6LcGyjQWjPKfD6hPfyLJj8NuHeBBfxMx2_nPdrauw_A%40mail.gmail.com?utm_medium=email&utm_source=footer>
>>> .
>>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/995072e6-cb1a-4ad4-a23f-b2baf289a7dan%40googlegroups.com.

Reply via email to