Skip to content
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

Optimize GitHub Actions #116

Closed
kytta opened this issue Dec 6, 2022 · 1 comment · Fixed by #118
Closed

Optimize GitHub Actions #116

kytta opened this issue Dec 6, 2022 · 1 comment · Fixed by #118
Assignees
Labels
enhancement Something can be improved

Comments

@kytta
Copy link
Member

kytta commented Dec 6, 2022

Our actions currently spawn for every combination of Python and Django. Some of these run empty, since we don't have the tox envs for them. Instead, I would just leave the Python versions in the matrix and do the testing with tox. This way, we will spawn way less runners, which will result in our CI running faster.

Another idea: Upload coverage once, in a different step. Would also quicken our CI runs.

Example: https://github.com/jazzband/django-debug-toolbar/blob/0379d4a1ea6b22bfc79096c02d4a1d78896be1c0/.github/workflows/test.yml

@kytta
Copy link
Member Author

kytta commented Dec 7, 2022

I found out about strategy.matrix.exclude, and I like the result more. Because of parallelization, testing a single Django version per worker takes even less time.

@kytta kytta closed this as completed in #118 Dec 7, 2022
kytta added a commit that referenced this issue Dec 7, 2022
This optimizes and speeds up tests a bit by doing the following:

 - upgrades Actions' versions

 - sets cache dir name from setup.cfg instead of setup.py

 - excludes configurations where no tests are run (for example, py36-dj40)

Closes #116
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Something can be improved
Projects
None yet
1 participant