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

build(deps): update thiserror requirement from 1.0.30 to 2.0.0 #346

Closed
wants to merge 1 commit into from

Conversation

dependabot[bot]
Copy link

@dependabot dependabot bot commented on behalf of github Nov 6, 2024

Updates the requirements on thiserror to permit the latest version.

Release notes

Sourced from thiserror's releases.

2.0.0

Breaking changes

  • Referencing keyword-named fields by a raw identifier like {r#type} inside a format string is no longer accepted; simply use the unraw name like {type} (#347)

    This aligns thiserror with the standard library's formatting macros, which gained support for implicit argument capture later than the release of this feature in thiserror 1.x.

    #[derive(Error, Debug)]
    #[error("... {type} ...")]  // Before: {r#type}
    pub struct Error {
        pub r#type: Type,
    }
  • Trait bounds are no longer inferred on fields whose value is shadowed by an explicit named argument in a format message (#345)

    // Before: impl<T: Octal> Display for Error<T>
    // After: impl<T> Display for Error<T>
    #[derive(Error, Debug)]
    #[error("{thing:o}", thing = "...")]
    pub struct Error<T> {
        thing: T,
    }
  • Tuple structs and tuple variants can no longer use numerical {0} {1} access at the same time as supplying extra positional arguments for a format message, as this makes it ambiguous whether the number refers to a tuple field vs a different positional arg (#354)

    #[derive(Error, Debug)]
    #[error("ambiguous: {0} {}", $N)]
    //                  ^^^ Not allowed, use #[error("... {0} {n}", n = $N)]
    pub struct TupleError(i32);
  • Code containing invocations of thiserror's derive(Error) must now have a direct dependency on the thiserror crate regardless of the error data structure's contents (#368, #369, #370, #372)

Features

  • Support disabling thiserror's standard library dependency by disabling the default "std" Cargo feature: thiserror = { version = "2", default-features = false } (#373)

  • Support using r#source as field name to opt out of a field named "source" being treated as an error's Error::source() (#350)

    #[derive(Error, Debug)]
    #[error("{source} ==> {destination}")]
    pub struct Error {
        r#source: char,
        destination: char,

... (truncated)

Commits
  • 6097d61 Release 2.0.0
  • 40113bd Merge pull request #373 from dtolnay/nostd
  • d8ed5fb Allow disabling std dependency on 1.81+
  • 8277ec4 Merge pull request #372 from dtolnay/stdbacktrace
  • d6d896d Access Backtrace exclusively through ::thiserror
  • d14adfb Merge pull request #371 from dtolnay/coreprovider
  • 2e99c51 Drop Provider API support in pre-1.81 nightlies
  • bf3d6f3 Merge pull request #370 from dtolnay/stderror
  • e0e9943 Access Error trait exclusively through ::thiserror
  • db7825e Merge pull request #369 from dtolnay/stdpath
  • Additional commits viewable in compare view

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Updates the requirements on [thiserror](https://github.com/dtolnay/thiserror) to permit the latest version.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](dtolnay/thiserror@1.0.30...2.0.0)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot bot added the dependencies Pull requests that update a dependency file label Nov 6, 2024
@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

Copy link

github-actions bot commented Nov 6, 2024

Benchmark for c5a05d3

Click to view benchmark
Test PR Benchmark Master Benchmark %
b_benchmark_rbac_model_large 10.4±0.10ms 10.3±0.27ms +0.97%
benchmark priority model 4.3±0.06µs 4.2±0.04µs +2.38%
benchmark_abac_model 2.4±0.02µs 2.5±0.06µs -4.00%
benchmark_basic_model 3.7±0.06µs 3.7±0.04µs 0.00%
benchmark_key_match 7.3±0.32µs 7.0±0.14µs +4.29%
benchmark_raw 0.0±0.00ns 0.0±0.00ns NaN%
benchmark_rbac_model 6.2±0.10µs 6.1±0.10µs +1.64%
benchmark_rbac_model_medium 837.8±17.27µs 855.9±11.66µs -2.11%
benchmark_rbac_model_with_domains 6.0±0.06µs 5.9±0.07µs +1.69%
benchmark_rbac_with_deny 8.5±0.14µs 8.4±0.09µs +1.19%
benchmark_rbac_with_resource_roles 4.4±0.07µs 4.3±0.07µs +2.33%
benchmark_role_manager_large 4.5±0.02ms 4.5±0.05ms 0.00%
benchmark_role_manager_medium 306.2±4.36µs 314.0±16.49µs -2.48%
benchmark_role_manager_small 29.9±0.72µs 29.3±0.43µs +2.05%

@hsluoyz hsluoyz closed this Nov 6, 2024
Copy link
Author

dependabot bot commented on behalf of github Nov 6, 2024

OK, I won't notify you again about this release, but will get in touch when a new version is available. If you'd rather skip all updates until the next major or minor version, let me know by commenting @dependabot ignore this major version or @dependabot ignore this minor version. You can also ignore all major, minor, or patch releases for a dependency by adding an ignore condition with the desired update_types to your config file.

If you change your mind, just re-open this PR and I'll resolve any conflicts on it.

@dependabot dependabot bot deleted the dependabot/cargo/thiserror-2.0.0 branch November 6, 2024 14:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants