Bug 2033204

Summary: python-sh fails to build with Python 3.11: AssertionError: 22 != 20 : (22, 20, {'_tty_out': True, '_tty_in': False, '_err_to_out': False})
Product: [Fedora] Fedora Reporter: Tomáš Hrnčiar <thrnciar>
Component: python-shAssignee: Carl George 🤠 <carl>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 36CC: carl, infra-sig, jpena, mhroncok, python-sig, rbean, thrnciar
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: python-sh-1.14.2-5.fc37 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2022-03-19 05:11:52 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: 2016048    

Description Tomáš Hrnčiar 2021-12-16 08:26:58 UTC
python-sh fails to build with Python 3.11.0a3.

======================================================================
FAIL: test_no_fd_leak (__main__.MiscTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/builddir/build/BUILD/sh-1.14.2/test.py", line 2862, in test_no_fd_leak
    self.assertEqual(baseline, num_fds, (baseline, num_fds, opts))
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AssertionError: 22 != 20 : (22, 20, {'_tty_out': True, '_tty_in': False, '_err_to_out': False})

----------------------------------------------------------------------
Ran 171 tests in 41.525s

FAILED (failures=1, skipped=1)

https://docs.python.org/3.11/whatsnew/3.11.html

For the build logs, see:
https://copr-be.cloud.fedoraproject.org/results/@python/python3.11/fedora-rawhide-x86_64/03054586-python-sh/

For all our attempts to build python-sh with Python 3.11, see:
https://copr.fedorainfracloud.org/coprs/g/python/python3.11/package/python-sh/

Testing and mass rebuild of packages is happening in copr. You can follow these instructions to test locally in mock if your package builds with Python 3.11:
https://copr.fedorainfracloud.org/coprs/g/python/python3.11/

Let us know here if you have any questions.

Python 3.11 is planned to be included in Fedora 37. To make that update smoother, we're building Fedora packages with all pre-releases of Python 3.11.
A build failure prevents us from testing all dependent packages (transitive [Build]Requires), so if this package is required a lot, it's important for us to get it fixed soon.
We'd appreciate help from the people who know this package best, but if you don't want to work on this now, let us know so we can try to work around it on our side.

Comment 1 Ben Cotton 2022-02-08 21:21:19 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 36 development cycle.
Changing version to 36.

Comment 2 Carl George 🤠 2022-03-19 04:56:52 UTC
In https://github.com/amoffat/sh/issues/600, upstream acknowledges this is a "flaky test by nature".  I'm just going to skip it.

Comment 3 Fedora Update System 2022-03-19 05:11:21 UTC
FEDORA-2022-e5600e6670 has been submitted as an update to Fedora 37. https://bodhi.fedoraproject.org/updates/FEDORA-2022-e5600e6670

Comment 4 Fedora Update System 2022-03-19 05:11:52 UTC
FEDORA-2022-e5600e6670 has been pushed to the Fedora 37 stable repository.
If problem still persists, please make note of it in this bug report.