-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2b1a987
commit 3669386
Showing
4 changed files
with
73 additions
and
0 deletions.
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,33 @@ | ||
name: Python CI | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
tags: ['v*'] | ||
pull_request: | ||
branches: [ master ] | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Set up Python 3.10 | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: "3.10" | ||
- name: Install protoc | ||
run: sudo apt install protobuf-compiler | ||
- name: Install requirements | ||
run: pip install -r requirements.txt | ||
- name: Build python module | ||
run: mkdir generated && protoc -I src --python_betterproto_out=generated/ src/*.proto src/service/*.proto | ||
# Appears related to https://github.com/danielgtaylor/python-betterproto/issues/238 but we need the latest beta of | ||
# betterproto to build src/service/*.proto | ||
- name: Trim python module | ||
run: sed -i '/from . import /d' generated/helium/__init__.py | ||
- name: Python artifact | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: helium_proto | ||
path: generated/helium |
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 @@ | ||
betterproto[compiler]>=2.0.0b4,<3 |
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,38 @@ | ||
# | ||
# This file is autogenerated by pip-compile with python 3.10 | ||
# To update, run: | ||
# | ||
# pip-compile | ||
# | ||
betterproto[compiler]==2.0.0b4 | ||
# via -r requirements.in | ||
black==22.1.0 | ||
# via betterproto | ||
click==8.0.3 | ||
# via black | ||
grpclib==0.4.2 | ||
# via betterproto | ||
h2==4.1.0 | ||
# via grpclib | ||
hpack==4.0.0 | ||
# via h2 | ||
hyperframe==6.0.1 | ||
# via h2 | ||
jinja2==2.11.3 | ||
# via betterproto | ||
markupsafe==2.0.1 | ||
# via jinja2 | ||
multidict==6.0.2 | ||
# via grpclib | ||
mypy-extensions==0.4.3 | ||
# via black | ||
pathspec==0.9.0 | ||
# via black | ||
platformdirs==2.5.0 | ||
# via black | ||
python-dateutil==2.8.2 | ||
# via betterproto | ||
six==1.16.0 | ||
# via python-dateutil | ||
tomli==2.0.1 | ||
# via black |
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 @@ | ||
pip-tools>=6.5.1,<7 |