{"categories":[{"label":"Testing","url":"https://skillfed.io/packages/category/software-development-testing/2"}],"enrichment":{"capability":"Provides a pytest fixture that runs test functions concurrently in multiple threads to detect race conditions in your code.","skillfed_tags":["concurrency-testing","thread-safety"],"use_cases":["Verify that global state or shared variables are protected against concurrent modification in multi-threaded code.","Test thread-safe implementations of caches, counters, or other mutable objects accessed from multiple threads.","Detect data corruption or assertion failures that occur only under concurrent access patterns.","Validate that locks or synchronization primitives are correctly placed in critical sections."],"what_it_does":"pytest-race is a pytest plugin that adds a `start_race` fixture for testing code that may have race conditions. It runs a test function concurrently in multiple threads and checks whether the code behaves correctly under concurrent access. The fixture accepts a thread count and a test callable, then executes that callable in parallel threads to expose timing-dependent bugs.\n\nThe package has no runtime dependencies beyond pytest itself, making it lightweight to add to a test suite. However, it has been abandoned since 2022, so compatibility with modern pytest and Python versions is uncertain. The approach of using threads to surface race conditions is inherently probabilistic\u2014bugs may not always manifest in a single test run.","worth_installing":"Yes, if you need to test for race conditions in a pytest suite and are willing to accept the maintenance risk. The package is simple, has no dependencies, and works for its stated purpose. However, verify compatibility with your pytest and Python versions first, since the project is no longer maintained."},"id":"pytest-race","links":{"html":"https://skillfed.io/packages/pytest-race","md":"https://skillfed.io/packages/pytest-race.md","pypi":"https://pypi.org/project/pytest-race/"},"maintenance":{"status":"abandoned"},"meta":{"latest_release":"2022-06-07","license_spdx":null,"license_treatment":"permissive","name":"pytest-race","python_support":"unspecified","summary":"Race conditions tester for pytest"},"popularity":{"monthly_downloads":792803,"position":5044,"tier":"top_15000"},"security":{"n_vulnerabilities":0},"version":"0.2.0"}
