Skip to content

Commit 9c9c358

Browse files
authored
Merge branch 'master' into typeg3
2 parents 884307c + e654572 commit 9c9c358

39 files changed

+446
-397
lines changed

.github/workflows/build_wheels.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: Build wheels
2+
3+
on:
4+
push:
5+
branches: [master]
6+
tags: ['*']
7+
paths-ignore:
8+
- 'docs/**'
9+
- '**/*.rst'
10+
- '**/*.md'
11+
- .gitignore
12+
- CREDITS
13+
- LICENSE
14+
15+
jobs:
16+
build-wheels:
17+
runs-on: ubuntu-latest
18+
steps:
19+
- uses: actions/checkout@v2
20+
- uses: actions/setup-python@v2
21+
with:
22+
python-version: '3.7'
23+
- name: Trigger script
24+
env:
25+
WHEELS_PUSH_TOKEN: ${{ secrets.WHEELS_PUSH_TOKEN }}
26+
run: ./misc/trigger_wheel_build.sh

.github/workflows/docs.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Check documentation build
2+
3+
on:
4+
push:
5+
branches: [master]
6+
tags: ['*']
7+
pull_request:
8+
paths:
9+
- 'docs/**'
10+
- '**/*.rst'
11+
- '**/*.md'
12+
- CREDITS
13+
- LICENSE
14+
15+
jobs:
16+
docs:
17+
runs-on: ubuntu-latest
18+
env:
19+
TOXENV: docs
20+
steps:
21+
- uses: actions/checkout@v2
22+
- uses: actions/setup-python@v2
23+
with:
24+
python-version: '3.7'
25+
- name: Install tox
26+
run: pip install --upgrade 'setuptools!=50' 'virtualenv<16.7.11' tox==3.20.1
27+
- name: Setup tox environment
28+
run: tox -e ${{ env.TOXENV }} --notest
29+
- name: Test
30+
run: tox -e ${{ env.TOXENV }} --skip-pkg-install

.github/workflows/test.yml

Lines changed: 93 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: main
1+
name: Run tests
22

33
on:
44
push:
@@ -10,17 +10,20 @@ on:
1010
- '**/*.rst'
1111
- '**/*.md'
1212
- .gitignore
13-
- .travis.yml
1413
- CREDITS
1514
- LICENSE
1615

1716
jobs:
18-
build:
17+
main:
1918
runs-on: ${{ matrix.os }}
2019
strategy:
2120
fail-fast: false
2221
matrix:
23-
name: [windows-py37-32, windows-py37-64]
22+
name: [windows-py37-32, windows-py37-64,
23+
ubuntu-py37, ubuntu-py38,
24+
ubuntu-py36-mypyc, ubuntu-py39-mypyc,
25+
macos-py36, ubuntu-py-36-debug-build,
26+
type-checking, code-style]
2427
include:
2528
- name: windows-py37-32
2629
python: '3.7'
@@ -32,16 +35,98 @@ jobs:
3235
arch: x64
3336
os: windows-latest
3437
toxenv: py37
38+
- name: ubuntu-py37
39+
python: '3.7'
40+
arch: x64
41+
os: ubuntu-latest
42+
toxenv: py
43+
tox_extra_args: "-n 2"
44+
- name: ubuntu-py38
45+
python: '3.8'
46+
arch: x64
47+
os: ubuntu-latest
48+
toxenv: py
49+
tox_extra_args: "-n 2"
50+
- name: ubuntu-py36-mypyc
51+
python: '3.6'
52+
arch: x64
53+
os: ubuntu-latest
54+
toxenv: py
55+
tox_extra_args: "-n 2"
56+
test_mypyc: true
57+
- name: ubuntu-py39-mypyc
58+
python: '3.9'
59+
arch: x64
60+
os: ubuntu-latest
61+
toxenv: py
62+
tox_extra_args: "-n 2"
63+
test_mypyc: true
64+
- name: macos-py36
65+
python: '3.6'
66+
arch: x64
67+
os: macos-latest
68+
toxenv: py
69+
tox_extra_args: "-n 2 mypyc/test/test_run.py mypyc/test/test_external.py"
70+
- name: ubuntu-py-36-debug-build
71+
python: '3.6.8'
72+
arch: x64
73+
os: ubuntu-latest
74+
toxenv: py36
75+
tox_extra_args: "-n 2 mypyc/test/test_run.py mypyc/test/test_external.py"
76+
debug_build: true
77+
- name: type-checking
78+
python: '3.7'
79+
arch: x64
80+
os: ubuntu-latest
81+
toxenv: type
82+
- name: code-style
83+
python: '3.7'
84+
arch: x64
85+
os: ubuntu-latest
86+
toxenv: lint
3587

3688
steps:
3789
- uses: actions/checkout@v2
3890
- uses: actions/setup-python@v2
3991
with:
4092
python-version: ${{ matrix.python }}
4193
architecture: ${{ matrix.arch }}
42-
- name: install tox
94+
- name: Debug build
95+
if: ${{ matrix.debug_build }}
96+
run: |
97+
PYTHONVERSION=${{ matrix.python }}
98+
PYTHONDIR=~/python-debug/python-$PYTHONVERSION
99+
VENV=$PYTHONDIR/env
100+
./misc/build-debug-python.sh $PYTHONVERSION $PYTHONDIR $VENV
101+
source $VENV/bin/activate
102+
- name: Install tox
43103
run: pip install --upgrade 'setuptools!=50' 'virtualenv<16.7.11' tox==3.20.1
44-
- name: setup tox environment
104+
- name: Compiled with mypyc
105+
if: ${{ matrix.test_mypyc }}
106+
run: |
107+
pip install -r test-requirements.txt
108+
CC=clang MYPYC_OPT_LEVEL=0 python3 setup.py --use-mypyc build_ext --inplace
109+
- name: Setup tox environment
45110
run: tox -e ${{ matrix.toxenv }} --notest
46-
- name: test
47-
run: tox -e ${{ matrix.toxenv }} --skip-pkg-install
111+
- name: Test
112+
run: tox -e ${{ matrix.toxenv }} --skip-pkg-install -- ${{ matrix.tox_extra_args }}
113+
114+
python-nightly:
115+
runs-on: ubuntu-latest
116+
steps:
117+
- uses: actions/checkout@v2
118+
- uses: actions/setup-python@v2
119+
with:
120+
python-version: '3.10-dev'
121+
- name: Install tox
122+
run: |
123+
pip install -U pip==21.2.3 setuptools
124+
pip install --upgrade 'setuptools!=50' virtualenv==20.4.7 tox==3.20.1
125+
- name: Setup tox environment
126+
run: tox -e py --notest
127+
- name: Test
128+
run: tox -e py --skip-pkg-install -- "-n 2"
129+
continue-on-error: true
130+
- name: Mark as a success
131+
run: exit 0
132+

.travis.yml

Lines changed: 0 additions & 121 deletions
This file was deleted.

docs/source/command_line.rst

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -565,8 +565,13 @@ of the above sections.
565565
566566
# This won't re-export the value
567567
from foo import bar
568+
569+
# Neither will this
570+
from foo import bar as bang
571+
568572
# This will re-export it as bar and allow other modules to import it
569573
from foo import bar as bar
574+
570575
# This will also re-export bar
571576
from foo import bar
572577
__all__ = ['bar']

misc/trigger_wheel_build.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
# Trigger a build of mypyc compiled mypy wheels by updating the mypy
44
# submodule in the git repo that drives those builds.
55

6-
# $WHEELS_PUSH_TOKEN is stored in travis and is an API token for the
7-
# mypy-build-bot account.
6+
# $WHEELS_PUSH_TOKEN is stored in Github Settings and is an API token
7+
# for the mypy-build-bot account.
88

99
git config --global user.email "nobody"
1010
git config --global user.name "mypy wheels autopush"

0 commit comments

Comments
 (0)