Bug 1789210

Summary: Fix Python 3.9 compatibility
Product: [Fedora] Fedora Reporter: Charalampos Stratakis <cstratak>
Component: python-pickleshareAssignee: Mukundan Ragavan <nonamedotc>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: igor.raits, mhroncok, nonamedotc
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-01-12 19:54:13 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:
Embargoed:
Bug Depends On:    
Bug Blocks: 1785415    

Description Charalampos Stratakis 2020-01-09 04:03:15 UTC
python-pickleshare is not compatible with Python 3.9

While it still builds, packages that use its code, like ipykernel fail to build from source.

This currently blocks the initial Python 3.9 bootstrap sequence.

The code that requires fixing:

diff --git a/pickleshare.py b/pickleshare.py
index 31f093c..a7e5e76 100644
--- a/pickleshare.py
+++ b/pickleshare.py
@@ -45,7 +45,7 @@ except ImportError:
     from pathlib2 import Path
 
 import os,stat,time
-import collections
+import collections.abc
 try:
     import cPickle as pickle
 except ImportError:
@@ -63,7 +63,7 @@ def gethashfile(key):
 
 _sentinel = object()
 
-class PickleShareDB(collections.MutableMapping):
+class PickleShareDB(collections.abc.MutableMapping):
     """ The main 'connection' object for PickleShare database """
     def __init__(self,root):
         """ Return a db object that will manage the specied directory"""

Comment 1 Mukundan Ragavan 2020-01-09 22:32:36 UTC
Should this be built on rawhide or a side-tag?

Comment 2 Miro Hrončok 2020-01-09 23:13:21 UTC
All we need is a fix pushed to master, no need to bump release, no need to build. Side tag is not yet ready and will not be before rawhide is F33.

Comment 3 Mukundan Ragavan 2020-01-10 02:39:24 UTC
In that case, let me update this to 0.7.5. The current rawhide version is only 0.7.4. I will get this done in a day or two.

Comment 4 Mukundan Ragavan 2020-01-11 21:46:10 UTC
I updated pickleshare to 0.7.5. This fixes the py 3.9 incompatibility natively. No need for the patch.

Please verify.

Comment 5 Miro Hrončok 2020-01-12 19:54:13 UTC
python-ipykernel builds with the updated pickleshare. Thank you.