Bug 988304

Summary: policycoreutils Python 3 compatibility
Product: [Fedora] Fedora Reporter: Bohuslav "Slavek" Kabrda <bkabrda>
Component: policycoreutilsAssignee: Petr Lautrbach <plautrba>
Status: CLOSED NEXTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 23CC: dwalsh, mgrepl, mhroncok, plautrba, rkuska
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-09-08 08:22:54 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Bug Depends On: 1024359    
Bug Blocks: 1014209, 1024357, 1125209    

Description Bohuslav "Slavek" Kabrda 2013-07-25 09:29:52 UTC
are there any plans for porting policycoreutils to Python 3? SELinux already has Python 3 bindings, so it would be great to have policycoreutils bindings as well (oh yes, and there are plans to move Fedora to Python 3 as a default and policycoreutils-python is dependency of cloud-init, which is one of the packages we want to port to Python 3 asap).

Comment 1 Daniel Walsh 2013-07-25 14:19:08 UTC
I started experimenting this week.  I would think it best to start work on it for F21, after F20 branches.

Comment 2 Fedora End Of Life 2013-09-16 14:48:38 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 20 development cycle.
Changing version to '20'.

More information and reason for this action is here:

Comment 3 Miro Hrončok 2013-10-29 14:02:06 UTC
Hi, we would like to use Python 3 on the default installation instead of Python 2 on Fedora 22.


According to FESCo, we should firstly focus on the cloud image.

From that perspective, your package is considered as IMPORTANT - that means, is has to be updated to Python 3, for our intention come true.

The goal here is, that at least for F22 you should provide python3- prefixed subpackage.

Please, help us update to Python 3 flawlessly.

Check if upstream already support Python 3, if yes, use it and add the support to the package.

If upstream doesn't support Python 3 yet, encourage it to do so by sending patches and offering your help.

When upstream is dead or unwilling to support Python 3, say so and we can solve the problem together.

Chances are, that you ARE the upstream. In that case, everything is easier, just do it yourself.

There is a table on wiki, that should list your package. Chances are, that you can see an upstream link that covers the problem. Anyway, please update the table with information you know.


I offer my help with this task, so if you have no idea, how to work on this, or it is just not your priority, don't hesitate to ask for help.

(As you've already realized, this is a bulk text, so if something is not quite exact about your package, sorry for that, just ask)

Comment 4 Daniel Walsh 2013-10-29 15:20:39 UTC
Already working on it.  Goal is support for F21.  Want to be able to run same code with either interpreter and then switch to python3 in F22.

Comment 5 Miro Hrončok 2014-06-09 11:54:57 UTC
I see python3 subpackage in http://koji.fedoraproject.org/koji/buildinfo?buildID=519932

Comment 6 Miro Hrončok 2015-02-27 14:30:40 UTC
The package doesn't provide all functionality, see:


Comment 7 Jaroslav Reznik 2015-03-03 14:58:37 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 22 development cycle.
Changing version to '22'.

More information and reason for this action is here:

Comment 8 Petr Lautrbach 2015-07-23 15:18:44 UTC
It's also requested to move utilities from policycoreutils-python to other non -python{,3} package.

Comment 9 Petr Lautrbach 2015-07-24 15:31:54 UTC

* Fri Jul 24 2015 Petr Lautrbach <plautrba> 2.4-5
- Move python utilities from -python to -python-utilities
- All scripts originally from policycoreutils-python use python 3 now

* Fri Jul 24 2015 Petr Lautrbach <plautrba> 2.4-4
- policycoreutils: semanage: fix moduleRecords deleteall method

* Thu Jul 23 2015 Petr Lautrbach <plautrba> 2.4-3
- Improve compatibility with python 3
- Add sepolgen module to python3 package

* Tue Jul 21 2015 Petr Lautrbach <plautrba> 2.4-2
- Add Python3 support for sepolgen module (#1125208,#1125209)