Bug 1900767

Summary: python-typing-extensions fails to build with Python 3.10: test fail with AssertionError
Product: [Fedora] Fedora Reporter: Tomáš Hrnčiar <thrnciar>
Component: python-typing-extensionsAssignee: Jonny Heggheim <hegjon>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: hegjon, mail, mhroncok, thrnciar
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: 2021-02-14 20:40:37 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: 1890881, 1900764    

Description Tomáš Hrnčiar 2020-11-23 16:50:37 UTC
python-typing-extensions fails to build with Python 3.10.0a2.

======================================================================
FAIL: test_keys_inheritance (__main__.TypedDictTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/builddir/build/BUILD/typing_extensions-3.7.4.3/src_py3/test_typing_extensions.py", line 1568, in test_keys_inheritance
    assert BaseAnimal.__annotations__ == {'name': str}
AssertionError

======================================================================
FAIL: test_py36_class_syntax_usage (__main__.TypedDictTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/builddir/build/BUILD/typing_extensions-3.7.4.3/src_py3/test_typing_extensions.py", line 1519, in test_py36_class_syntax_usage
    self.assertEqual(LabelPoint2D.__annotations__, {'x': int, 'y': int, 'label': str})
AssertionError: {'x': ForwardRef('int'), 'y': ForwardRef('int'), 'label': <class 'str'>} != {'x': <class 'int'>, 'y': <class 'int'>, 'label': <class 'str'>}
- {'label': <class 'str'>, 'x': ForwardRef('int'), 'y': ForwardRef('int')}
+ {'label': <class 'str'>, 'x': <class 'int'>, 'y': <class 'int'>}

----------------------------------------------------------------------
Ran 130 tests in 0.082s

FAILED (failures=2, skipped=4)
error: Bad exit status from /var/tmp/rpm-tmp.FNjGbw (%check)

For the build logs, see:
https://copr-be.cloud.fedoraproject.org/results/@python/python3.10/fedora-rawhide-x86_64/01773460-python-typing-extensions/

For all our attempts to build python-typing-extensions with Python 3.10, see:
https://copr.fedorainfracloud.org/coprs/g/python/python3.10/package/python-typing-extensions/

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.10:
https://copr.fedorainfracloud.org/coprs/g/python/python3.10/

Let us know here if you have any questions.

Python 3.10 will be included in Fedora 35. To make that update smoother, we're building Fedora packages with early pre-releases of Python 3.10.
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 Jonny Heggheim 2020-11-24 10:43:39 UTC
Reported upstream https://github.com/python/typing/issues/766

Comment 2 Jonny Heggheim 2020-12-09 16:40:10 UTC
Fixed in master for upstream in PR https://github.com/python/typing/pull/768

Comment 3 Ben Cotton 2021-02-09 15:27:56 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 34 development cycle.
Changing version to 34.

Comment 4 Miro Hrončok 2021-02-13 23:46:47 UTC
There's also https://github.com/python/typing/pull/773 now.