gitpod icon indicating copy to clipboard operation
gitpod copied to clipboard

[content-service] Remove git no-single-branch flag

Open aledbf opened this issue 2 years ago • 19 comments

Description

The flag --no-single-branch was introduced in https://github.com/gitpod-io/gitpod/pull/6464 in an attempt to use --filter=blob:none (which didn't make it). By checking all the existing branches, even if we use --depth=1

xref: https://github.com/gitpod-io/gitpod/issues/12682

How to test

  • Open a workspace
  • Trigger a prebuild and open the workspace
  • No git errors should be present}
  • Trigger a prebuild and check there are no issues

Release Notes

Do not check all existing git branches during the initial checkout

Werft options:

  • [x] /werft with-preview
  • [x] /werft with-integration-tests=workspace Valid options are all, workspace, webapp, ide

/hold

aledbf avatar Sep 16 '22 23:09 aledbf

started the job as gitpod-build-aledbf-git-nsb.0 because the annotations in the pull request description changed (with .werft/ from main)

If it's not the default branch, manually trigger prebuild failed.

image

Prebuild failed for system reasons. Please contact support. cannot initialize workspace: cannot initialize workspace: git initializer clone: git checkout -B prebuild-without-pvc origin/prebuild-without-pvc failed (exit status 128): fatal: 'origin/prebuild-without-pvc' is not a commit and a branch 'prebuild-wit ...

jenting avatar Sep 18 '22 23:09 jenting

/werft run

:+1: started the job as gitpod-build-aledbf-git-nsb.5 (with .werft/ from main)

aledbf avatar Sep 19 '22 14:09 aledbf

@jenting please check again

aledbf avatar Sep 19 '22 16:09 aledbf

/hold lets merge this after the new cluster has been deployed :pray:

sagor999 avatar Sep 19 '22 18:09 sagor999

started the job as gitpod-build-aledbf-git-nsb.12 because the annotations in the pull request description changed (with .werft/ from main)

started the job as gitpod-build-aledbf-git-nsb.13 because the annotations in the pull request description changed (with .werft/ from main)

started the job as gitpod-build-aledbf-git-nsb.14 because the annotations in the pull request description changed (with .werft/ from main)

FYI, for integration tests to run, you may need to rebase with main.

I am guessing you need https://github.com/gitpod-io/gitpod/commit/c524a001d4da47613b6b013a9e2bef9e8abb3881

The error is:

[Run integration tests] [test-ws-manager|FAIL] 1
[Run integration tests] [test-workspace] running integration for workspace - log file at /tmp/tmp.q8ghJqttKy/workspace.log
[Run integration tests] [test-workspace] go: conflicting replacements for github.com/seccomp/libseccomp-golang:
[Run integration tests] [test-workspace] 	github.com/gitpod-io/[email protected]
[Run integration tests] [test-workspace] 	github.com/gitpod-io/[email protected]
[Run integration tests] [test-workspace] use "go work edit -replace github.com/seccomp/libseccomp-golang=[override]" to resolve

kylos101 avatar Sep 19 '22 20:09 kylos101

FYI, for integration tests to run, you may need to rebase with main.

done

aledbf avatar Sep 19 '22 20:09 aledbf

started the job as gitpod-build-aledbf-git-nsb.16 because the annotations in the pull request description changed (with .werft/ from main)

test-workspace integration test was failing, but, that was in a prior run when we ran all tests.

I changed the description for this PR, so that we just run workspace tests, being run in: https://werft.gitpod-dev.com/job/gitpod-build-aledbf-git-nsb.16

@utam0k are the test-workspace tests still flakey? I ask because a prior run for this branch appeared to timeout. :thinking:

kylos101 avatar Sep 20 '22 20:09 kylos101

also once all conversations are resolved, feel free to remove the hold. (not removing it myself as it will auto merge)

sagor999 avatar Sep 20 '22 20:09 sagor999

@utam0k can you help analyze this failure?

It failed with this message, but I'm not sure where to look (expand does not have more info):

[Run integration tests] [test-workspace] FAIL
[Run integration tests] [test-workspace] FAIL	github.com/gitpod-io/gitpod/test/tests/workspace	2191.554s
[Run integration tests] [test-workspace] FAIL
[Run integration tests] /workspace
[Run integration tests] [test-workspace|FAIL] 1
[Run integration tests] 
[Run integration tests] Failed. Expand to see why
[Run integration tests|FAIL]

kylos101 avatar Sep 21 '22 01:09 kylos101

@kylos101 Sure.

utam0k avatar Sep 21 '22 01:09 utam0k

I think this PR brought the broken integration tests.

@utam0k are the test-workspace tests still flakey? I ask because a prior run for this branch appeared to timeout. thinking

The test to launch gitpod from the git tag pointed to HEAD until now. This seems to have changed and now points to a hash value.

contexts_test.go:200: expected branch 'HEAD', got 'a89cab1135a2d05901ca3021d1608f24a0400932'!

I honestly don't think this change will cause any problems for users, so I think we should just fix the test. However, you should write to Changelog. https://github.com/gitpod-io/gitpod/blob/f61eacf1e8e5e0a0efb7353fe29ad57f25a93820/test/tests/workspace/contexts_test.go#L51-L54

utam0k avatar Sep 21 '22 02:09 utam0k

@utam0k can you help analyze this failure?

It failed with this message, but I'm not sure where to look (expand does not have more info):

[Run integration tests] [test-workspace] FAIL
[Run integration tests] [test-workspace] FAIL	github.com/gitpod-io/gitpod/test/tests/workspace	2191.554s
[Run integration tests] [test-workspace] FAIL
[Run integration tests] /workspace
[Run integration tests] [test-workspace|FAIL] 1
[Run integration tests] 
[Run integration tests] Failed. Expand to see why
[Run integration tests|FAIL]

TIPS: Please search FAIL: via your browser and you can see specific failed tests.

utam0k avatar Sep 21 '22 02:09 utam0k

Thanks for the heads up @utam0k !

@aledbf can you update the test @utam0k shared is failing?

kylos101 avatar Sep 21 '22 12:09 kylos101

@aledbf can you update the https://github.com/gitpod-io/gitpod/pull/13053#issuecomment-1253118277 @utam0k shared is failing?

done

aledbf avatar Sep 21 '22 21:09 aledbf

Hmm, I am seeing a different test failures, but, am skeptical it is related to this PR.

@jenting are you aware of the below test being flakey?

[Run integration tests] [test-ws-manager] --- FAIL: TestOpenWorkspaceFromPrebuild (546.19s)
[Run integration tests] [test-ws-manager]     --- FAIL: TestOpenWorkspaceFromPrebuild/prebuild (546.19s)
[Run integration tests] [test-ws-manager]         --- FAIL: TestOpenWorkspaceFromPrebuild/prebuild/it_should_open_workspace_from_prebuild_successfully (546.19s)
[Run integration tests] [test-ws-manager]             --- FAIL: TestOpenWorkspaceFromPrebuild/prebuild/it_should_open_workspace_from_prebuild_successfully/classic (216.68s)
[Run integration tests] [test-ws-manager]             --- PASS: TestOpenWorkspaceFromPrebuild/prebuild/it_should_open_workspace_from_prebuild_successfully/pvc (329.51s)

kylos101 avatar Sep 21 '22 23:09 kylos101

Hmm, I am seeing a different test failures, but, am skeptical it is related to this PR.

@jenting are you aware of the below test being flakey?


[Run integration tests] [test-ws-manager] --- FAIL: TestOpenWorkspaceFromPrebuild (546.19s)

[Run integration tests] [test-ws-manager]     --- FAIL: TestOpenWorkspaceFromPrebuild/prebuild (546.19s)

[Run integration tests] [test-ws-manager]         --- FAIL: TestOpenWorkspaceFromPrebuild/prebuild/it_should_open_workspace_from_prebuild_successfully (546.19s)

[Run integration tests] [test-ws-manager]             --- FAIL: TestOpenWorkspaceFromPrebuild/prebuild/it_should_open_workspace_from_prebuild_successfully/classic (216.68s)

[Run integration tests] [test-ws-manager]             --- PASS: TestOpenWorkspaceFromPrebuild/prebuild/it_should_open_workspace_from_prebuild_successfully/pvc (329.51s)

Ya, I am working on fixing this flaky test in this PR #13170

jenting avatar Sep 22 '22 00:09 jenting

/unhold

:steam_locomotive: choo, choo!

kylos101 avatar Sep 22 '22 00:09 kylos101

started the job as gitpod-build-aledbf-git-nsb.18 because the annotations in the pull request description changed (with .werft/ from main)

started the job as gitpod-build-aledbf-git-nsb.19 because the annotations in the pull request description changed (with .werft/ from main)

@aledbf FYI replace the one-line release notes with a key highlight here

atduarte avatar Sep 29 '22 14:09 atduarte