argoproj / argo-cd

Declarative Continuous Deployment for Kubernetes
https://argo-cd.readthedocs.io
Apache License 2.0
18.07k stars 5.53k forks source link

Race: repository.TestGenerateManifestsHelmWithRefs_CachedNoLsRemote #20035

Open jsoref opened 2 months ago

jsoref commented 2 months ago

Checklist:

Describe the bug

https://github.com/argoproj/argo-cd/actions/runs/10933071333/job/30351016108#step:16:5740

To Reproduce

  1. Create a PR for some non Go code
  2. See Race workflow failure

Expected behavior

PRs that don't change Go code/workflows that fail shouldn't be blocked by failures in Go code/workflows they aren't changing.

Screenshots

https://github.com/argoproj/argo-cd/actions/runs/10933071333

Version

https://github.com/argoproj/argo-cd/commit/1d77fe52e1d9750af9f22178462a0744ab7cf727

Logs

FAIL reposerver/repository.TestGenerateManifestsHelmWithRefs_CachedNoLsRemote (0.12s)
  time="2024-09-19T02:06:32Z" level=info msg="manifest cache miss: &ApplicationSource{RepoURL:file:///tmp/TestGenerateManifestsHelmWithRefs_CachedNoLsRemote1728810496/001/tmprepo,Path:.,TargetRevision:HEAD,Helm:&ApplicationSourceHelm{ValueFiles:[$ref/test.yaml],Parameters:[]HelmParameter{},ReleaseName:,Values:,FileParameters:[]HelmFileParameter{},Version:,PassCredentials:false,IgnoreMissingValueFiles:false,SkipCrds:false,ValuesObject:nil,Namespace:,KubeVersion:,APIVersions:[],},Kustomize:nil,Directory:nil,Plugin:nil,Chart:,Ref:,}/992165053266c3043b11e6931947a8ae83a147be"
  time="2024-09-19T02:06:32Z" level=info msg="Initializing file:///tmp/TestGenerateManifestsHelmWithRefs_CachedNoLsRemote1728810496/001/tmprepo to /tmp/TestGenerateManifestsHelmWithRefs_CachedNoLsRemote1728810496/001/tmprepo/b971d887-997e-40aa-86b9-dd21a755333d"
  time="2024-09-19T02:06:32Z" level=info msg="git cat-file -t 992165053266c3043b11e6931947a8ae83a147be" dir=/tmp/TestGenerateManifestsHelmWithRefs_CachedNoLsRemote1728810496/001/tmprepo/b971d887-997e-40aa-86b9-dd21a755333d execID=bd248
  time="2024-09-19T02:06:32Z" level=info msg=Trace args="[git cat-file -t 992165053266c3043b11e6931947a8ae83a147be]" dir=/tmp/TestGenerateManifestsHelmWithRefs_CachedNoLsRemote1728810496/001/tmprepo/b971d887-997e-40aa-86b9-dd21a755333d operation_name="exec git" time_ms=2.189946
  time="2024-09-19T02:06:32Z" level=info msg="git fetch origin --tags --force --prune" dir=/tmp/TestGenerateManifestsHelmWithRefs_CachedNoLsRemote1728810496/001/tmprepo/b971d887-997e-40aa-86b9-dd21a755333d execID=8a298
  time="2024-09-19T02:06:32Z" level=info msg=Trace args="[git fetch origin --tags --force --prune]" dir=/tmp/TestGenerateManifestsHelmWithRefs_CachedNoLsRemote1728810496/001/tmprepo/b971d887-997e-40aa-86b9-dd21a755333d operation_name="exec git" time_ms=15.739834000000002
  time="2024-09-19T02:06:32Z" level=info msg="git checkout --force 992165053266c3043b11e6931947a8ae83a147be" dir=/tmp/TestGenerateManifestsHelmWithRefs_CachedNoLsRemote1728810496/001/tmprepo/b971d887-997e-40aa-86b9-dd21a755333d execID=15a2e
  time="2024-09-19T02:06:32Z" level=info msg=Trace args="[git checkout --force 992165053266c3043b11e6931947a8ae83a147be]" dir=/tmp/TestGenerateManifestsHelmWithRefs_CachedNoLsRemote1728810496/001/tmprepo/b971d887-997e-40aa-86b9-dd21a755333d operation_name="exec git" time_ms=3.289363
  time="2024-09-19T02:06:32Z" level=info msg="git clean -ffdx" dir=/tmp/TestGenerateManifestsHelmWithRefs_CachedNoLsRemote1728810496/001/tmprepo/b971d887-997e-40aa-86b9-dd21a755333d execID=7f91a
  time="2024-09-19T02:06:32Z" level=info msg=Trace args="[git clean -ffdx]" dir=/tmp/TestGenerateManifestsHelmWithRefs_CachedNoLsRemote1728810496/001/tmprepo/b971d887-997e-40aa-86b9-dd21a755333d operation_name="exec git" time_ms=1.8856249999999999
  time="2024-09-19T02:06:32Z" level=info msg="manifest cache miss: &ApplicationSource{RepoURL:file:///tmp/TestGenerateManifestsHelmWithRefs_CachedNoLsRemote1728810496/001/tmprepo,Path:.,TargetRevision:HEAD,Helm:&ApplicationSourceHelm{ValueFiles:[$ref/test.yaml],Parameters:[]HelmParameter{},ReleaseName:,Values:,FileParameters:[]HelmFileParameter{},Version:,PassCredentials:false,IgnoreMissingValueFiles:false,SkipCrds:false,ValuesObject:nil,Namespace:,KubeVersion:,APIVersions:[],},Kustomize:nil,Directory:nil,Plugin:nil,Chart:,Ref:,}/992165053266c3043b11e6931947a8ae83a147be"
  time="2024-09-19T02:06:32Z" level=info msg="helm template . --name-template  --values /tmp/TestGenerateManifestsHelmWithRefs_CachedNoLsRemote1728810496/001/tmprepo/b971d887-997e-40aa-86b9-dd21a755333d/test.yaml --include-crds" dir=/tmp/TestGenerateManifestsHelmWithRefs_CachedNoLsRemote1728810496/001/tmprepo/b971d887-997e-40aa-86b9-dd21a755333d execID=0d66e
  time="2024-09-19T02:06:32Z" level=info msg=Trace args="[helm template . --name-template  --values /tmp/TestGenerateManifestsHelmWithRefs_CachedNoLsRemote1728810496/001/tmprepo/b971d887-997e-40aa-86b9-dd21a755333d/test.yaml --include-crds]" dir=/tmp/TestGenerateManifestsHelmWithRefs_CachedNoLsRemote1728810496/001/tmprepo/b971d887-997e-40aa-86b9-dd21a755333d operation_name="exec helm" time_ms=51.7645
      testing.go:1231: TempDir RemoveAll cleanup: unlinkat /tmp/TestGenerateManifestsHelmWithRefs_CachedNoLsRemote1728810496/001/tmprepo/b971d887-997e-40aa-86b9-dd21a755333d/.git: permission denied
andrii-korotkov-verkada commented 2 weeks ago

We can probably customize the backend files more, separating workflows and other meta things into something like tools here https://github.com/argoproj/argo-cd/blob/0f872f51be36a474a27e70e0c9300231f026ffb3/.github/workflows/ci-build.yaml.

andrii-korotkov-verkada commented 2 weeks ago

I'll discuss this at the contributors meeting.