Abacn commented on code in PR #36757:
URL: https://github.com/apache/beam/pull/36757#discussion_r2504421964
##########
runners/google-cloud-dataflow-java/build.gradle:
##########
@@ -372,11 +372,56 @@ def buildAndPushDockerPythonContainer =
tasks.create("buildAndPushDockerPythonCo
root: "apache",
tag: project.sdk_version)
doLast {
+ def imageExists = false
+ try {
+ exec {
+ commandLine "docker", "inspect", "--type=image",
"${defaultDockerImageName}"
+ ignoreExitValue = false
+ }
+ imageExists = true
+ } catch (Exception e) {
+ println "Image ${defaultDockerImageName} not found locally: ${e.message}"
Review Comment:
What caused this? We should fix the underlying cause that docker image not
gets built. be able to build container successfully at once. This kind of
fallback logic is generally not preferred
##########
.github/workflows/beam_PostCommit_XVR_GoUsingJava_Dataflow.yml:
##########
@@ -75,15 +75,46 @@ jobs:
uses: ./.github/actions/setup-environment-action
with:
python-version: default
+ - name: Set up writable gcloud config directory
Review Comment:
Other Dataflow XVR tests also push containers in order to run tests:
https://github.com/apache/beam/blob/master/.github/workflows/beam_PostCommit_XVR_PythonUsingJava_Dataflow.yml
but what's the reason only this one requires environment setup in github
action yaml file? In general we wish to keep GHA yaml minimum, and aims to make
gradle target self contained so developers can test the target locally, or in
different environment, not necessarily rely on GitHub Action runner to run.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]