File tree Expand file tree Collapse file tree 2 files changed +12
-4
lines changed
Filter options
Expand file tree Collapse file tree 2 files changed +12
-4
lines changed
Original file line number Diff line number Diff line change
1
+ # Unreleased
2
+
3
+ - Remove ` __or__ ` and ` __ror__ ` methods from ` typing_extensions.Sentinel `
4
+ on Python versions <3.10. PEP 604 was introduced in Python 3.10, and
5
+ ` typing_extensions ` does not generally attempt to backport PEP-604 methods
6
+ to prior versions.
7
+
1
8
# Release 4.14.0rc1 (May 24, 2025)
2
9
3
10
- Drop support for Python 3.8 (including PyPy-3.8). Patch by [ Victorien Plot] ( https://github.com/Viicos ) .
Original file line number Diff line number Diff line change @@ -4244,11 +4244,12 @@ def __repr__(self):
4244
4244
def __call__ (self , * args , ** kwargs ):
4245
4245
raise TypeError (f"{ type (self ).__name__ !r} object is not callable" )
4246
4246
4247
- def __or__ (self , other ):
4248
- return typing .Union [self , other ]
4247
+ if sys .version_info >= (3 , 10 ):
4248
+ def __or__ (self , other ):
4249
+ return typing .Union [self , other ]
4249
4250
4250
- def __ror__ (self , other ):
4251
- return typing .Union [other , self ]
4251
+ def __ror__ (self , other ):
4252
+ return typing .Union [other , self ]
4252
4253
4253
4254
def __getstate__ (self ):
4254
4255
raise TypeError (f"Cannot pickle { type (self ).__name__ !r} object" )
You can’t perform that action at this time.
0 commit comments