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

Bump the all-dependencies group with 3 updates #22

Merged
merged 1 commit into from
Jan 29, 2024

Conversation

dependabot[bot]
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Jan 29, 2024

Bumps the all-dependencies group with 3 updates: garde, serde and serde_json.

Updates garde from 0.17.0 to 0.18.0

Release notes

Sourced from garde's releases.

v0.18.0

There are quite a few changes in this release:

Some of these are breaking changes. If you are only using the derive functionality and calling validate, updating should still be as simple as a version bump:

cargo add [email protected] -F full

If it isn't, please open an issue!

Length modes

You can now specify what kind of length you wish to validate by adding a new mode argument to your length rules. The argument is optional.

#[derive(garde::Validate)]
#[garde(transparent)]
struct Username(
    #[garde(
        length(bytes, min = 1, max = 100),
        length(graphemes, min = 1, max = 25)
    )]
    String
);

The above validates both bytes (via v.len()) and graphemes (via v.graphemes().count() using the unicode-segmentation crate. To understand why the distinction is important, consider the x character, which occupies 73 bytes in memory, but is considered a single grapheme.

The available modes are:

  • simple, which is the default, and its behavior depends on the type. For strings, it measures the number of bytes, and for collections (such as Vec), it meaures the number of items.
  • bytes, which uses s.len(), measuring the number of bytes,
  • graphemes, which uses s.graphemes(true).count(), measuring the number of graphemes
  • chars, which uses s.chars().count(), measuring the number of unicode scalar values
  • utf16, which uses s.encode_utf16().count(), measuring the number of UTF-16 code units

The original Length and HasLength traits have been removed, and replaced by one trait per length mode.

Adapters

Using adapters, it is possible to implement validation rules for 3rd-party types directly in your own crates.

mod my_str_adapter {
    #![allow(unused_imports)]
    pub use garde::rules::*; // re-export garde's rules
</tr></table>

... (truncated)

Commits
  • eb627df update versions
  • 4f057f0 Merge pull request #95 from jprochazk/no-default-features
  • 987d783 use --all-features in check
  • 5d3d443 remove default features, add full
  • 068ac5d Merge pull request #93 from jprochazk/adapters
  • 240e54e add docs
  • 31f3e9a implement #[garde(adapt)]
  • 291d042 Merge pull request #91 from jprochazk/newtype-empty-display
  • 3055d4b remove empty colon from display impl of report
  • 7ccf734 Merge pull request #90 from jprochazk/report-serde
  • Additional commits viewable in compare view

Updates serde from 1.0.195 to 1.0.196

Release notes

Sourced from serde's releases.

v1.0.196

  • Improve formatting of "invalid type" error messages involving floats (#2682)
Commits
  • ede9762 Release 1.0.196
  • d438c2d Merge pull request #2682 from dtolnay/decimalpoint
  • bef110b Format Unexpected::Float with decimal point
  • b971ef1 Merge pull request #2681 from dtolnay/workspacedeps
  • 29d9f69 Fix workspace.dependencies default-features future compat warning
  • aecb408 Sort workspace dependencies
  • 1c675ab Merge pull request #2678 from rodoufu/workspaceDependencies
  • dd61963 Adding workspace dependencies
  • 111803a Merge pull request #2673 from Sky9x/msrv-badge
  • 0024f74 Use shields.io's MSRV badges
  • See full diff in compare view

Updates serde_json from 1.0.111 to 1.0.113

Release notes

Sourced from serde_json's releases.

v1.0.113

  • Add swap_remove and shift_remove methods on Map (#1109)

v1.0.112

  • Improve formatting of "invalid type" error messages involving floats (#1107)
Commits
  • 09d865b Release 1.0.113
  • 5aeab4e Merge pull request #1109 from serde-rs/remove
  • ca3c2ca Add swap_remove and shift_remove methods on Map
  • 7fece96 Release 1.0.112
  • 6a6d2bb Merge pull request #1107 from serde-rs/unexpectedfloat
  • 83d7bad Format f64 in error messages using ryu
  • 107c2d1 Merge pull request #1106 from serde-rs/invalidvalue
  • 62ca3e4 Handle Unexpected::Unit in Error::invalid_value
  • 296fafb Factor out JSON-specific Display impl for serde::de::Unexpected
  • e56cc69 Merge pull request #1105 from keienWang/master
  • 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 <dependency name> major version will close this group update PR and stop Dependabot creating any more for the specific dependency's major version (unless you unignore this specific dependency's major version or upgrade to it yourself)
  • @dependabot ignore <dependency name> minor version will close this group update PR and stop Dependabot creating any more for the specific dependency's minor version (unless you unignore this specific dependency's minor version or upgrade to it yourself)
  • @dependabot ignore <dependency name> will close this group update PR and stop Dependabot creating any more for the specific dependency (unless you unignore this specific dependency or upgrade to it yourself)
  • @dependabot unignore <dependency name> will remove all of the ignore conditions of the specified dependency
  • @dependabot unignore <dependency name> <ignore condition> will remove the ignore condition of the specified dependency and ignore conditions

Bumps the all-dependencies group with 3 updates: [garde](https://github.com/jprochazk/garde), [serde](https://github.com/serde-rs/serde) and [serde_json](https://github.com/serde-rs/json).


Updates `garde` from 0.17.0 to 0.18.0
- [Release notes](https://github.com/jprochazk/garde/releases)
- [Commits](https://github.com/jprochazk/garde/compare/[email protected])

Updates `serde` from 1.0.195 to 1.0.196
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](serde-rs/serde@v1.0.195...v1.0.196)

Updates `serde_json` from 1.0.111 to 1.0.113
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](serde-rs/json@v1.0.111...v1.0.113)

---
updated-dependencies:
- dependency-name: garde
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: all-dependencies
- dependency-name: serde
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: all-dependencies
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: all-dependencies
...

Signed-off-by: dependabot[bot] <[email protected]>
@dependabot dependabot bot added the dependencies Pull requests that update a dependency file label Jan 29, 2024
@raffomania raffomania merged commit 477c067 into main Jan 29, 2024
1 check passed
@raffomania raffomania deleted the dependabot/cargo/all-dependencies-6f4ae480fc branch January 29, 2024 09:01
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.

1 participant