summaryrefslogtreecommitdiff
path: root/release.py
diff options
context:
space:
mode:
authorPaul Kehrer <paul.l.kehrer@gmail.com>2020-08-16 12:07:10 -0500
committerGitHub <noreply@github.com>2020-08-16 13:07:10 -0400
commit314c0f57aae910c1e0153c0ab23019bb11ce9072 (patch)
tree57b5fc0bda2c7a88800542faee7b724fe038e461 /release.py
parente813ce2a3f3d5451cefa670f1cac743cfa7aa2f9 (diff)
downloadpy-bcrypt-git-314c0f57aae910c1e0153c0ab23019bb11ce9072.tar.gz
convert to workflow and improve (#222)
* convert to workflow and improve * E231 should probably be ignored now that we use black but whatever * no legacy
Diffstat (limited to 'release.py')
-rw-r--r--release.py14
1 files changed, 5 insertions, 9 deletions
diff --git a/release.py b/release.py
index 9e492af..83de6b4 100644
--- a/release.py
+++ b/release.py
@@ -83,18 +83,14 @@ def build_github_actions_wheels(token, version):
session = requests.Session()
response = session.post(
- "https://api.github.com/repos/pyca/bcrypt/dispatches",
+ "https://api.github.com/repos/pyca/bcrypt/actions/workflows/"
+ "wheel-builder.yml/dispatches",
headers={
"Content-Type": "application/json",
- "Accept": "application/vnd.github.everest-preview+json",
+ "Accept": "application/vnd.github.v3+json",
"Authorization": "token {}".format(token),
},
- data=json.dumps(
- {
- "event_type": "wheel-builder",
- "client_payload": {"BUILD_VERSION": version},
- }
- ),
+ data=json.dumps({"ref": "master", "inputs": {"version": version}}),
)
response.raise_for_status()
@@ -103,7 +99,7 @@ def build_github_actions_wheels(token, version):
response = session.get(
(
"https://api.github.com/repos/pyca/bcrypt/actions/workflows/"
- "wheel-builder.yml/runs?event=repository_dispatch"
+ "wheel-builder.yml/runs?event=workflow_dispatch"
),
headers={
"Content-Type": "application/json",