4444 Path ("Tools/build/regen-configure.sh" ),
4545})
4646
47- SUFFIXES_C_OR_CPP = frozenset ({".c" , ".h" , ".cpp" })
4847SUFFIXES_DOCUMENTATION = frozenset ({".rst" , ".md" })
4948
5049ANDROID_DIRS = frozenset ({"Android" })
5352MACOS_DIRS = frozenset ({"Mac" })
5453WASI_DIRS = frozenset ({Path ("Tools" , "wasm" )})
5554
56- LIBRARY_FUZZER_PATHS = frozenset ({
57- # All C/CPP fuzzers.
58- Path ("configure" ),
59- Path (".github/workflows/reusable-cifuzz.yml" ),
60- # ast
61- Path ("Lib/ast.py" ),
62- Path ("Python/ast.c" ),
63- # configparser
64- Path ("Lib/configparser.py" ),
65- # csv
66- Path ("Lib/csv.py" ),
67- Path ("Modules/_csv.c" ),
68- # decode
69- Path ("Lib/encodings/" ),
70- Path ("Modules/_codecsmodule.c" ),
71- Path ("Modules/cjkcodecs/" ),
72- Path ("Modules/unicodedata*" ),
73- # difflib
74- Path ("Lib/difflib.py" ),
75- # email
76- Path ("Lib/email/" ),
77- # html
78- Path ("Lib/html/" ),
79- Path ("Lib/_markupbase.py" ),
80- # http.client
81- Path ("Lib/http/client.py" ),
82- # json
83- Path ("Lib/json/" ),
84- Path ("Modules/_json.c" ),
85- # plist
86- Path ("Lib/plistlib.py" ),
87- # re
88- Path ("Lib/re/" ),
89- Path ("Modules/_sre/" ),
90- # tarfile
91- Path ("Lib/tarfile.py" ),
92- # tomllib
93- Path ("Modules/tomllib/" ),
94- # xml
95- Path ("Lib/xml/" ),
96- Path ("Lib/_markupbase.py" ),
97- Path ("Modules/expat/" ),
98- Path ("Modules/pyexpat.c" ),
99- # zipfile
100- Path ("Lib/zipfile/" ),
101- # zoneinfo
102- Path ("Lib/zoneinfo/" ),
103- Path ("Modules/_zoneinfo.c" ),
104- })
105-
106-
10755@dataclass (kw_only = True , slots = True )
10856class Outputs :
10957 run_android : bool = False
110- run_ci_fuzz : bool = False
111- run_ci_fuzz_stdlib : bool = False
11258 run_docs : bool = False
11359 run_emscripten : bool = False
11460 run_ios : bool = False
@@ -145,16 +91,6 @@ def compute_changes() -> None:
14591 if outputs .run_windows_tests :
14692 print ("Run Windows tests" )
14793
148- if outputs .run_ci_fuzz :
149- print ("Run CIFuzz tests" )
150- else :
151- print ("Branch too old for CIFuzz tests; or no C files were changed" )
152-
153- if outputs .run_ci_fuzz_stdlib :
154- print ("Run CIFuzz tests for stdlib" )
155- else :
156- print ("Branch too old for CIFuzz tests; or no stdlib files were changed" )
157-
15894 if outputs .run_docs :
15995 print ("Build documentation" )
16096
@@ -207,18 +143,8 @@ def get_file_platform(file: Path) -> str | None:
207143 return None
208144
209145
210- def is_fuzzable_library_file (file : Path ) -> bool :
211- return any (
212- (file .is_relative_to (needs_fuzz ) and needs_fuzz .is_dir ())
213- or (file == needs_fuzz and file .is_file ())
214- for needs_fuzz in LIBRARY_FUZZER_PATHS
215- )
216-
217-
218146def process_changed_files (changed_files : Set [Path ]) -> Outputs :
219147 run_tests = False
220- run_ci_fuzz = False
221- run_ci_fuzz_stdlib = False
222148 run_docs = False
223149 run_windows_tests = False
224150 run_windows_msi = False
@@ -232,8 +158,8 @@ def process_changed_files(changed_files: Set[Path]) -> Outputs:
232158 doc_file = file .suffix in SUFFIXES_DOCUMENTATION or doc_or_misc
233159
234160 if file .parent == GITHUB_WORKFLOWS_PATH :
235- if file .name in ( "build.yml" , "reusable-cifuzz.yml" ) :
236- run_tests = run_ci_fuzz = run_ci_fuzz_stdlib = run_windows_tests = True
161+ if file .name == "build.yml" :
162+ run_tests = run_windows_tests = True
237163 has_platform_specific_change = False
238164 continue
239165 if file .name == "reusable-docs.yml" :
@@ -270,18 +196,6 @@ def process_changed_files(changed_files: Set[Path]) -> Outputs:
270196 if file not in UNIX_BUILD_SYSTEM_FILE_NAMES :
271197 run_windows_tests = True
272198
273- # The fuzz tests are pretty slow so they are executed only for PRs
274- # changing relevant files.
275- if file .suffix in SUFFIXES_C_OR_CPP :
276- run_ci_fuzz = True
277- if file .parts [:2 ] in {
278- ("configure" ,),
279- ("Modules" , "_xxtestfuzz" ),
280- }:
281- run_ci_fuzz = True
282- if not run_ci_fuzz_stdlib and is_fuzzable_library_file (file ):
283- run_ci_fuzz_stdlib = True
284-
285199 # Check for changed documentation-related files
286200 if doc_file :
287201 run_docs = True
@@ -316,8 +230,6 @@ def process_changed_files(changed_files: Set[Path]) -> Outputs:
316230
317231 return Outputs (
318232 run_android = run_android ,
319- run_ci_fuzz = run_ci_fuzz ,
320- run_ci_fuzz_stdlib = run_ci_fuzz_stdlib ,
321233 run_docs = run_docs ,
322234 run_emscripten = run_emscripten ,
323235 run_ios = run_ios ,
@@ -334,10 +246,6 @@ def process_target_branch(outputs: Outputs, git_branch: str) -> Outputs:
334246 if not git_branch :
335247 outputs .run_tests = True
336248
337- # CIFuzz / OSS-Fuzz compatibility with older branches may be broken.
338- if git_branch != GITHUB_DEFAULT_BRANCH :
339- outputs .run_ci_fuzz = False
340-
341249 if os .environ .get ("GITHUB_EVENT_NAME" , "" ).lower () == "workflow_dispatch" :
342250 outputs .run_docs = True
343251 outputs .run_windows_msi = True
0 commit comments