Skip to content

ci: automated update to rustc 1.83.0#1776

Merged
notmandatory merged 6 commits intomasterfrom
create-pull-request/update-rust-version
Dec 17, 2024
Merged

ci: automated update to rustc 1.83.0#1776
notmandatory merged 6 commits intomasterfrom
create-pull-request/update-rust-version

Conversation

@create-pr-actions
Copy link
Copy Markdown

@create-pr-actions create-pr-actions bot commented Dec 15, 2024

Automated update to Github CI workflow cont_integration.yml by create-pull-request GitHub action

I manually fixed new clippy warnings.

I also changed CI to:
1. not build or run tests or test dependencies when building with MSRV. This reduced the number of dependencies we need to pin for MSRV and fixes 1398. I removed these changes.
2. use the same version or rust as in the rust-version file for all jobs instead of just for clippy. I made this change to prevent CI breaks when stable changes before we have a chance to fix the auto created PR that bumps the rust-version file.

@notmandatory notmandatory added this to the 1.0.0-beta milestone Dec 16, 2024
@notmandatory notmandatory self-assigned this Dec 16, 2024
@notmandatory
Copy link
Copy Markdown
Member

notmandatory commented Dec 16, 2024

This doesn't need to go into the final 1.0.0, but if folks have time to review it I'd like to get it in so:

  1. downstream projects using 1.83 don't get the new clippy warnings
    2. CI will build with MSRV without so many pinned dependencies I removed these changes.

@notmandatory notmandatory force-pushed the create-pull-request/update-rust-version branch 2 times, most recently from aa83307 to 74a7f73 Compare December 16, 2024 03:54
Copy link
Copy Markdown
Collaborator

@oleonardolima oleonardolima left a comment

Choose a reason for hiding this comment

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

tACK 74a7f73

proptest = "1.2.0"
bdk_testenv = { path = "../testenv", default-features = false }
criterion = { version = "0.2" }
criterion = { version = "0.5" }
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I'm not aware of the reason it has been downgraded to 0.2 by #1670, but I guess there might be some #:thinking:

Copy link
Copy Markdown
Member

@notmandatory notmandatory Dec 16, 2024

Choose a reason for hiding this comment

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

I manually ran the bench tests with criterion 0.5 and they still build and run so I think it's ok. @ValuedMammal do you know why we were using such an old version?

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

AFAICT on VM's initial PR it was using 0.5 🤔.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

do you know why we were using such an old version?

I think it was only to get CI to pass using MSRV. I guess the issue didn't surface on #1735 because running the benches required a special invocation and so criterion was not automatically linked in with the build deps.

cargo update -p indexmap --precise "2.5.0"
- name: Build
run: cargo build --workspace --exclude 'example_*' ${{ matrix.features }}
run: cargo build --workspace --exclude 'example_*' --exclude 'bdk_testenv' ${{ matrix.features }}
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I'm divided on this one, it surely helps not pinning on CI, but I'm unsure if we should test or not on MSRV toolchain 🤔.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Since we are keeping such an old MSRV and our test deps change so often I think this is the only way to manage it. But I'm open to move this to a different PR for after 1.0 if this is going to need more discussion.

@oleonardolima
Copy link
Copy Markdown
Collaborator

@notmandatory It's probably needed to update the docs nightly toolchain too, see https://github.com/bitcoindevkit/bdk/actions/runs/12360406444/job/34495287138#step:7:307

Copy link
Copy Markdown
Contributor

@nymius nymius left a comment

Choose a reason for hiding this comment

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

I've run the workflows with act tool locally, but the output is not clear.
Though the CI is green, and have reviewed the output there.
If there are better ways to check this, please let me know.

Besides that, I have to research more about best practices on MSRV, as it seems to be another deep rabbit hole. The best material I have found so far is this discussion in the api guidelines repository of rust-lang. The stance adopted there seems to be in favor of pinning dependencies but in an alternative Cargo.lock.min file, which I think is not very different from what what was done here before, and I think is a path we should consider, probably against the original motivation of this PR.
However, I think these changes doesn't go in the opposite direction the link I mentioned above goes, and considering the project is still checking it builds against MSRV, my only concern here is the lack of testing this introduces for MSRV, so I wouldn't remove them unless there are strong reasons to remove the pinning and remove the testing in the way.

@notmandatory
Copy link
Copy Markdown
Member

notmandatory commented Dec 17, 2024

@notmandatory It's probably needed to update the docs nightly toolchain too, see https://github.com/bitcoindevkit/bdk/actions/runs/12360406444/job/34495287138#step:7:307

Good call. I updated the docs job to use rust nightly since the #[doc(cfg(…))] attribute (feature: doc_cfg) still isn't stabilized, see tracking issue: rust-lang/rust#43781.

@notmandatory notmandatory force-pushed the create-pull-request/update-rust-version branch from d4dc092 to b287325 Compare December 17, 2024 02:20
@notmandatory notmandatory force-pushed the create-pull-request/update-rust-version branch from b287325 to 272ce22 Compare December 17, 2024 02:46
@notmandatory
Copy link
Copy Markdown
Member

Besides that, I have to research more about best practices on MSRV, as it seems to be another deep rabbit hole.
...

I removed the commits that changed our MSRV testing and dependencies. I agree this is a rabbit hole that deserves more work to get right.

@notmandatory
Copy link
Copy Markdown
Member

I've run the workflows with act tool locally, but the output is not clear. Though the CI is green, and have reviewed the output there. If there are better ways to check this, please let me know.

I haven't tried the act tool, to test CI stuff I either push the changes in my PR or if it's someone else's PR and I want to try something different I push to my own bdk fork and let the Github CI run there.

This was referenced Dec 17, 2024
Copy link
Copy Markdown
Collaborator

@oleonardolima oleonardolima left a comment

Choose a reason for hiding this comment

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

tACK 272ce22

Copy link
Copy Markdown
Contributor

@nymius nymius left a comment

Choose a reason for hiding this comment

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

tACK 272ce22

Copy link
Copy Markdown
Collaborator

@ValuedMammal ValuedMammal left a comment

Choose a reason for hiding this comment

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

ACK 272ce22

@notmandatory notmandatory mentioned this pull request Dec 19, 2024
40 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

4 participants