prestodb / presto

The official home of the Presto distributed SQL query engine for big data
http://prestodb.io
Apache License 2.0
15.92k stars 5.33k forks source link

ci/circleci: linux-build-and-unit-test fails to clone git repo #22273

Open elharo opened 6 months ago

elharo commented 6 months ago

Creating .ssh directory Adding the following entries to known_hosts: github.com ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQCj7ndNxQowgcQnjshcLrqPEiiphnt+VTTvDP6mHBL9j1aNUkY4Ue1gvwnGLVlOhGeYrnZaMgRK6+PKCUXaDbC7qtbW8gIkhL7aGCsOr/C56SJMy/BCZfxd1nWzAOxSDPgVsmerOBYfNqltV9/hWCqBywINIR+5dIg6JTJ72pcEpEjcYgXkE2YEFXV1JHnsKgbLWNlhScqb2UmyRkQyytRLtL+38TGxkxCflmO+5Z8CSSNY7GidjMIZ7Q4zMjA2n1nGrlTDkzwDCsw+wqFPGQA179cnfGWOWRVruj16z6XyvxvjJwbz0wQZ75XK5tKSb7FNyeIEs4TT4jk+S4dhPeAUC5y+bDYirYgM4GC7uEnztnZyaVWQ7B381AK4Qdrwt51ZqExKbQpTUNn+EjqoTwvqNj4kqx5QUCI0ThS/YkOxJCXmPUWZbhjpCg56i+2aB6CmK2JGhn57K5mj0MNdBXA4/WnwH6XoPWJzK5Nyu2zB3nAZp+S5hpQs+p1vN1/wsjk= github.com ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBEmKSENjQEezOmxkZMy7opKgwFB9nkt5YRrYMjNuG5N87uRgg6CLrbo5wAdT/y6v0mKV0U2w0WZ2YB/++Tpockg= github.com ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOMqqnkVzrm0SdG6UOoqKLsabgH5C9okWi0dh2l9GKJl bitbucket.org ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBPIQmuzMBuKdWeF4+a2sjSSpBK0iqitSQ+5BM9KhpexuGt20JpTVM7u5BDZngncgrqDMbWdxMWWOGtZ9UgbqgZE= bitbucket.org ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIazEu89wgQZ4bqs3d63QSMzYVa0MuJ2e2gKTKqu+UUO bitbucket.org ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDQeJzhupRu0u0cdegZIa8e86EG2qOCsIsD1Xw0xSeiPDlCr7kq97NLmMbpKTX6Esc30NuoqEEHCuc7yWtwp8dI76EEEB1VqY9QJq6vk+aySyboD5QF61I/1WeTwu+deCbgKMGbUijeXhtfbxSxm6JwGrXrhBdofTsbKRUsrN1WoNgUa8uqN1Vx6WAJw1JHPhglEGGHea6QICwJOAr/6mrui/oB7pkaWKHj3z7d1IC4KWLtY47elvjbaTlkN04Kc/5LFEirorGYVbt15kAUlqGM65pk6ZBxtaO3+30LVlORZkxOh+LKL/BvbZ/iRNhItLqNyieoQj/uh/7Iv4uyH/cV/0b4WDSd3DptigWq84lJubb9t/DnZlrJazxyDCulTmKdOR7vs9gMTo+uoIrPSb8ScTtvw65+odKAlBj59dhnVp9zd7QUojOpXlL62Aw56U4oO+FALuevvMjiWeavKhJqlR7i5n9srYcrNV7ttmDw7kf/97P5zauIhxcjX+xHv4M= gitlab.com ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBFSMqzJeV9rUzU4kWitGjeR4PWSa29SPqJ1fVkhtj3Hw9xjLVXVYrU9QlYWrOLXBpQ6KWjbjTDTdDkoohFzgbEY=

Writing SSH key for checkout to "/root/.ssh/id_rsa" Writing SSH public key for checkout to "/root/.ssh/id_rsa.pub" Cloning git repository Cloning into '.'... Warning: Permanently added the ECDSA host key for IP address '140.82.114.3' to the list of known hosts. client_loop: send disconnect: Broken pipe fetch-pack: unexpected disconnect while reading sideband packet fatal: early EOF fatal: fetch-pack: invalid index-pack output error running git clone "git@github.com:prestodb/presto.git": exit status 128

error running git clone "git@github.com:prestodb/presto.git": exit status 128

pratyakshsharma commented 6 months ago

shallow cloning and setting few git configs like disabling compression and increasing buffer size should probably help here.

https://github.com/orgs/community/discussions/48568#discussioncomment-7111245

pratyakshsharma commented 6 months ago

Here are additional links to fix this -

  1. https://medium.com/equify-tech/from-5-minutes-to-5-seconds-customize-your-checkout-step-in-circleci-2-0-244d7b226d7d
  2. https://support.circleci.com/hc/en-us/articles/115015659247-How-do-I-modify-the-checkout-step#:~:text=If%20you%20need%20to%20change,process%20to%20suit%20your%20needs.&text=Please%20remember%20to%20remove%20the,step%20to%20process%20the%20checkout.
pratyakshsharma commented 6 months ago

cc @wanglinsong

wanglinsong commented 6 months ago

@elharo can you provide your git env? macOS or Windows? git version, etc.

elharo commented 6 months ago

This is on the CI. Off the top of my head I don't recall if this was github actions or CircleCI.

elharo commented 6 months ago

Yes, it was circleci. Not sure how that picks git versions etc. but the config is here: https://github.com/prestodb/presto/blob/master/.circleci/config.yml

wanglinsong commented 5 months ago

@tdcmeehan can you have somebody with circleci acces to take a look?

tdcmeehan commented 5 months ago

@wanglinsong @pratyakshsharma anyone can edit the config.yml referenced above.

pratyakshsharma commented 5 months ago

@tdcmeehan to solve the above issue, we do not need to make changes to config.yml, since it is using checkout helper function of circleci. Checkout will clone the entire repo with all the commit history by default, however for our usecase we can make use of shallow cloning as we only build the project and run tests. So we actually need to customize this checkout step as per my exploration. Here is a link that might help - https://medium.com/equify-tech/from-5-minutes-to-5-seconds-customize-your-checkout-step-in-circleci-2-0-244d7b226d7d, but it needs circleci admin access. So we need someone with this access to try out the fix.

tdcmeehan commented 5 months ago

I don't think I have admin access. @mshang816 do you know, or do you know who could help?