-
Notifications
You must be signed in to change notification settings - Fork 294
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
pkg/uuid: use google/uuid.Validate in Valid
So that any UUID string accepted by uuid.Parse also validates correctly with uuid.Valid, for the sake of consistency. Note that this means that uuid.Valid error messages no longer contain the input string, but that's for the best, as that often led to rendered errors repeating themselves: valid.err.a: invalid value "052ef62d_7223_58b6_a551_c1deee46d401" (does not satisfy uuid.Valid): invalid UUID "052ef62d_7223_58b6_a551_c1deee46d401": ./in.cue:16:5 The new rendered error is better: valid.err.a: invalid value "052ef62d_7223_58b6_a551_c1deee46d401" (does not satisfy uuid.Valid): invalid UUID format: ./in.cue:16:5 Signed-off-by: Daniel Martí <[email protected]> Change-Id: Ib7b44247b1ff2efe3fe90b916211b268ad8d856a Reviewed-on: https://review.gerrithub.io/c/cue-lang/cue/+/1199881 TryBot-Result: CUEcueckoo <[email protected]> Reviewed-by: Matthew Sackman <[email protected]> Unity-Result: CUE porcuepine <[email protected]>
- Loading branch information
Showing
2 changed files
with
28 additions
and
70 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters