[weewx-user] Re: Broken python dependency with CentOS 8

2020-05-29 Thread David

On Saturday, May 30, 2020 at 7:42:13 AM UTC+9:30, vince wrote:
>
> On Friday, May 29, 2020 at 1:40:28 AM UTC-7, David wrote:
>>
>> On Friday, May 29, 2020 at 11:32:47 AM UTC+9:30, vince wrote:
>> Thanks for that Vince, i'll give it a go and get back to you.
>> I understand people volunteer to do this stuff and certainly wasn't 
>> expecting an immediate fix.
>>
>>
> David - I 'did' verify that adding the bogus fake-python rpm that I posted 
> 'does' work around the problem.  The official 4.1.0 weewx rpm installs ok 
> afterward.  Tested in a centos-8 vagrant VM. 
>
Hi Vince,
Can confirm the fake-python rpm worked for me as well. I tested it late 
last night.
Thanks
David

-- 
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/94c41445-ca40-4b8d-ac11-6c720a441449%40googlegroups.com.


[weewx-user] Re: Broken python dependency with CentOS 8

2020-05-29 Thread vince
On Friday, May 29, 2020 at 10:40:47 AM UTC-7, mwall wrote:
>
> On Friday, May 29, 2020 at 12:24:14 PM UTC-4, vince wrote:
>>
>> I'll open an issue on this one this afternoon and provide some updates 
>> there, if that's ok with Tom+Matthew...
>>
>
> yes, please do.  i would like to get this fixed before the next release.
>  
>

Patch added to issue 564 comments - give it a try on both centos7 and 
centos8 variants of course.
Basically I switched to building the rpm under centos8 which seems to work 
ok for me. 

-- 
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/42b9114e-6b4a-4e95-aafe-4559ed6bc022%40googlegroups.com.


[weewx-user] Re: Broken python dependency with CentOS 8

2020-05-29 Thread vince
On Friday, May 29, 2020 at 1:40:28 AM UTC-7, David wrote:
>
> On Friday, May 29, 2020 at 11:32:47 AM UTC+9:30, vince wrote:
> Thanks for that Vince, i'll give it a go and get back to you.
> I understand people volunteer to do this stuff and certainly wasn't 
> expecting an immediate fix.
>
>
David - I 'did' verify that adding the bogus fake-python rpm that I posted 
'does' work around the problem.  The official 4.1.0 weewx rpm installs ok 
afterward.  Tested in a centos-8 vagrant VM. 

-- 
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/5ce35190-3d77-4388-924c-2d2ef21c2cfd%40googlegroups.com.


[weewx-user] Re: Broken python dependency with CentOS 8

2020-05-29 Thread vince
On Friday, May 29, 2020 at 10:40:47 AM UTC-7, mwall wrote:
>
> On Friday, May 29, 2020 at 12:24:14 PM UTC-4, vince wrote:
>>
>> I'll open an issue on this one this afternoon and provide some updates 
>> there, if that's ok with Tom+Matthew...
>>
>
> yes, please do.  i would like to get this fixed before the next release.
>  
>


https://github.com/weewx/weewx/issues/564 

-- 
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/d1522469-36d9-4eb4-a636-1467f5b9f780%40googlegroups.com.


[weewx-user] Re: Broken python dependency with CentOS 8

2020-05-29 Thread mwall
On Friday, May 29, 2020 at 12:24:14 PM UTC-4, vince wrote:
>
> I'll open an issue on this one this afternoon and provide some updates 
> there, if that's ok with Tom+Matthew...
>

yes, please do.  i would like to get this fixed before the next release.
 

-- 
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/85657b2a-0d9a-4a3c-bfed-4135c1a63d35%40googlegroups.com.


[weewx-user] Re: Broken python dependency with CentOS 8

2020-05-29 Thread vince
I'll open an issue on this one this afternoon and provide some updates 
there, if that's ok with Tom+Matthew...

-- 
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/f056d751-80fc-447f-8e2d-23dd4f3c233c%40googlegroups.com.


[weewx-user] Re: Broken python dependency with CentOS 8

2020-05-29 Thread vince
On Friday, May 29, 2020 at 6:33:22 AM UTC-7, mwall wrote:
>
> however, there *are* bld_deps that are python2:
> %define bld_deps python, python-configobj
> are these somehow getting propagated into the rpm itself?
>
>

If you run "rpm -qp --requires filename.rpm" you will see the dependencies 
that were built in.

I didn't get anywhere successfully in trying to bang on the spec file to 
tweak things.  I would agree that it shouldn't matter which version you 
build a .noarch.rpm on these days, in most cases.

What's interesting is it actually also requires 'perl' too.

[root@320c68ef1804 /]# rpm -qp --requires weewx-4.1.0-1.el8.noarch.rpm
warning: weewx-4.1.0-1.el8.noarch.rpm: Header V4 RSA/SHA1 Signature, key ID 
15306a67: NOKEY
/bin/sh
/bin/sh
/bin/sh
/bin/sh
/usr/bin/env
/usr/bin/perl
/usr/bin/python 

config(weewx) = 4.1.0-1.el8
perl(strict)
python3
python3-configobj
python3-pillow
python3-pyserial
python3-pyusb
python3-setuptools
rpmlib(CompressedFileNames) <= 3.0.4-1
rpmlib(FileDigests) <= 4.6.0-1
rpmlib(PartialHardlinkSets) <= 4.0.4-1
rpmlib(PayloadFilesHavePrefix) <= 4.0-1
rpmlib(PayloadIsXz) <= 5.2-1


Provides looks ok:

[root@320c68ef1804 /]# rpm -qp --provides weewx-4.1.0-1.el8.noarch.rpm
warning: weewx-4.1.0-1.el8.noarch.rpm: Header V4 RSA/SHA1 Signature, key ID 
15306a67: NOKEY
config(weewx) = 4.1.0-1.el8
weewx = 4.1.0-1.el8


There has to be some kind of macro expansion thing going on.  It's been so 
long since I had to dig into the internals that it's a little hazy how all 
this stuff works under the hood. 

-- 
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/61a56868-f835-4893-aec5-23c6ae985e33%40googlegroups.com.


[weewx-user] Re: Broken python dependency with CentOS 8

2020-05-29 Thread mwall
vince,

the el8 rpm worked just fine for me when i tested on a centos8 system.

however, it is quite possible that my centos8 was not as much of a virgin 
as david's centos8

it should not matter whether we build the rpm packages on centos7 or centos8

the spec file defines these deps for el8:

%define deps python3, python3-setuptools, python3-configobj, 
python3-pillow, py\
thon3-pyserial, python3-pyusb

there is no 'python' dependency in there!

however, there *are* bld_deps that are python2:

%define bld_deps python, python-configobj

are these somehow getting propagated into the rpm itself?




On 28 May 2020, at 22:13, Tom Keffer = wrote:

As per Vince's request...
-tk

-- Forwarded message -
From: vince
Date: Thu, May 28, 2020 at 7:06 PM
Subject: Private message regarding: [weewx-user] Re: Broken python 
dependency with CentOS 8
To: Tom Keffer


On Thursday, May 28, 2020 at 6:58:59 PM UTC-7, Tom Keffer wrote:
Could one of you two file an issue so we can track this? If we can't make a 
package that "just installs," there should be at least some documentation 
telling a user what to do.



If he doesn't do so, I'll get to it this week.

I took a pass at hacking on Matthew's spec file, but had an epic fail, so 
I cooked up a quick interim fake-it-out rpm for the user.

It looks from the spec file that he's building everything on centos7 
which might be where things are getting whacko.  I built mine in a centos7 
docker container just in case, but this is another one of those places 
where a bunch'o'containers might helps us work these kinds of os issues. 
 Worth a thought.

(if you can forward this to Matthew, I'd appreciate it - can't find a way 
to add a cc in reply-via-email in the google gui)

-- 
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/4b1a4b2d-0dd8-4de1-a250-4637f06910e3%40googlegroups.com.


[weewx-user] Re: Broken python dependency with CentOS 8

2020-05-29 Thread David


On Friday, May 29, 2020 at 11:32:47 AM UTC+9:30, vince wrote:
>
> Here is a quick rpm that should fake out things for you.  Try installing 
> this first and then the weewx rpm for centos8.
>
> These aren't digitally signed, so if rpm barks at you, 'use the force 
> Luke' :-)
>
> I've attached the spec file just so you can see what it has inside.  If 
> you need to tweak it, edit the .spec file and run "rpmbuild -ba 
> fake_python.spec" and install the resulting rpm.  If you have a minimal 
> centos you might need to 'yum install rpm-build' to get the rpmbuild 
> utility.   Give it a try.
>
>
> Thanks for that Vince, i'll give it a go and get back to you.
I understand people volunteer to do this stuff and certainly wasn't 
expecting an immediate fix.
My understanding is it should be a pretty simple one line change (maybe 2 
if you include updating the rpm version) to fix so thought it could be 
rolled into the rpm when the next version of WeeWX is released.

--
David

-- 
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/b9458a2a-9689-4959-8a99-4e4365ea6dd4%40googlegroups.com.


[weewx-user] Re: Broken python dependency with CentOS 8

2020-05-28 Thread vince
Here is a quick rpm that should fake out things for you.  Try installing 
this first and then the weewx rpm for centos8.

These aren't digitally signed, so if rpm barks at you, 'use the force Luke' 
:-)

I've attached the spec file just so you can see what it has inside.  If you 
need to tweak it, edit the .spec file and run "rpmbuild -ba 
fake_python.spec" and install the resulting rpm.  If you have a minimal 
centos you might need to 'yum install rpm-build' to get the rpmbuild 
utility.   Give it a try.


-- 
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/c1e94cc7-d7dc-43b6-884b-a42d1c882c01%40googlegroups.com.


fake_python.spec
Description: Binary data


fake_python-0.1-1.noarch.rpm
Description: application/redhat-package-manager


Re: [weewx-user] Re: Broken python dependency with CentOS 8

2020-05-28 Thread Tom Keffer
Could one of you two file an issue so we can track this? If we can't make a
package that "just installs," there should be at least some documentation
telling a user what to do.

-tk

On Thu, May 28, 2020 at 5:54 PM vince  wrote:

> On Thursday, May 28, 2020 at 4:47:51 PM UTC-7, David wrote:
>>
>> Hi Vince,
>> I could force the rpm installation, but was hoping to get the WeeWX rpm
>> file fixed since this will be an ongoing issue.
>>
>>
> Given people are all volunteers, you might be waiting a while for any
> particular fix in a packaged variant to be made available...
>
> If you want to do it short-term, roll your own rpm with 'rpmbuild' from
> the sources and remove the dependency.   An alternate way would be to cook
> up a bogus rpm that 'provides /usr/bin/python' (but actually does
> nothing).  Install that manually and your rpmdb will have the dependency
> expectation met.  There's a tool called "fpm" that makes this pretty easy
> to do.
>
> But if it's me, I'd just force the rpm to install and run the distributed
> version
>
> --
> 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/9e391add-0fc0-4181-91ef-25d422cb3cec%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/CAPq0zECvCACT2xHsHYOp8JyLiq_9W7LE2nQzyotJ99ZmaeuNSQ%40mail.gmail.com.


[weewx-user] Re: Broken python dependency with CentOS 8

2020-05-28 Thread vince
On Thursday, May 28, 2020 at 4:47:51 PM UTC-7, David wrote:
>
> Hi Vince,
> I could force the rpm installation, but was hoping to get the WeeWX rpm 
> file fixed since this will be an ongoing issue.
>
>
Given people are all volunteers, you might be waiting a while for any 
particular fix in a packaged variant to be made available...

If you want to do it short-term, roll your own rpm with 'rpmbuild' from the 
sources and remove the dependency.   An alternate way would be to cook up a 
bogus rpm that 'provides /usr/bin/python' (but actually does nothing). 
 Install that manually and your rpmdb will have the dependency expectation 
met.  There's a tool called "fpm" that makes this pretty easy to do.

But if it's me, I'd just force the rpm to install and run the distributed 
version

-- 
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/9e391add-0fc0-4181-91ef-25d422cb3cec%40googlegroups.com.


[weewx-user] Re: Broken python dependency with CentOS 8

2020-05-28 Thread David
On Friday, May 29, 2020 at 8:49:22 AM UTC+9:30, vince wrote:
>
> On Thursday, May 28, 2020 at 4:16:47 PM UTC-7, David wrote:
>>
>> Hi Robert,
>> Thanks for the reply.
>> I have tried this but unfortunately it doesn't solve the problem.
>> While it provides a '/usr/bin/python' file, it doesn't solve the problem 
>> of providing a package which has the required dependency.
>>
>>>
>>>
> So force the rpm installation to work around that part.  And yes.  Centos8 
> really hosed things up when they chose to have 'no' python interpreter. 
>

Hi Vince,
I could force the rpm installation, but was hoping to get the WeeWX rpm 
file fixed since this will be an ongoing issue.

Regards
David

-- 
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/75d3c326-0617-4f87-b039-95f6fe0e5ed6%40googlegroups.com.


[weewx-user] Re: Broken python dependency with CentOS 8

2020-05-28 Thread vince
On Thursday, May 28, 2020 at 4:16:47 PM UTC-7, David wrote:
>
> Hi Robert,
> Thanks for the reply.
> I have tried this but unfortunately it doesn't solve the problem.
> While it provides a '/usr/bin/python' file, it doesn't solve the problem 
> of providing a package which has the required dependency.
>
>>
>>
So force the rpm installation to work around that part.  And yes.  Centos8 
really hosed things up when they chose to have 'no' python interpreter. 

-- 
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/18a68c07-778e-4452-ad9d-42486ac5abe9%40googlegroups.com.


[weewx-user] Re: Broken python dependency with CentOS 8

2020-05-28 Thread David
Hi Robert,
Thanks for the reply.
I have tried this but unfortunately it doesn't solve the problem.
While it provides a '/usr/bin/python' file, it doesn't solve the problem of 
providing a package which has the required dependency.

Regards
David

On Friday, May 29, 2020 at 2:22:06 AM UTC+9:30, Robert Beer wrote:
>
> David,
>
> Take a look at:
>
> alternatives --list
>
> You can then set the Python version (3 in this example ):
>
> alternatives --set python /usr/bin/python3
>
> This should get you going.
>
>

-- 
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/44b386cc-ca87-487d-aeca-8ce12da38bd5%40googlegroups.com.


[weewx-user] Re: Broken python dependency with CentOS 8

2020-05-28 Thread Robert Beer
David,

Take a look at:

alternatives --list

You can then set the Python version (3 in this example ):

alternatives --set python /usr/bin/python3

This should get you going.

On Thursday, May 28, 2020 at 10:35:28 AM UTC-4, David wrote:
>
> Hi All,
> I'm trying to install WeeWX v4.1.0 on CentOS 8 and am running into 
> dependency issues with '/usr/bin/python'.
>
> # yum install weewx
> Last metadata expiration check: 0:59:04 ago on Thu 28 May 2020 22:48:17 
> ACST.
> Error:
>  Problem: cannot install the best candidate for the job
>   - nothing provides /usr/bin/python needed by weewx-4.1.0-1.el8.noarch
> (try to add '--skip-broken' to skip uninstallable packages or '--nobest' 
> to use not only best candidate packages)
>
> I understand that with CentOS 8 there is no package that provides 
> '/usr/bin/python' anymore and there are separate commands to invoke either 
> Python 2 (/usr/bin/python2) or Python 3 (/usr/bin/python3).
> To be installable on CentOS 8 the rpm has to be changed to expect either 
> /usr/bin/python2 or /usr/bin/python3.
> I was hoping someone could fix the CentOS/RHEL 8 rpm so it works.
>
> Thanks
> David
>
>

-- 
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/d31829cd-1cc8-4235-b086-113e1435c5c9%40googlegroups.com.