Skip to content

Commit d42fabc

Browse files
authored
1 parent 86b96f9 commit d42fabc

File tree

6 files changed

+35
-44
lines changed

6 files changed

+35
-44
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
## Upcoming
22

3+
- Switch from setup.py to pyproject.toml and setup.cfg per https://packaging.python.org/tutorials/packaging-projects/
4+
35
## 2.9
46

57
- [Rename master branch to main](https://github.com/github/renaming)

pyproject.toml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
[build-system]
2+
requires = [
3+
"setuptools>=42",
4+
"wheel",
5+
]
6+
build-backend = "setuptools.build_meta"

pyrightconfig.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
"extraPaths": ["test/generated"],
66
"include": [
77
"mypy_protobuf/",
8-
"setup.py",
98
"test/"
109
],
1110
"exclude": [

run_test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ MYPY_PROTOBUF_VENV=venv_$PY_VER_MYPY_PROTOBUF
7474
test "$(protoc-gen-mypy --version)" = "mypy-protobuf 2.9"
7575

7676
# Run mypy on mypy-protobuf internal code for developers to catch issues
77-
FILES="mypy_protobuf/main.py setup.py"
77+
FILES="mypy_protobuf/main.py"
7878
$MYPY_VENV/bin/mypy --strict --custom-typeshed-dir=$CUSTOM_TYPESHED_DIR --python-executable=$MYPY_PROTOBUF_VENV/bin/python3 --python-version=$PY_VER_MYPY_PROTOBUF_SHORT --pretty --show-error-codes $FILES
7979

8080
# Generate protos

setup.cfg

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
[metadata]
2+
name = mypy-protobuf
3+
version = attr: mypy_protobuf.main.__version__
4+
description = Generate mypy stub files from protobuf specs
5+
keywords = mypy proto dropbox
6+
license = Apache License 2.0
7+
author = Nipunn Koorapati
8+
author_email = [email protected]
9+
url = https://github.com/dropbox/mypy-protobuf
10+
download_url = https://github.com/dropbox/mypy-protobuf/releases
11+
12+
[options]
13+
py_modules =
14+
mypy_protobuf
15+
mypy_protobuf.main
16+
mypy_protobuf.extensions_pb2
17+
install_requires =
18+
protobuf>=3.17.3
19+
types-protobuf>=3.17.3
20+
grpcio-tools>=1.38.1
21+
python_requires = >=3.6
22+
23+
[options.entry_points]
24+
console_scripts =
25+
protoc-gen-mypy = mypy_protobuf.main:main
26+
protoc-gen-mypy_grpc = mypy_protobuf.main:grpc

setup.py

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

0 commit comments

Comments
 (0)