Bug 1535901 - freeipa-client should not install python2 dependencies
Summary: freeipa-client should not install python2 dependencies
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: freeipa
Version: 27
Hardware: Unspecified
OS: Unspecified
urgent
urgent
Target Milestone: ---
Assignee: IPA Maintainers
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-01-18 08:55 UTC by Lukas Slebodnik
Modified: 2018-02-20 17:12 UTC (History)
7 users (show)

Fixed In Version: freeipa-4.6.3-2.fc27
Clone Of:
Environment:
Last Closed: 2018-02-20 17:12:29 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Lukas Slebodnik 2018-01-18 08:55:53 UTC
Description of problem:
All python executable files are using python3 in hashbang.
But installation of freeipa-client will install python2 even though it is not used at all.

Version-Release number of selected component (if applicable):
sh$ rpm -q freeipa-client
freeipa-client-4.6.1-3.fc27.x86_64

How reproducible:


Steps to Reproduce:
1. rpm -q python2 || echo missing python2
2. dnf install -e0 -d0 -y freeipa-client
3. rpm -q python2 || echo missing python2

Actual results:
sh# rpm -q python2 || echo missing python2
package python2 is not installed
missing python2
sh# dnf install -e0 -d0 -y freeipa-client
sh# rpm -q freeipa-client
freeipa-client-4.6.1-3.fc27.x86_64
sh# rpm -q python2 || echo missing python2
python2-2.7.14-5.fc27.x86_64

Expected results:
sh# rpm -q python2 || echo missing python2
package python2 is not installed
missing python2
sh# dnf install -e0 -d0 -y freeipa-client
sh# rpm -q freeipa-client
freeipa-client-4.6.1-5.fc27.x86_64
sh# rpm -q python2 || echo missing python2
package python2 is not installed
missing python2

Additional info:
sh# head -n 1 /usr/sbin/ipa-client-install
#!/usr/bin/python3 -E

sh# [root@552c7216f088 /]# head -n1 /usr/sbin/ipa-*
==> /usr/sbin/ipa-certupdate <==
#!/usr/bin/python3 -E  

==> /usr/sbin/ipa-client-automount <==
#!/usr/bin/python3 -E  

==> /usr/sbin/ipa-client-install <==
#!/usr/bin/python3 -E


sh# rpm -q --requires freeipa-client | grep python-
python-gssapi >= 1.2.0-5
python-ldap
python-sssdconfig

Comment 1 Lukas Slebodnik 2018-01-18 08:59:09 UTC
BTW you are quite lucky that it works for you because python3-sssdconfig is indirectly installed by authconfig and sssd

sh# dnf repoquery --whatrequires python3-sssdconfig
Last metadata expiration check: 0:04:56 ago on Thu Jan 18 08:51:08 2018.
authconfig-0:7.0.1-4.fc27.x86_64
python3-ipaserver-0:4.6.1-3.fc27.noarch
python3-ipatests-0:4.6.1-3.fc27.noarch
sssd-0:1.16.0-5.fc27.x86_64
sssd-tools-0:1.16.0-5.fc27.x86_64

Comment 2 Lukas Slebodnik 2018-01-18 09:00:05 UTC
BTW you have unnecessary dependency on libnfsidmap. 

sh# rpm -q --requires freeipa-client | grep nfs
libnfsidmap
nfs-utils

sh# rpm -q --requires nfs-utils | grep libnfs
libnfsidmap
libnfsidmap.so.0()(64bit)

Comment 3 Rob Crittenden 2018-01-18 19:18:21 UTC
The python2/3 issue has been addressed upstream in a number of commits in the ipa-4-6 branch (at least):

d4f47d17f1077f3c839c325fd3d86b363772434b
66efeb884ace3ddad5088f51cfca8f1882cd7432
74ec1f934ecfb01f2c2dff3146cca28d67b4e2a6
aaf2621e84243ab8978054cad14164ae50b539b8

This will be fixed with the next rebase.

Can you file a separate bug for the libnfsidmap dependency so this can go into POST for tracking purposes?

Comment 4 Lukas Slebodnik 2018-01-18 22:17:46 UTC
(In reply to Rob Crittenden from comment #3)
> The python2/3 issue has been addressed upstream in a number of commits in
> the ipa-4-6 branch (at least):
> 
> d4f47d17f1077f3c839c325fd3d86b363772434b
> 66efeb884ace3ddad5088f51cfca8f1882cd7432
> 74ec1f934ecfb01f2c2dff3146cca28d67b4e2a6
> aaf2621e84243ab8978054cad14164ae50b539b8
> 
> This will be fixed with the next rebase.
>
I do not see a reason for waiting till next reabase.
Most of changes were done in spec file and upstream specfile
does not 100% match fedora version.

Some of commits contains changes for server part.
And this ticket is only about dependencies for freeipa-client.

python3 + freeipa-server is a different topic and maybe for rawhide not f27.

 
> Can you file a separate bug for the libnfsidmap dependency so this can go
> into POST for tracking purpose

I only noticed that when I was investigating why freeipa-client depends on python2. It's up to you whether you want to fix that or no.

The main reason of this BZ is getting rid of python2 for freeipa-client.

Comment 5 Lukas Slebodnik 2018-01-23 09:23:23 UTC
Would you be so kind and could you provide ETA for fixing these trivial changes in spec file for freeipa-client?

If you are so bust I can ask some proven packager to do changes as part of
https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3

Comment 6 Lukas Slebodnik 2018-01-23 09:28:42 UTC
(In reply to Lukas Slebodnik from comment #5)
> Would you be so kind and could you provide ETA for fixing these trivial
> changes in spec file for freeipa-client?
> 
> If you are so bust I can ask some proven packager to do changes as part of
                ^^^^
                busy :-)
> https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3

Comment 7 Rob Crittenden 2018-01-23 15:01:44 UTC
I hardly see this as urgent.

The changes are going to be made as part of a rebase to a new upstream release expected soon which will include additional python 3 changes/fixes.

Comment 8 Lukas Slebodnik 2018-01-23 15:32:19 UTC
(In reply to Rob Crittenden from comment #7)
> The changes are going to be made as part of a rebase to a new upstream
> release expected soon which will include additional python 3 changes/fixes.

I am sorry when I was not clear enough. But could you provide ETA?

Because last upstream release was done a month ago and fedora still does not contain it. https://www.redhat.com/archives/freeipa-interest/2017-December/msg00000.html

BTW, I still did not get a point why it is related to new upstream release because it is only spec file change.

>I hardly see this as urgent.

It depends on POV. It blocks builds&testing of pure pyhton3 sssd. And I cannot do that because I need freeipa-client for testing which depends on python2 packages provided by sssd.

I would really appreciate ETA for the change so I can organize my tasks.

Comment 9 Rob Crittenden 2018-01-23 15:43:45 UTC
It'll be done when it's done, in typical software fashion. At least a few days.

The changes are not just spec changes. There are other python 3 changes that are needed as well, so even if you got just the spec changes other unexpected things could happen.

IPA is big enough that changing one part of it can affect others in non-obvious ways and without testing there is no way to know. So no, I'm not going to push out changes to a package which represents itself as a centralized identity service and potentially break production systems without going through CI.

A rebase is not strictly required here but the timing is right and we can fix a whole lot of things at once.

Comment 10 Lukas Slebodnik 2018-01-23 16:18:06 UTC
I agree that freeIPA is complex but ipa-client-install is much more trivial and it already works in python3 mode. (as it is mention in ticket description).

There are just packaging bugs which pulls python2 as a dependency. And this ticket is *only* about packaging changes in freeipa-client to unblock testing of pure python3 version of sssd. But it seems that there is not intention to help testing of other projects and it will be faster to use custom version from COPR.

I am sorry for bothering you with such unimportant request. And than you very much for pointing to upstream commit.

Comment 11 Fedora Update System 2018-01-31 23:24:42 UTC
freeipa-4.6.3-1.fc27 has been submitted as an update to Fedora 27. https://bodhi.fedoraproject.org/updates/FEDORA-2018-787ba41890

Comment 12 Fedora Update System 2018-02-01 19:30:51 UTC
freeipa-4.6.3-1.fc27 has been pushed to the Fedora 27 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-787ba41890

Comment 13 Fedora Update System 2018-02-09 00:09:43 UTC
freeipa-4.6.3-2.fc27 has been submitted as an update to Fedora 27. https://bodhi.fedoraproject.org/updates/FEDORA-2018-787ba41890

Comment 14 Fedora Update System 2018-02-09 18:46:47 UTC
freeipa-4.6.3-2.fc27 has been pushed to the Fedora 27 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-787ba41890

Comment 15 Fedora Update System 2018-02-20 17:12:29 UTC
freeipa-4.6.3-2.fc27 has been pushed to the Fedora 27 stable repository. If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.