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

ci: move a chunk of the Rust CI over to GHA #9290

Merged
merged 7 commits into from
Oct 7, 2023
Merged

Conversation

nagisa
Copy link
Collaborator

@nagisa nagisa commented Jul 12, 2023

GHA has many significant benefits compared to buildkite, most major of it is that blindly using GHA is not going to by default allow untrusted contributors to run arbitrary code – instead GitHub will present reviewers a button they can click after reviewing the PR.

It also makes maintenance of the CI infrastructure somewhat easier, which given our soon-to-be-stretched-very-thin infrastructure team is a huge benefit.

In process of implementing this PR I ended up simplifying a lot of the Rust testing as well. In particular instead of running half a dozen of different combinations on just Linux, we now run just the nightly vs non-nightly versions. This saves CPU time on many different rebuilds… Of note, one feature that no longer gets tested is mock_node, as it was causing a failure in one of the integration tests. If we wanted to re-enable this particular test, we should figure out how to fix the test, rather than adding a new test configuration.

As a final benefit, I’ve also added a m1 macOS-based job. This should help with making sure that people who develop on company-issued laptops can actually be productive, rather than have to tip-toe around a boatload of failing tests. We will have an ability to decide whether we want to block PRs landing on this job in the repository configuration at any point in the future.

See also #9608

@nagisa
Copy link
Collaborator Author

nagisa commented Jul 12, 2023

I guess the check for allowing changes to pipeline.yml work a little too well :D

test-utils/style/src/lib.rs Outdated Show resolved Hide resolved
@nagisa nagisa force-pushed the nagisa/cargo-tests-style branch 9 times, most recently from 315191a to 4b56709 Compare September 21, 2023 08:04
@nagisa nagisa force-pushed the nagisa/cargo-tests-style branch 3 times, most recently from e17417d to b2f700e Compare September 27, 2023 08:35
github-merge-queue bot pushed a commit that referenced this pull request Oct 2, 2023
…t` (#9608)

I got absolutely fed up with waiting for prerequisite infrastructure
work for #9290 (why does it have to be _that_ hard?)

However the PR in question had some other important improvements that do
not necessarily *rely* on changes to said infrastructure to work. In
particular:

* `nextest` now retries failing tests a few times before giving up, to
make sure they aren't spuriously failing;
* This should help some timing out integration tests in particular, as
those often fail because of some deadlockish situation in my experience.
* style checks still run with `cargo nextest` – unfortunately that means
that in CI this will run these checks multiple times, but that doesn’t
sound particularly terrible of a tradeoff (especially if the other
changes mean we won't be retrying entire test suites as often anymore;)
* This should allow for a greater portion of the test suite to run on
Macs – unfortunately not verified by the CI, but people do complain and
this should make the situation better.

cc #9367
@nagisa nagisa force-pushed the nagisa/cargo-tests-style branch 2 times, most recently from 48da3c7 to 43fe737 Compare October 2, 2023 10:38
@@ -1,8 +1,5 @@
[profile.default]
slow-timeout = { period = "60s", terminate-after = 2, grace-period = "0s" }
# FIXME(nagisa): use --profile ci in CI instead when we manage to modify CI scripts...
retries = { backoff = "fixed", count = 3, delay = "1s" }
failure-output = "final"
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

This change may be contentious. On one hand keeping this in makes flaky tests less of a major PiTA during local development. On the other we might end up living with the flaky tests in perpetuity if we keep this as nobody would have any motivation to actually look into these flakies…

Copy link
Contributor

Choose a reason for hiding this comment

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

+1 to removing retries

nikurt pushed a commit that referenced this pull request Oct 2, 2023
…t` (#9608)

I got absolutely fed up with waiting for prerequisite infrastructure
work for #9290 (why does it have to be _that_ hard?)

However the PR in question had some other important improvements that do
not necessarily *rely* on changes to said infrastructure to work. In
particular:

* `nextest` now retries failing tests a few times before giving up, to
make sure they aren't spuriously failing;
* This should help some timing out integration tests in particular, as
those often fail because of some deadlockish situation in my experience.
* style checks still run with `cargo nextest` – unfortunately that means
that in CI this will run these checks multiple times, but that doesn’t
sound particularly terrible of a tradeoff (especially if the other
changes mean we won't be retrying entire test suites as often anymore;)
* This should allow for a greater portion of the test suite to run on
Macs – unfortunately not verified by the CI, but people do complain and
this should make the situation better.

cc #9367
@nagisa nagisa force-pushed the nagisa/cargo-tests-style branch 3 times, most recently from c55bb2c to 8670d05 Compare October 2, 2023 16:46
@nagisa nagisa force-pushed the nagisa/cargo-tests-style branch from b595d7d to ae5eb0c Compare October 5, 2023 10:57
This is much better than denying warnings during build as even with warnings
present we can see the rest of the test suite failures at the same time.
@nagisa nagisa force-pushed the nagisa/cargo-tests-style branch from 1a17509 to 3a74f0c Compare October 5, 2023 11:35
@nagisa nagisa changed the title ci: move Rust style checks to rust tests ci: move a chunk of the Rust CI over to GHA Oct 5, 2023
@nagisa nagisa added this pull request to the merge queue Oct 7, 2023
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Oct 7, 2023
@nagisa nagisa added this pull request to the merge queue Oct 7, 2023
@nagisa nagisa removed this pull request from the merge queue due to a manual request Oct 7, 2023
@nagisa nagisa enabled auto-merge October 7, 2023 09:06
@nagisa nagisa added this pull request to the merge queue Oct 7, 2023
Merged via the queue into master with commit 7dc48f7 Oct 7, 2023
@nagisa nagisa deleted the nagisa/cargo-tests-style branch October 7, 2023 10:00
nikurt pushed a commit that referenced this pull request Oct 10, 2023
GHA has many significant benefits compared to buildkite, most major of
it is that blindly using GHA is not going to by default allow untrusted
contributors to run arbitrary code – instead GitHub will present
reviewers a button they can click after reviewing the PR.

It also makes maintenance of the CI infrastructure somewhat easier,
which given our soon-to-be-stretched-very-thin infrastructure team is a
huge benefit.

In process of implementing this PR I ended up simplifying a lot of the
Rust testing as well. In particular instead of running half a dozen of
different combinations on just Linux, we now run just the nightly vs
non-nightly versions. This saves CPU time on many different rebuilds… Of
note, one feature that no longer gets tested is `mock_node`, as it was
causing a failure in one of the integration tests. If we wanted to
re-enable this particular test, we should figure out how to fix the
test, rather than adding a new test configuration.

As a final benefit, I’ve also added a m1 macOS-based job. This should
help with making sure that people who develop on company-issued laptops
can actually be productive, rather than have to tip-toe around a
boatload of failing tests. We will have an ability to decide whether we
want to block PRs landing on this job in the repository configuration at
any point in the future.
nikurt pushed a commit that referenced this pull request Oct 11, 2023
…t` (#9608)

I got absolutely fed up with waiting for prerequisite infrastructure
work for #9290 (why does it have to be _that_ hard?)

However the PR in question had some other important improvements that do
not necessarily *rely* on changes to said infrastructure to work. In
particular:

* `nextest` now retries failing tests a few times before giving up, to
make sure they aren't spuriously failing;
* This should help some timing out integration tests in particular, as
those often fail because of some deadlockish situation in my experience.
* style checks still run with `cargo nextest` – unfortunately that means
that in CI this will run these checks multiple times, but that doesn’t
sound particularly terrible of a tradeoff (especially if the other
changes mean we won't be retrying entire test suites as often anymore;)
* This should allow for a greater portion of the test suite to run on
Macs – unfortunately not verified by the CI, but people do complain and
this should make the situation better.

cc #9367
nikurt pushed a commit that referenced this pull request Oct 11, 2023
GHA has many significant benefits compared to buildkite, most major of
it is that blindly using GHA is not going to by default allow untrusted
contributors to run arbitrary code – instead GitHub will present
reviewers a button they can click after reviewing the PR.

It also makes maintenance of the CI infrastructure somewhat easier,
which given our soon-to-be-stretched-very-thin infrastructure team is a
huge benefit.

In process of implementing this PR I ended up simplifying a lot of the
Rust testing as well. In particular instead of running half a dozen of
different combinations on just Linux, we now run just the nightly vs
non-nightly versions. This saves CPU time on many different rebuilds… Of
note, one feature that no longer gets tested is `mock_node`, as it was
causing a failure in one of the integration tests. If we wanted to
re-enable this particular test, we should figure out how to fix the
test, rather than adding a new test configuration.

As a final benefit, I’ve also added a m1 macOS-based job. This should
help with making sure that people who develop on company-issued laptops
can actually be productive, rather than have to tip-toe around a
boatload of failing tests. We will have an ability to decide whether we
want to block PRs landing on this job in the repository configuration at
any point in the future.
nikurt pushed a commit that referenced this pull request Oct 11, 2023
GHA has many significant benefits compared to buildkite, most major of
it is that blindly using GHA is not going to by default allow untrusted
contributors to run arbitrary code – instead GitHub will present
reviewers a button they can click after reviewing the PR.

It also makes maintenance of the CI infrastructure somewhat easier,
which given our soon-to-be-stretched-very-thin infrastructure team is a
huge benefit.

In process of implementing this PR I ended up simplifying a lot of the
Rust testing as well. In particular instead of running half a dozen of
different combinations on just Linux, we now run just the nightly vs
non-nightly versions. This saves CPU time on many different rebuilds… Of
note, one feature that no longer gets tested is `mock_node`, as it was
causing a failure in one of the integration tests. If we wanted to
re-enable this particular test, we should figure out how to fix the
test, rather than adding a new test configuration.

As a final benefit, I’ve also added a m1 macOS-based job. This should
help with making sure that people who develop on company-issued laptops
can actually be productive, rather than have to tip-toe around a
boatload of failing tests. We will have an ability to decide whether we
want to block PRs landing on this job in the repository configuration at
any point in the future.
Comment on lines -67 to -71
cargo install cargo-deny
cargo run -p themis --release
if [ -e deny.toml ]; then
cargo-deny --all-features check bans
fi
Copy link
Collaborator

Choose a reason for hiding this comment

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

@nagisa Was it intentional to decommission cargo-deny and themis sanity checks?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

They’re still being run as part of cargo nextest here as implemented in #9608.

nikurt pushed a commit that referenced this pull request Oct 16, 2023
GHA has many significant benefits compared to buildkite, most major of
it is that blindly using GHA is not going to by default allow untrusted
contributors to run arbitrary code – instead GitHub will present
reviewers a button they can click after reviewing the PR.

It also makes maintenance of the CI infrastructure somewhat easier,
which given our soon-to-be-stretched-very-thin infrastructure team is a
huge benefit.

In process of implementing this PR I ended up simplifying a lot of the
Rust testing as well. In particular instead of running half a dozen of
different combinations on just Linux, we now run just the nightly vs
non-nightly versions. This saves CPU time on many different rebuilds… Of
note, one feature that no longer gets tested is `mock_node`, as it was
causing a failure in one of the integration tests. If we wanted to
re-enable this particular test, we should figure out how to fix the
test, rather than adding a new test configuration.

As a final benefit, I’ve also added a m1 macOS-based job. This should
help with making sure that people who develop on company-issued laptops
can actually be productive, rather than have to tip-toe around a
boatload of failing tests. We will have an ability to decide whether we
want to block PRs landing on this job in the repository configuration at
any point in the future.
nikurt pushed a commit that referenced this pull request Oct 18, 2023
GHA has many significant benefits compared to buildkite, most major of
it is that blindly using GHA is not going to by default allow untrusted
contributors to run arbitrary code – instead GitHub will present
reviewers a button they can click after reviewing the PR.

It also makes maintenance of the CI infrastructure somewhat easier,
which given our soon-to-be-stretched-very-thin infrastructure team is a
huge benefit.

In process of implementing this PR I ended up simplifying a lot of the
Rust testing as well. In particular instead of running half a dozen of
different combinations on just Linux, we now run just the nightly vs
non-nightly versions. This saves CPU time on many different rebuilds… Of
note, one feature that no longer gets tested is `mock_node`, as it was
causing a failure in one of the integration tests. If we wanted to
re-enable this particular test, we should figure out how to fix the
test, rather than adding a new test configuration.

As a final benefit, I’ve also added a m1 macOS-based job. This should
help with making sure that people who develop on company-issued laptops
can actually be productive, rather than have to tip-toe around a
boatload of failing tests. We will have an ability to decide whether we
want to block PRs landing on this job in the repository configuration at
any point in the future.
nikurt pushed a commit that referenced this pull request Oct 19, 2023
GHA has many significant benefits compared to buildkite, most major of
it is that blindly using GHA is not going to by default allow untrusted
contributors to run arbitrary code – instead GitHub will present
reviewers a button they can click after reviewing the PR.

It also makes maintenance of the CI infrastructure somewhat easier,
which given our soon-to-be-stretched-very-thin infrastructure team is a
huge benefit.

In process of implementing this PR I ended up simplifying a lot of the
Rust testing as well. In particular instead of running half a dozen of
different combinations on just Linux, we now run just the nightly vs
non-nightly versions. This saves CPU time on many different rebuilds… Of
note, one feature that no longer gets tested is `mock_node`, as it was
causing a failure in one of the integration tests. If we wanted to
re-enable this particular test, we should figure out how to fix the
test, rather than adding a new test configuration.

As a final benefit, I’ve also added a m1 macOS-based job. This should
help with making sure that people who develop on company-issued laptops
can actually be productive, rather than have to tip-toe around a
boatload of failing tests. We will have an ability to decide whether we
want to block PRs landing on this job in the repository configuration at
any point in the future.
nikurt pushed a commit that referenced this pull request Oct 19, 2023
GHA has many significant benefits compared to buildkite, most major of
it is that blindly using GHA is not going to by default allow untrusted
contributors to run arbitrary code – instead GitHub will present
reviewers a button they can click after reviewing the PR.

It also makes maintenance of the CI infrastructure somewhat easier,
which given our soon-to-be-stretched-very-thin infrastructure team is a
huge benefit.

In process of implementing this PR I ended up simplifying a lot of the
Rust testing as well. In particular instead of running half a dozen of
different combinations on just Linux, we now run just the nightly vs
non-nightly versions. This saves CPU time on many different rebuilds… Of
note, one feature that no longer gets tested is `mock_node`, as it was
causing a failure in one of the integration tests. If we wanted to
re-enable this particular test, we should figure out how to fix the
test, rather than adding a new test configuration.

As a final benefit, I’ve also added a m1 macOS-based job. This should
help with making sure that people who develop on company-issued laptops
can actually be productive, rather than have to tip-toe around a
boatload of failing tests. We will have an ability to decide whether we
want to block PRs landing on this job in the repository configuration at
any point in the future.
nikurt pushed a commit that referenced this pull request Oct 19, 2023
GHA has many significant benefits compared to buildkite, most major of
it is that blindly using GHA is not going to by default allow untrusted
contributors to run arbitrary code – instead GitHub will present
reviewers a button they can click after reviewing the PR.

It also makes maintenance of the CI infrastructure somewhat easier,
which given our soon-to-be-stretched-very-thin infrastructure team is a
huge benefit.

In process of implementing this PR I ended up simplifying a lot of the
Rust testing as well. In particular instead of running half a dozen of
different combinations on just Linux, we now run just the nightly vs
non-nightly versions. This saves CPU time on many different rebuilds… Of
note, one feature that no longer gets tested is `mock_node`, as it was
causing a failure in one of the integration tests. If we wanted to
re-enable this particular test, we should figure out how to fix the
test, rather than adding a new test configuration.

As a final benefit, I’ve also added a m1 macOS-based job. This should
help with making sure that people who develop on company-issued laptops
can actually be productive, rather than have to tip-toe around a
boatload of failing tests. We will have an ability to decide whether we
want to block PRs landing on this job in the repository configuration at
any point in the future.
nikurt pushed a commit that referenced this pull request Oct 19, 2023
GHA has many significant benefits compared to buildkite, most major of
it is that blindly using GHA is not going to by default allow untrusted
contributors to run arbitrary code – instead GitHub will present
reviewers a button they can click after reviewing the PR.

It also makes maintenance of the CI infrastructure somewhat easier,
which given our soon-to-be-stretched-very-thin infrastructure team is a
huge benefit.

In process of implementing this PR I ended up simplifying a lot of the
Rust testing as well. In particular instead of running half a dozen of
different combinations on just Linux, we now run just the nightly vs
non-nightly versions. This saves CPU time on many different rebuilds… Of
note, one feature that no longer gets tested is `mock_node`, as it was
causing a failure in one of the integration tests. If we wanted to
re-enable this particular test, we should figure out how to fix the
test, rather than adding a new test configuration.

As a final benefit, I’ve also added a m1 macOS-based job. This should
help with making sure that people who develop on company-issued laptops
can actually be productive, rather than have to tip-toe around a
boatload of failing tests. We will have an ability to decide whether we
want to block PRs landing on this job in the repository configuration at
any point in the future.
nikurt pushed a commit that referenced this pull request Oct 23, 2023
GHA has many significant benefits compared to buildkite, most major of
it is that blindly using GHA is not going to by default allow untrusted
contributors to run arbitrary code – instead GitHub will present
reviewers a button they can click after reviewing the PR.

It also makes maintenance of the CI infrastructure somewhat easier,
which given our soon-to-be-stretched-very-thin infrastructure team is a
huge benefit.

In process of implementing this PR I ended up simplifying a lot of the
Rust testing as well. In particular instead of running half a dozen of
different combinations on just Linux, we now run just the nightly vs
non-nightly versions. This saves CPU time on many different rebuilds… Of
note, one feature that no longer gets tested is `mock_node`, as it was
causing a failure in one of the integration tests. If we wanted to
re-enable this particular test, we should figure out how to fix the
test, rather than adding a new test configuration.

As a final benefit, I’ve also added a m1 macOS-based job. This should
help with making sure that people who develop on company-issued laptops
can actually be productive, rather than have to tip-toe around a
boatload of failing tests. We will have an ability to decide whether we
want to block PRs landing on this job in the repository configuration at
any point in the future.
nikurt pushed a commit that referenced this pull request Oct 23, 2023
GHA has many significant benefits compared to buildkite, most major of
it is that blindly using GHA is not going to by default allow untrusted
contributors to run arbitrary code – instead GitHub will present
reviewers a button they can click after reviewing the PR.

It also makes maintenance of the CI infrastructure somewhat easier,
which given our soon-to-be-stretched-very-thin infrastructure team is a
huge benefit.

In process of implementing this PR I ended up simplifying a lot of the
Rust testing as well. In particular instead of running half a dozen of
different combinations on just Linux, we now run just the nightly vs
non-nightly versions. This saves CPU time on many different rebuilds… Of
note, one feature that no longer gets tested is `mock_node`, as it was
causing a failure in one of the integration tests. If we wanted to
re-enable this particular test, we should figure out how to fix the
test, rather than adding a new test configuration.

As a final benefit, I’ve also added a m1 macOS-based job. This should
help with making sure that people who develop on company-issued laptops
can actually be productive, rather than have to tip-toe around a
boatload of failing tests. We will have an ability to decide whether we
want to block PRs landing on this job in the repository configuration at
any point in the future.
nikurt pushed a commit that referenced this pull request Oct 24, 2023
GHA has many significant benefits compared to buildkite, most major of
it is that blindly using GHA is not going to by default allow untrusted
contributors to run arbitrary code – instead GitHub will present
reviewers a button they can click after reviewing the PR.

It also makes maintenance of the CI infrastructure somewhat easier,
which given our soon-to-be-stretched-very-thin infrastructure team is a
huge benefit.

In process of implementing this PR I ended up simplifying a lot of the
Rust testing as well. In particular instead of running half a dozen of
different combinations on just Linux, we now run just the nightly vs
non-nightly versions. This saves CPU time on many different rebuilds… Of
note, one feature that no longer gets tested is `mock_node`, as it was
causing a failure in one of the integration tests. If we wanted to
re-enable this particular test, we should figure out how to fix the
test, rather than adding a new test configuration.

As a final benefit, I’ve also added a m1 macOS-based job. This should
help with making sure that people who develop on company-issued laptops
can actually be productive, rather than have to tip-toe around a
boatload of failing tests. We will have an ability to decide whether we
want to block PRs landing on this job in the repository configuration at
any point in the future.
nikurt pushed a commit that referenced this pull request Oct 24, 2023
GHA has many significant benefits compared to buildkite, most major of
it is that blindly using GHA is not going to by default allow untrusted
contributors to run arbitrary code – instead GitHub will present
reviewers a button they can click after reviewing the PR.

It also makes maintenance of the CI infrastructure somewhat easier,
which given our soon-to-be-stretched-very-thin infrastructure team is a
huge benefit.

In process of implementing this PR I ended up simplifying a lot of the
Rust testing as well. In particular instead of running half a dozen of
different combinations on just Linux, we now run just the nightly vs
non-nightly versions. This saves CPU time on many different rebuilds… Of
note, one feature that no longer gets tested is `mock_node`, as it was
causing a failure in one of the integration tests. If we wanted to
re-enable this particular test, we should figure out how to fix the
test, rather than adding a new test configuration.

As a final benefit, I’ve also added a m1 macOS-based job. This should
help with making sure that people who develop on company-issued laptops
can actually be productive, rather than have to tip-toe around a
boatload of failing tests. We will have an ability to decide whether we
want to block PRs landing on this job in the repository configuration at
any point in the future.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants