@@ -676,6 +676,7 @@ const GLOBAL_EXTENSIONS: &[&str] = &[
676676// _sha256 and _sha512 merged into _sha2 in 3.12.
677677// _xxinterpchannels added in 3.12.
678678// audioop removed in 3.13.
679+ // annotationlib added in 3.14.
679680
680681// We didn't build ctypes_test until 3.9.
681682// We didn't build some test extensions until 3.9.
@@ -738,6 +739,7 @@ const GLOBAL_EXTENSIONS_PYTHON_3_14: &[&str] = &[
738739 "_tokenize" ,
739740 "_typing" ,
740741 "_zoneinfo" ,
742+ "annotationlib" ,
741743] ;
742744
743745const GLOBAL_EXTENSIONS_MACOS : & [ & str ] = & [ "_scproxy" ] ;
@@ -1490,7 +1492,7 @@ fn validate_extension_modules(
14901492
14911493 if is_macos {
14921494 wanted. extend ( GLOBAL_EXTENSIONS_POSIX ) ;
1493- if python_major_minor == "3.13" {
1495+ if matches ! ( python_major_minor, "3.13" | "3.14" ) {
14941496 wanted. remove ( "_crypt" ) ;
14951497 }
14961498 wanted. extend ( GLOBAL_EXTENSIONS_MACOS ) ;
@@ -1514,7 +1516,7 @@ fn validate_extension_modules(
15141516 wanted. extend ( GLOBAL_EXTENSIONS_POSIX ) ;
15151517 // TODO: If there are more differences for `GLOBAL_EXTENSIONS_POSIX` in future Python
15161518 // versions, we should move the `_crypt` special-case into a constant
1517- if python_major_minor == "3.13" {
1519+ if matches ! ( python_major_minor, "3.13" | "3.14" ) {
15181520 wanted. remove ( "_crypt" ) ;
15191521 }
15201522 if matches ! ( python_major_minor, "3.9" | "3.10" | "3.11" | "3.12" ) {
@@ -1527,12 +1529,7 @@ fn validate_extension_modules(
15271529 }
15281530 }
15291531
1530- if ( is_linux || is_macos)
1531- && matches ! (
1532- python_major_minor,
1533- "3.9" | "3.10" | "3.11" | "3.12" | "3.13"
1534- )
1535- {
1532+ if ( is_linux || is_macos) {
15361533 wanted. extend ( [
15371534 "_testbuffer" ,
15381535 "_testimportmultiple" ,
@@ -1541,16 +1538,16 @@ fn validate_extension_modules(
15411538 ] ) ;
15421539 }
15431540
1544- if ( is_linux || is_macos) && python_major_minor == "3.13" {
1541+ if ( is_linux || is_macos) && matches ! ( python_major_minor, "3.13" | "3.14" ) {
15451542 wanted. extend ( [ "_suggestions" , "_testexternalinspection" ] ) ;
15461543 }
15471544
1548- if ( is_linux || is_macos) && matches ! ( python_major_minor, "3.12" | "3.13" ) {
1545+ if ( is_linux || is_macos) && matches ! ( python_major_minor, "3.12" | "3.13" | "3.14" ) {
15491546 wanted. insert ( "_testsinglephase" ) ;
15501547 }
15511548
15521549 // _wmi is Windows only on 3.12+.
1553- if matches ! ( python_major_minor, "3.12" | "3.13" ) && is_windows {
1550+ if matches ! ( python_major_minor, "3.12" | "3.13" | "3.14" ) && is_windows {
15541551 wanted. insert ( "_wmi" ) ;
15551552 }
15561553
@@ -1673,6 +1670,8 @@ fn validate_distribution(
16731670 "3.12"
16741671 } else if dist_filename. starts_with ( "cpython-3.13." ) {
16751672 "3.13"
1673+ } else if dist_filename. starts_with ( "cpython-3.14." ) {
1674+ "3.14"
16761675 } else {
16771676 return Err ( anyhow ! ( "could not parse Python version from filename" ) ) ;
16781677 } ;
@@ -1955,7 +1954,7 @@ fn validate_distribution(
19551954 false
19561955 // For some strange reason _PyWarnings_Init is exported as part of the ABI
19571956 } else if name == "_warnings" {
1958- // But not on Python 3.13 on Windows
1957+ // But not on Python 3.13+ on Windows
19591958 if triple. contains ( "-windows-" ) {
19601959 matches ! ( python_major_minor, "3.9" | "3.10" | "3.11" | "3.12" )
19611960 } else {
0 commit comments