Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This pull request introduces enhancements to the project's testing and formatting workflows, focusing on improving code quality and parallelizing test execution. The most significant changes include adding
isortfor import sorting, enabling parallel test execution withpytest-xdist, and updating related configurations and scripts.Testing Workflow Enhancements:
.github/workflows/tests.yml: Addedisortto the CI workflow to check and enforce import order. Enabled parallel test execution for notebooks by adding the-n=autoflag and specifying the kernel with--nbmake-kernel=python3.run_pytests.py: Updated the pytest command to include the-n=autoflag for parallel test execution.Dependency Updates:
pyproject.toml: Addedpytest-xdist(for parallel test execution) andisort(for import sorting) as new dependencies.Documentation Updates:
.github/pull_request_template.md: Updated the pull request checklist to include a step for sorting imports usingisort.Checklist
Please complete the following checklist when submitting a PR. The PR will not be reviewed until all items are checked.
All new features include a unit test.
Make sure that the tests passed and the coverage is
sufficient by running
python run_pytests.py --tests_folder=testsorpytest tests --cov=src --cov-report=term-missing.All new functions and code are clearly documented.
The code is formatted using Black.
You can do this by running
black src tests.The code is type-checked using Mypy.
You can do this by running
mypy src tests.