Repository: TraceMachina/nativelink (language: rust)

Issue:
LRE/Remote sometimes tries to wait for tekton pipelineruns before they're triggered
This can lead to flaky runs like here: https://github.com/TraceMachina/nativelink/actions/runs/11638914077/job/32414391566


Discussion / hints:

Fix patch:
diff --git a/.github/workflows/lre.yaml b/.github/workflows/lre.yaml
index 36c40a406..f68860c03 100644
--- a/.github/workflows/lre.yaml
+++ b/.github/workflows/lre.yaml
@@ -153,12 +153,23 @@ jobs:
 
       - name: Wait for Tekton pipelines
         run: >
-          nix develop --impure --command
-          bash -c "kubectl wait \
-            --for=condition=Succeeded \
-            --timeout=45m \
-            pipelinerun \
-                -l tekton.dev/pipeline=rebuild-nativelink"
+          nix develop --impure --command bash << 'EOF'
+            until pr=$(kubectl get pipelinerun -o name | \
+                       grep rebuild-nativelink-run-); do
+              echo "Waiting for pipeline to be created..."
+              sleep 1
+            done
+
+            echo "Found pipeline: $pr"
+            kubectl wait --for=create $pr
+
+            echo "Waiting for pipeline to succeed..."
+            kubectl wait \
+              --for=condition=Succeeded \
+              --timeout=45m \
+              pipelinerun \
+              -l tekton.dev/pipeline=rebuild-nativelink
+          EOF
 
       - name: Wait for Configmaps
         run: >


Test patch: