-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Raise where the fuzzer found aborts and stack overflows, and collect with the count in the object header #8551
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
e71a5fd
e981e03
9b40373
562dd86
6b9b80d
4573909
b077f20
45ce8f4
c7e2658
94dc4db
5a9c726
4df44e8
aff3fca
8f8382c
1c7899d
800c2d8
da37fb8
c0faf2d
b2ad9b1
3613b89
9f3580b
e07987d
357ed5e
468f9dd
09dca1e
0f38af2
7392a20
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -80,7 +80,10 @@ jobs: | |
| if: ${{ !contains(github.event.pull_request.labels.*.name, 'skip:ci') }} | ||
| env: | ||
| RUST_BACKTRACE: full | ||
| name: Run rust tests | ||
| # Named after the matrix entry rather than left to be named for it: a | ||
| # generated name lists every value in the entry, so adding or removing one | ||
| # renames the check and drops it from the required list. | ||
| name: Run rust tests (${{ matrix.os }}) | ||
| runs-on: ${{ matrix.os }} | ||
| timeout-minutes: 45 | ||
| strategy: | ||
|
|
@@ -165,7 +168,10 @@ jobs: | |
| if: runner.os == 'Linux' | ||
|
|
||
| cargo_check: | ||
| name: cargo check | ||
| # Named after the matrix entry rather than left to be named for it: a | ||
| # generated name lists every value in the entry, so adding or removing one | ||
| # renames the check and drops it from the required list. | ||
| name: cargo check (${{ matrix.os }}, ${{ matrix.target }}) | ||
| runs-on: ${{ matrix.os }} | ||
| needs: | ||
| - determine_changes | ||
|
|
@@ -292,7 +298,10 @@ jobs: | |
| test_multiprocessing_fork | ||
| test_multiprocessing_forkserver | ||
| test_multiprocessing_spawn | ||
| name: Run snippets and cpython tests | ||
| # Named after the matrix entry rather than left to be named for it: a | ||
| # generated name lists every value in the entry, so adding or removing one | ||
| # renames the check and drops it from the required list. | ||
| name: Run snippets and cpython tests (${{ matrix.os }}) | ||
| runs-on: ${{ matrix.os }} | ||
| strategy: | ||
| matrix: | ||
|
|
@@ -302,26 +311,23 @@ jobs: | |
| - '-u all' | ||
| - '--timeout 600' | ||
| - '--dont-add-python-opts' | ||
| env_polluting_tests: | ||
| - test_set | ||
| env_polluting_tests: [] | ||
| skips: [] | ||
| timeout: 50 | ||
| - os: ubuntu-latest | ||
| extra_test_args: | ||
| - '-u all' | ||
| - '--timeout 600' | ||
| - '--dont-add-python-opts' | ||
| env_polluting_tests: | ||
| - test_set | ||
| env_polluting_tests: [] | ||
| skips: [] | ||
| timeout: 60 | ||
| - os: windows-2025 | ||
| extra_test_args: | ||
| - '-u all' | ||
| - '--timeout 600' | ||
| - '--dont-add-python-opts' | ||
| env_polluting_tests: | ||
| - test_set | ||
| env_polluting_tests: [] | ||
|
Comment on lines
+314
to
+330
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🩺 Stability & Availability | 🟡 Minor | ⚡ Quick win 🧩 Analysis chain🏁 Script executed: #!/bin/bash
set -euo pipefail
rg -n -C 4 '\btest_set\b|env_polluting_tests|POLLUTERS' .github extra_testsRepository: RustPython/RustPython Length of output: 3196 🏁 Script executed: #!/bin/bash
set -euo pipefail
printf '%s\n' '--- tracked candidates ---'
git ls-files -- .github/workflows/ci.yaml extra_tests | sed -n '1,120p'
printf '%s\n' '--- references ---'
rg -n -C 6 '\btest_set\b|env_polluting_tests|POLLUTERS' .github extra_tests
printf '%s\n' '--- workflow sections ---'
sed -n '285,345p' .github/workflows/ci.yaml
sed -n '395,450p' .github/workflows/ci.yamlRepository: RustPython/RustPython Length of output: 3167 🌐 Web query:
💡 Result: In the context of the RustPython project, env_polluting_tests is a configuration key used in GitHub Actions CI workflows to track and manage test suites that modify the shared global environment, such as changing environment variables, system settings, or global state, which can cause subsequent tests to fail [1][2]. The term POLLUTERS refers specifically to these tests that "pollute" the environment [1][2]. The workflow uses this configuration to: 1. Identify Tests: It lists specific test sets in matrix.env_polluting_tests that are known to have side effects [1][2]. 2. Isolate/Skip: The CI environment is configured to skip these tests by default using the RUSTPYTHON_SKIP_ENV_POLLUTERS environment variable [1][2]. 3. Verify Remediation: The CI includes a specific job designed to check if tests previously marked as polluters have been fixed [1][2]. This job runs the tests multiple times; if a test no longer triggers an "environment changed" exit code (specifically exit code 3 in the CPython test runner context), it provides a message instructing developers to remove that test from the env_polluting_tests list and remove any associated skip decorators that contain the keyword POLLUTERS in the source code [1][2]. Essentially, this mechanism serves as a technical debt management strategy for ensuring that tests are isolated and do not leave the system in a state that impacts the reliability of the overall test suite [1][2]. Citations:
🌐 Web query:
💡 Result: In the context of software testing, particularly within projects like RustPython, a test is considered a POLLUTER (or "env polluter") if it modifies the global environment or state in a way that affects the execution or results of subsequent tests [1][2]. When a test pollutes the environment, it may cause later tests to fail, behave unpredictably, or produce "flaky" results, even if those later tests would otherwise pass in isolation. Developers use mechanisms to identify and manage these polluters to ensure the stability and reliability of the test suite [1][2]. Key strategies for managing POLLUTERS include: 1. Identification: Developers explicitly track and categorize tests known to cause environmental side effects [1][2]. 2. Isolation/Skipping: Build configurations, such as CI/CD workflows, are often designed to skip known polluters during standard test runs (e.g., using environment variables like RUSTPYTHON_SKIP_ENV_POLLUTERS) to prevent them from interfering with other tests [1][2]. 3. Targeted Testing: Once identified, these tests are often run separately or in a controlled environment to verify if the pollution issue has been resolved, allowing them to eventually be removed from the exclusion lists [1][2]. Citations:
🌐 Web query:
💡 Result: In the RustPython repository, test_set refers to the test suite for Python set objects, specifically implemented in the file Lib/test/test_set.py [1][2]. This file contains the standard Python unit tests for the set data type [1][2]. The identifier test_set is commonly referenced in the repository's CI configurations [3][4] and issue trackers [5][6][1][2] as part of the ongoing effort to track and maintain compatibility with the CPython standard library tests. It should not be confused with test_sets, which is a method name found within other test files, such as Lib/test/test_compare.py [7]. Citations:
🌐 Web query:
💡 Result: In machine learning, a test set is a subset of a dataset held back from the training process to provide an unbiased evaluation of a final model. Its primary purpose is to assess how well the model generalizes to new, unseen data, rather than just how well it memorized the training examples. While the training set is used to fit the model parameters, the test set is used only after training is complete to report final performance metrics. A validation set is typically used during the development phase to tune hyperparameters and perform model selection, ensuring the final model is ready for the unseen data in the test set. By separating these datasets, researchers can identify if a model is suffering from overfitting, where it performs well on known data but fails to perform accurately on new inputs. Citations:
🌐 Web query:
💡 Result: In the context of the RustPython project, env_polluting_tests is a configuration key used within GitHub Actions CI workflows to identify and track specific test suites that modify the global environment (e.g., changing environment variables, file system state, or system settings) in a way that affects other tests [1][2]. These tests are identified and listed in the CI matrix to manage how they are executed [1]. Because they pollute the environment, they can cause side effects that lead to flaky or incorrect results in subsequent tests. The CI workflow includes a dedicated step that runs these identified tests specifically to check if they have stopped polluting the environment [1][2]. By monitoring these tests, the developers can: 1. Identify when a test is no longer causing environmental pollution [1][2]. 2. Enforce better test isolation by encouraging the removal of these tests from the list once they are fixed [1][2]. 3. Apply specific skip decorators or test flags (such as --fail-env-changed) to control their execution safely during the CI process [1][2]. Essentially, it acts as a tracking mechanism to isolate "bad actor" tests that violate test independence, allowing the project to eventually clean them up and improve overall test suite reliability [1][2]. Citations:
🌐 Web query:
💡 Result: In the RustPython project's CI configuration (located in.github/workflows/ci.yaml), env_polluting_tests is a matrix variable used to identify and manage test suites that modify the shared testing environment in a way that affects subsequent tests [1]. Tests listed under this variable are executed in a specific, repetitive manner within the CI pipeline to ensure they do not cause persistent side effects [1]. The CI process runs these tests multiple times (up to 10 attempts by default) while monitoring for specific exit codes [1]. If a test is detected to be polluting the environment, the CI pipeline flags it, and developers are instructed to investigate the specific test item responsible, often by marking it with skip decorators or resolving the underlying incompatibility [1]. Once a test is confirmed to no longer pollute the environment, it should be removed from the env_polluting_tests list in the ci.yaml file [1]. Citations: 🌐 Web query:
💡 Result: In the context of the RustPython project, "POLLUTERS" refers to a specific categorization of tests—often those that are unstable, have side effects, or negatively impact the reliability of the test suite [1][2][3]. The project's automation workflows contain instructions to identify and remove skip decorators that include the word "POLLUTERS" from test files [2][3]. This suggests that "POLLUTERS" is a label used within the codebase to mark tests that are being skipped or temporarily disabled due to their disruptive nature [2][3]. Regarding test_set.py, it is a standard Python library test file used to verify set functionality [4][5][6]. While test_set.py is frequently updated as part of the project's ongoing efforts to synchronize with newer CPython versions [5][6], the term "POLLUTERS" is a broader management mechanism for test reliability in the RustPython repository, rather than a specific feature of the set implementation itself [2][3]. Citations:
🌐 Web query:
💡 Result: RUSTPYTHON_SKIP_ENV_POLLUTERS is an environment variable used in the RustPython project's CI/CD pipeline (specifically in GitHub Actions) to control the execution of tests that modify or "pollute" the global environment [1][2][3]. When this variable is set to true (e.g., env: RUSTPYTHON_SKIP_ENV_POLLUTERS: true), it instructs the test runner to skip specific tests known to alter system state in a way that could affect subsequent tests [1][2]. Key points regarding its use: 1. CI Configuration: It is primarily used in workflow files (such as.github/workflows/ci.yaml) to ensure that stability-sensitive tests do not interfere with the reliability of the test suite [1][2]. 2. Test Stability: RustPython maintains lists of "polluting" tests [1]. These tests are often run separately or with specific configurations to monitor if they continue to pollute the environment, with the goal of eventually removing them from the exclusion lists once the underlying issues are resolved [1][2]. 3. Mechanism: The variable functions as a conditional flag within the test execution logic to prevent certain test items from running during standard CI passes [1][2]. There is no standard "test_set" command associated with this variable; rather, "test_set" likely refers to the suite or collection of tests that are being skipped or managed based on this environment variable's state [1][2]. Citations:
🌐 Web query:
💡 Result: In the RustPython codebase, the mention of "environment polluter" in Lib/test/test_set.py refers to tests that alter the global environment (such as environment variables or system state) and therefore may cause side effects in other tests [1]. To handle this, RustPython uses a specific environment variable mechanism, Citations:
🌐 Web query:
💡 Result: In the RustPython CI configuration (specifically in.github/workflows/ci.yaml), env_polluting_tests is a list used to identify and isolate tests that modify the global environment in ways that interfere with subsequent tests [1][2]. The primary purpose of this mechanism is to detect and address tests that fail to clean up after themselves [2]. The CI workflow includes a specific job that explicitly checks if these tests are still "polluting" the environment [2]. This process involves: 1. Running the identified tests in a loop (up to 10 attempts) [1][2]. 2. Using the --fail-env-changed flag with the test runner to detect if the environment has been altered [1][2]. 3. Reporting success if a test stops polluting, prompting developers to remove the test from the env_polluting_tests list and remove associated skip decorators in the test code [1][2]. This helps maintain the integrity of the test suite by ensuring that tests are properly isolated and that environment-altering tests are identified, fixed, or explicitly managed [2]. Citations:
🌐 Web query:
💡 Result: The hash string "b7875fe8f2f75df9a351b4a5a872b1152c4bbdd1" does not appear to be a recognized or valid Git commit hash within the RustPython project repository [1][2][3][4]. RustPython is a prominent open-source Python 3 interpreter written entirely in Rust, designed for embedding in Rust applications or compiling to WebAssembly [1][5]. As of August 2026, the project remains active with ongoing development, including work on bytecode parity and standard library updates [1][6][2][7]. The string provided likely does not correspond to project-specific code, documentation, or commit history [1][8][9][10]. Users looking for specific historical states or changes in the RustPython repository should use valid 7-character or full 40-character commit hashes found in the project's official commit logs [2][3][4][11]. Citations:
🌐 Web query:
💡 Result: The code snippet Citations: 🌐 Web query:
💡 Result: In the RustPython project, when a test is identified as an "env polluter"—meaning it fails to clean up after itself and causes failures in subsequent tests when run with the Citations:
🌐 Web query:
💡 Result: The terms Citations:
Keep 🤖 Prompt for AI Agents |
||
| skips: [] | ||
| timeout: 50 | ||
| fail-fast: false | ||
|
|
@@ -465,7 +471,10 @@ jobs: | |
| run: python -I scripts/whats_left.py ${{ env.CARGO_ARGS }} --features jit | ||
|
|
||
| clippy: | ||
| name: clippy | ||
| # Named after the matrix entry rather than left to be named for it: a | ||
| # generated name lists every value in the entry, so adding or removing one | ||
| # renames the check and drops it from the required list. | ||
| name: clippy (${{ matrix.os }}) | ||
| runs-on: ${{ matrix.os }} | ||
| needs: | ||
| - determine_changes | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🩺 Stability & Availability | 🟡 Minor | ⚡ Quick win
🧩 Analysis chain
🏁 Script executed:
Repository: RustPython/RustPython
Length of output: 204
🏁 Script executed:
Repository: RustPython/RustPython
Length of output: 8264
🏁 Script executed:
Repository: RustPython/RustPython
Length of output: 9776
🌐 Web query:
GitHub Actions ubuntu-latest ubuntu-slim hosted runner images GNU coreutils timeout command --kill-after official documentation💡 Result:
The GitHub Actions ubuntu-latest hosted runner images (currently based on Ubuntu 24.04 LTS) include the standard GNU coreutils package, which provides the timeout command [1][2][3]. This command supports the --kill-after option [4][5]. The --kill-after=DURATION option is a feature of the GNU coreutils timeout utility that ensures the monitored command is forcefully killed by sending a SIGKILL signal if it is still running after the specified duration has elapsed following the initial signal [5]. Key details regarding this command in the GitHub Actions environment include: - Availability: The timeout command is part of the coreutils package pre-installed on all official Ubuntu-based GitHub Actions runners [6][7]. - Version: As of August 2026, these runners use recent versions of Ubuntu (e.g., 24.04 LTS), which include modern versions of GNU coreutils (e.g., 9.x) that fully support the --kill-after flag [6][8][5]. - Official Documentation: The behavior of this command, including the --kill-after option, is documented in the official GNU Coreutils manual [5]. Usage Example: To run a command that is terminated by a SIGTERM after 5 seconds and subsequently killed by a SIGKILL if it is still running 3 seconds later, use: timeout -s TERM -k 3s 5s [5]
Citations:
Force-stop timed-out
apt-getprocesses.The Linux GitHub-hosted runners used by this action provide GNU
timeout, including--kill-after. Add a short grace period:Proposed fix
📝 Committable suggestion
🤖 Prompt for AI Agents