-
Notifications
You must be signed in to change notification settings - Fork 140
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
GitHub Actions CI config #308
Merged
Merged
Changes from all commits
Commits
Show all changes
18 commits
Select commit
Hold shift + click to select a range
c536034
GitHub Actions CI config
twm 237fb6f
Set minimum Twisted to 18.7.0
twm c34dcb3
Twisted versions in matrix
twm fe5ca65
Make PyPy3 and trunk builds experimental
twm b019e20
Add timeouts
twm 6e698af
Increase RSA key size for PyPy3
twm 46b0878
Remove Travis CI config
twm 2d31fa9
Nicer job names
twm 08be5fd
Add newsfragment
twm 4e5088c
Report to coveralls
twm 7e6a75c
Coveralls
twm b15fc74
Add coveralls repo token
twm 38bc238
Make pypy-3.7 run non-experimental
twm b7a5a6e
Maybe coveralls needs a checkout?
twm 7ba6fef
Debugging...
twm 65a9a24
Remove failing coveralls --finish
twm b5e8518
Combine lints to run in parallel
twm 9d044f5
Combine Tox and Coveralls installs
twm File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,117 @@ | ||
name: CI | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
|
||
jobs: | ||
lint: | ||
runs-on: ubuntu-20.04 | ||
timeout-minutes: 5 | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- uses: actions/setup-python@v2 | ||
with: | ||
python-version: '3.8' | ||
|
||
- uses: actions/cache@v2 | ||
with: | ||
path: ~/.cache/pip | ||
key: | ||
${{ runner.os }}-pip-lint-${{ hashFiles('pyproject.toml', 'setup.py', 'tox.ini') }} | ||
restore-keys: | | ||
${{ runner.os }}-pip-lint- | ||
${{ runner.os }}-pip- | ||
|
||
- run: python -m pip install tox | ||
|
||
- run: tox -q -p all -e flake8,towncrier,twine,check-manifest | ||
|
||
docs: | ||
runs-on: ubuntu-20.04 | ||
timeout-minutes: 5 | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- uses: actions/setup-python@v2 | ||
with: | ||
python-version: "3.8" | ||
|
||
- uses: actions/cache@v2 | ||
with: | ||
path: ~/.cache/pip | ||
key: | ||
${{ runner.os }}-pip-docs-${{ hashFiles('pyproject.toml', 'setup.py', 'tox.ini') }} | ||
restore-keys: | | ||
${{ runner.os }}-pip-docs- | ||
${{ runner.os }}-pip- | ||
|
||
- run: python -m pip install tox | ||
|
||
- run: tox -q -e docs | ||
|
||
|
||
test: | ||
name: "Test ${{ matrix.python-version }} with ${{ matrix.twisted-version }} Twisted" | ||
runs-on: ubuntu-20.04 | ||
timeout-minutes: 10 | ||
continue-on-error: ${{ matrix.experimental }} | ||
strategy: | ||
matrix: | ||
python-version: ["2.7", "3.5", "3.6", "3.7", "3.8", "pypy-2.7", "pypy-3.7"] | ||
twisted-version: ["lowest", "latest"] | ||
experimental: [false] | ||
|
||
include: | ||
- python-version: "3.8" | ||
twisted-version: "trunk" | ||
experimental: true | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- uses: actions/cache@v2 | ||
with: | ||
path: ~/.cache/pip | ||
key: | ||
${{ runner.os }}-pip-${{ matrix.python-version }}-${{ hashFiles('pyproject.toml', 'setup.py', 'tox.ini') }} | ||
restore-keys: | | ||
${{ runner.os }}-pip-${{ matrix.python-version }}- | ||
${{ runner.os }}-pip- | ||
|
||
- name: Translate Python version to Tox factor | ||
id: pyfactor | ||
shell: python | ||
run: | | ||
table = { | ||
"2.7": "py27", | ||
"3.5": "py35", | ||
"3.6": "py36", | ||
"3.7": "py37", | ||
"3.8": "py38", | ||
"3.9": "py39", | ||
"pypy-2.7": "pypy", | ||
"pypy-3.7": "pypy3", | ||
} | ||
factor = table["${{ matrix.python-version }}"] | ||
print("::set-output name=value::" + factor) | ||
|
||
- run: python -m pip install tox coveralls | ||
|
||
- run: tox -e ${{ steps.pyfactor.outputs.value }}-twisted_${{ matrix.twisted-version }} | ||
|
||
- run: coveralls | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
COVERALLS_REPO_TOKEN: 4nctuKHTnVtbdmty2FgdO3iiWm1nb7xc4 | ||
COVERALLS_FLAG_NAME: python_${{ matrix.python-version }}-twisted_${{ matrix.twisted-version }} | ||
COVERALLS_PARALLEL: true |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
The minimum supported Twisted version has increased to 18.7.0. Older versions are no longer tested in CI. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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.
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.
is the coveralls token public ?
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.
As far as I can tell we don't have much choice about it. I looked at putting it in a GitHub Actions secret, but according to the documentation it wouldn't be available on PRs from forks. The Coveralls docs don't seem to treat it like a secret, either — it's at the top of the page, not obscured at all.
IMO Coveralls and Codecov aren't really worth the trouble. I'd rather focus my time on getting treq to 100% coverage than babysit these systems, so I'm not going to worry about it until and unless it becomes a real problem.