Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(ci): fix breaking tests #8413

Merged
merged 7 commits into from
Nov 4, 2022
Merged

chore(ci): fix breaking tests #8413

merged 7 commits into from
Nov 4, 2022

Conversation

joshua-goldstein
Copy link
Contributor

Problem

Since we added arm64 runners, they are being picked up by our workflows. Tests are failing after about 1 minute with exec format error (due to documented Badger/Ristretto issue).

For more info on runner labels see here.

Solution

We modify workflows to only pickup amd runners. We also pin the Go version.

@github-actions github-actions bot added the area/integrations Related to integrations with other projects. label Nov 4, 2022
@joshua-goldstein joshua-goldstein marked this pull request as ready for review November 4, 2022 07:29
@joshua-goldstein
Copy link
Contributor Author

@skrdgraph This should fix the issue of failing workflows.

@joshua-goldstein joshua-goldstein added arm64 and removed area/integrations Related to integrations with other projects. labels Nov 4, 2022
@coveralls
Copy link

coveralls commented Nov 4, 2022

Coverage Status

Coverage increased (+0.004%) to 37.184% when pulling e4b79a0 on joshua/breaking-tests into c04ce80 on main.

@@ -1,4 +1,4 @@
name: ci-dgraph-load-tests
name: ci-dgraph-load-tests-amd64
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@joshua-goldstein - can we remove this line change?

I had mentioned this to @adityasadalage, and indicated to specify the x64, and not change the name.

We will lose history when we make a name change. Also, the future plan is to use matrix and bring in all the runner types into this workflow.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@skrdgraph yeah I wasn't sure on this point - I just reverted the change

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah ci-dgraph-tests-arm64.yml pipeline was given the new name. Would that need to be reverted to accommodate the matrix change later on?

run: |
#!/bin/bash
GOVERSION=$({ [ -f .go-version ] && cat .go-version; })
echo "GOVERSION=$GOVERSION" >> $GITHUB_ENV
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1 ^ thanks for adding this, could you also do this for go-lint?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@skrdgraph Sure, previously the linter yaml was skipping the Go installation step entirely with skip-go-installation: true . I just pushed changes that model the linter after the Badger linter setup (hence the version bumps). Let me know if that looks okay.

- name: golang-lint
env:
# prevent OOM
GOGC: 10
uses: golangci/golangci-lint-action@v2
uses: golangci/golangci-lint-action@v3.2.0
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should we just do @latest here?

Copy link
Contributor Author

@joshua-goldstein joshua-goldstein Nov 4, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Latest or perhaps @ v3 ? That way a major version upgrade wouldn't break the CI

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if it does break, we would know something changed in the action side. Times when this would break is when the underlying schema would change things the way this action is invoked or some new fields coming in.

Irrespective it's good to do latest here as well IMO

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense! I pinned it to @ latest

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interesting, @ latest is not possible (see the failed run here). But @ v3 works and will pull the latest minor versions

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you can probably just do golangci/golangci-lint-action without a version, this is still a guess

with:
# Required: the version of golangci-lint is required and must be specified without patch version: we always use the latest patch version.
version: v1.36
version: v1.48
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

also should we just do latest here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

latest can work here - currently latest is v1.50.1 so not a big bump

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's easier if we pin to latest. We shouldn't be doing latest pins on core code though.

The other thing is there may be some go version <> go-lang-ci version compatibility issues.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also pinned to latest. 👍

@skrdgraph skrdgraph self-requested a review November 4, 2022 23:16
Copy link
Contributor

@skrdgraph skrdgraph left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@skrdgraph skrdgraph merged commit 5f5994a into main Nov 4, 2022
@skrdgraph skrdgraph deleted the joshua/breaking-tests branch November 4, 2022 23:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

Successfully merging this pull request may close these issues.

4 participants