This repository was archived by the owner on Jun 10, 2020. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 31
Setup Travis and correct setup.py #8
Merged
Merged
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
b7cd5ed
Replace tab in setup.py with spaces
alanhdu 8151159
Add Travis
alanhdu de8de39
Add flake8 config to pass tests
alanhdu efc4bd8
Use `-` instead of `_`
alanhdu 3a60b08
Add Travis badge to README
alanhdu bd71995
Use numpy 1.14.0
alanhdu 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 hidden or 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 @@ | ||
.mypy_cache |
This file contains hidden or 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,17 @@ | ||
language: python | ||
python: 3.6 | ||
|
||
notifications: | ||
email: false | ||
|
||
install: | ||
- pip install -r test-requirements.txt | ||
- if [[ $TRAVIS_PYTHON_VERSION == '3.6' ]]; then pip install flake8-pyi==17.3.0; fi | ||
|
||
script: | ||
- flake8 | ||
- MYPYPATH="." mypy tests/test_simple.py | ||
|
||
cache: | ||
directories: | ||
- "$HOME/.cache/pip" |
This file contains hidden or 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 hidden or 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,9 @@ | ||
# Ignore the following errors (for stubs): | ||
# E301 expected 1 blank line, found 0 | ||
# E302 expected 2 blank lines, found 1 | ||
# E305 expected 2 blank lines after class or function definition, found 1 | ||
# E701 multiple statements on one line (colon) | ||
# E704 multiple statements on one line (def) | ||
|
||
[flake8] | ||
ignore = E301, E302, E305, E701, E704 |
This file contains hidden or 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 |
---|---|---|
@@ -1,7 +1,7 @@ | ||
from setuptools import setup, find_packages | ||
|
||
setup( | ||
name='numpy_stubs', | ||
name='numpy-stubs', | ||
maintainer="NumPy Developers", | ||
maintainer_email="[email protected]", | ||
description="PEP 561 type stubs for numpy", | ||
|
@@ -11,8 +11,8 @@ | |
packages=find_packages(), | ||
|
||
# PEP 561 requires these | ||
install_requires=['numpy~=1.13.0'], | ||
install_requires=['numpy~=1.14.0'], | ||
package_data={ | ||
'numpy': 'py.typed' | ||
'numpy': 'py.typed' | ||
}, | ||
) |
This file contains hidden or 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,3 @@ | ||
flake8==3.3.0 | ||
|
||
mypy==0.560.0 |
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.
I see that PEP 561 changed it's guidelines here. I suppose we should also rename this repository?
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.
This name (the distribution name) doesn't impact PEP 561 compliance. The package name is the real decider; when this repo starts using my PEP 561 implementation in mypy, it will need to rename the
numpy
package tonumpy-stubs
, and make according changes. Happy to do those changes when it is time.