Bug 1801932 - flatpak-runtime-config requires Python 2
Summary: flatpak-runtime-config requires Python 2
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: flatpak-runtime-config
Version: 32
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Kalev Lember
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: PYTHON2_EOL BRPY27
TreeView+ depends on / blocked
 
Reported: 2020-02-11 23:25 UTC by Miro Hrončok
Modified: 2020-03-16 20:34 UTC (History)
4 users (show)

Fixed In Version: flatpak-runtime-config-32-1.fc32
Clone Of:
Environment:
Last Closed: 2020-03-16 20:34:47 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Miro Hrončok 2020-02-11 23:25:31 UTC
Hello, I have just noticed that flatpak-runtime-config requires Python 2.

According to https://fedoraproject.org/wiki/Changes/RetirePython2 packages need FESCo exception to require Python 2 in Fedora 32+.

I suppose the need here is based on the fact that flatpaks have Python 2 in their shared runtime, is that correct? Can we change that somehow?

Comment 1 Kalev Lember 2020-02-12 08:03:52 UTC
Hello!

Is it just the python2 BR that's problematic, or is python2-rpm-macros as well? We can easily drop BuildRequires: python2 and python3 both I think, it doesn't seem they are actually used. We do use the %{python2_sitelib} and %{python3_sitelib} macros though that come from the python2/3-rpm-macros packages.

As for Python 2 in the shared runtime, we do have that in the F31 runtime, yes, but that's only to support gimp and inkscape. Inkscape is already ported to Python 3 in rawhide and GIMP, hopefully, follows soon.

My plan was to keep the gimp flatpak using the F31 flatpak runtime as long as possible (as gimp needs python2) and once a gimp version with python3 support is out, then switch it to a newer runtime. This plan of course doesn't work if it takes forever for gimp to get ported to python3, but we can cross that line when F31 is starting to reach EOL.

Comment 2 Miro Hrončok 2020-02-12 09:41:32 UTC
> Is it just the python2 BR that's problematic, or is python2-rpm-macros as well? 

It is mostly the runtime requirement of python(abi) = 2.7 caused by installing to %{python2_sitelib}.

> We can easily drop BuildRequires: python2 and python3 both I think, it doesn't seem they are actually used. We do use the %{python2_sitelib} and %{python3_sitelib} macros though that come from the python2/3-rpm-macros packages.

The macros don't work without the Python interpreter. They are defined by calling /usr/bin/python2|3 with arguments.

> As for Python 2 in the shared runtime, we do have that in the F31 runtime, yes, but that's only to support gimp and inkscape.

F31 is fine. It also contains a regular (traditional?) python2 package. The F32+ python27 package is "flat" and huge.

> Inkscape is already ported to Python 3 in rawhide and GIMP, hopefully, follows soon.

I don't share that sentiment about GIMP, but I haven't checked in a while.

> My plan was to keep the gimp flatpak using the F31 flatpak runtime as long as possible (as gimp needs python2) and once a gimp version with python3 support is out, then switch it to a newer runtime. This plan of course doesn't work if it takes forever for gimp to get ported to python3, but we can cross that line when F31 is starting to reach EOL.

Proposal: Drop Python 2 runtime from Fedora 32+, revisit when F31 starts reaching EOL?

Comment 3 Kalev Lember 2020-02-12 10:37:58 UTC
> Proposal: Drop Python 2 runtime from Fedora 32+, revisit when F31 starts reaching EOL?

Sounds like a good plan to me! I'm going to put together an initial F32 flatpak runtime after the F32 branching freeze is done; I'll make sure to drop python2 from the runtime then.

Comment 4 Miro Hrončok 2020-02-12 10:52:21 UTC
Thanks.

Comment 5 Miro Hrončok 2020-03-05 23:25:53 UTC
Do you think it is OK to do this in Fedora 32 after the beta freeze, or should we postpone?

Comment 6 Kalev Lember 2020-03-06 08:42:38 UTC
I'm still definitely for dropping python2 from F32 flatpak runtime, but I'd like to keep the infra there so that we can easily add it back later if it turns out that gimp's python3 port takes longer than expected. I'd like to keep the bits in flatpak-runtime-config for now for F32 (https://src.fedoraproject.org/rpms/flatpak-runtime-config/blob/f32/f/usercustomize.py.py installed to both %{python2_sitelib} and %{python3_sitelib}).

Comment 7 Miro Hrončok 2020-03-06 09:37:26 UTC
That brings in Python 2 as a runtime requirement.

Comment 8 Kalev Lember 2020-03-06 11:25:37 UTC
Ah, indeed. OK, then it has to go completely :)

Comment 9 Kalev Lember 2020-03-06 11:30:39 UTC
I went ahead and dropped Python 2 support in https://src.fedoraproject.org/rpms/flatpak-runtime-config/c/54fb203609dca11690a4223bdbccef05e250e8d1?branch=f32

Comment 10 Fedora Update System 2020-03-06 20:23:34 UTC
flatpak-runtime-config-32-1.fc32 has been pushed to the Fedora 32 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-2020-eeb9b0fb57

Comment 11 Fedora Update System 2020-03-16 20:34:47 UTC
flatpak-runtime-config-32-1.fc32 has been pushed to the Fedora 32 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.