Skip to content
This repository was archived by the owner on Oct 9, 2023. It is now read-only.

Commit 70f0ef6

Browse files
authored
Validate Python dependencies before releasing (#142)
## What is the goal of this PR? Currently, there's no validation happening before the release. We should validate that the version of `graknprotocol` is available on PyPI with newly-developed `release_validate_python_deps` ## What are the changes implemented in this PR? - Upgrade `@graknlabs_dependencies` - Add `//:release-validate-python-deps`
1 parent ce27c0b commit 70f0ef6

File tree

3 files changed

+13
-16
lines changed

3 files changed

+13
-16
lines changed

.grabl/automation.yml

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -132,11 +132,10 @@ release:
132132
filter:
133133
owner: graknlabs
134134
branch: master
135-
# TODO: add it back once we're able to depend on @graknlabs_protocol as bazel rather than artifact dependency
136-
# validation:
137-
# validate-dependencies:
138-
# image: graknlabs-ubuntu-20.04
139-
# script: bazel test //:release-validate-deps --test_output=streamed
135+
validation:
136+
validate-dependencies:
137+
image: graknlabs-ubuntu-20.04
138+
script: bazel test //:release-validate-python-deps --test_output=streamed
140139
deployment:
141140
deploy-github:
142141
image: graknlabs-ubuntu-20.04

BUILD

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ load("@graknlabs_bazel_distribution_pip//:requirements.bzl", graknlabs_bazel_dis
2727
load("@graknlabs_bazel_distribution//github:rules.bzl", "deploy_github")
2828
load("@graknlabs_bazel_distribution//artifact:rules.bzl", "artifact_extractor")
2929

30-
load("@graknlabs_dependencies//tool/release:rules.bzl", "release_validate_deps")
30+
load("@graknlabs_dependencies//tool/release:rules.bzl", "release_validate_python_deps")
3131
load("@graknlabs_dependencies//tool/checkstyle:rules.bzl", "checkstyle_test")
3232
load("@graknlabs_dependencies//distribution:deployment.bzl", "deployment")
3333
load(":deployment.bzl", github_deployment = "deployment")
@@ -109,15 +109,13 @@ artifact_extractor(
109109
artifact = "@graknlabs_grakn_core_artifact_linux//file",
110110
)
111111

112-
# TODO: add it back once we're able to depend on @graknlabs_protocol as bazel rather than artifact dependency
113-
#release_validate_deps(
114-
# name = "release-validate-deps",
115-
# refs = "@graknlabs_client_python_workspace_refs//:refs.json",
116-
# tagged_deps = [
117-
# "@graknlabs_protocol",
118-
# ],
119-
# tags = ["manual"] # in order for bazel test //... to not fail
120-
#)
112+
release_validate_python_deps(
113+
name = "release-validate-python-deps",
114+
requirements = "//:requirements.txt",
115+
tagged_deps = [
116+
"graknprotocol",
117+
],
118+
)
121119

122120
# CI targets that are not declared in any BUILD file, but are called externally
123121
filegroup(

dependencies/graknlabs/repositories.bzl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ def graknlabs_dependencies():
2323
git_repository(
2424
name = "graknlabs_dependencies",
2525
remote = "https://github.com/graknlabs/dependencies",
26-
commit = "0989c45b00a80eef83f2caa278961dd0d7fd0b76", # sync-marker: do not remove this comment, this is used for sync-dependencies by @graknlabs_dependencies
26+
commit = "bec7e4103069a08384f32bc1d3bc8e17ff5f5af0", # sync-marker: do not remove this comment, this is used for sync-dependencies by @graknlabs_dependencies
2727
)
2828

2929
def graknlabs_common():

0 commit comments

Comments
 (0)