Skip to content

Commit

Permalink
[Automation] Smithy Version Bump - 1.46.0 (#87)
Browse files Browse the repository at this point in the history
Update Smithy Version to 1.46.0

---------

Co-authored-by: Smithy Automation <[email protected]>
Co-authored-by: Hunter Mellema <[email protected]>
  • Loading branch information
3 people authored Mar 27, 2024
1 parent 0ff8ff1 commit 3ef3926
Show file tree
Hide file tree
Showing 5 changed files with 38 additions and 35 deletions.
4 changes: 2 additions & 2 deletions conversion-examples/smithy-to-openapi/smithy-build.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
"sources": ["models"],
"maven": {
"dependencies": [
"software.amazon.smithy:smithy-openapi:1.45.0",
"software.amazon.smithy:smithy-aws-traits:1.45.0"
"software.amazon.smithy:smithy-openapi:1.46.0",
"software.amazon.smithy:smithy-aws-traits:1.46.0"
]
},
"projections": {
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
smithyVersion=1.45.0
smithyVersion=1.46.0
smithyGradleVersion=0.10.1
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ metadata validators = [
id: "OperationInputName"
configuration: {
messageTemplate: """
`@{id}` is bound as an input of `@{var|operation|id}` \
but does not have a name ending with 'Request'.
`@{id}` is bound as an input of `@{var|operation|id}` but
does not have a name ending with 'Request'.
"""
selector: "$operation(*) -[input]-> :not([id|name$=Request])"
}
Expand All @@ -39,8 +39,9 @@ metadata validators = [
id: "OperationErrorName"
configuration: {
messageTemplate: """
`@{id}` is bound as an error but does not have a name ending with 'Exception'. \
Perhaps you should rename this shape to `@{id|name}Exception`.
`@{id}` is bound as an error but does not have
a name ending with 'Exception'. Perhaps you should
rename this shape to `@{id|name}Exception`.
"""
selector: "operation -[error]-> :not([id|name$=Exception])"
}
Expand All @@ -52,9 +53,10 @@ metadata validators = [
id: "RawIntegerWithoutRange"
configuration: {
messageTemplate: """
This number shape in member `@{id}` of the operation input `@{var|structure}` \
does not have a range constraint on both its minimum or maximum value. \
Add the `@@range` trait to this integer shape and provide both minimum and maximum values. \
This number shape in member `@{id}` of the operation input
`@{var|structure}` does not have a range constraint on both
its minimum or maximum value. Add the `@@range` trait to this
integer shape and provide both minimum and maximum values.
For example, `@@range(min: 1, max: 500)`.
"""
selector: """
Expand All @@ -69,9 +71,9 @@ metadata validators = [
id: "RawIntegerWithoutRangeMin"
configuration: {
messageTemplate: """
This number shape in member `@{id}` of the operation input `@{var|structure}` \
does not have a maximum range constraint. \
Add a minimum value to the `@@range` trait on this shape. \
This number shape in member `@{id}` of the operation
input `@{var|structure}` does not have a maximum range constraint.
Add a minimum value to the `@@range` trait on this shape.
For example, `@@range(>>> min: 1 <<<, max: 500)`.
"""
selector: """
Expand All @@ -86,9 +88,9 @@ metadata validators = [
id: "RawIntegerWithoutRangeMax"
configuration: {
messageTemplate: """
This number shape in member `@{id}` of the operation input `@{var|structure}` \
does not have a maximum range constraint. \
Add a maximum value to the `@@range` trait on this shape. \
This number shape in member `@{id}` of the operation input
`@{var|structure}` does not have a maximum range constraint.
Add a maximum value to the `@@range` trait on this shape.
For example, `@@range(min: 1, >>> max: 500 <<<)`.
"""
selector: """
Expand Down
2 changes: 1 addition & 1 deletion quickstart-examples/quickstart-gradle/gradle.properties
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
smithyVersion=1.45.0
smithyVersion=1.46.0
smithyGradleVersion=0.10.1
37 changes: 19 additions & 18 deletions shared-model-examples/common-shapes/model/validators.smithy
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,10 @@ metadata validators = [
id: "RawIntegerWithoutRange"
configuration: {
messageTemplate: """
This number shape in member `@{id}` of the operation input `@{var|structure}` \
does not have a range constraint on both its minimum or maximum value. \
Add the `@@range` trait to this integer shape and provide both minimum and maximum values. \
This number shape in member `@{id}` of the operation
input `@{var|structure}` does not have a range constraint
on both its minimum or maximum value. Add the `@@range` trait
to this integer shape and provide both minimum and maximum values.
For example, `@@range(min: 1, max: 500)`.
"""
selector: """
Expand All @@ -38,9 +39,9 @@ metadata validators = [
id: "RawIntegerWithoutRangeMin"
configuration: {
messageTemplate: """
This number shape in member `@{id}` of the operation input `@{var|structure}` \
does not have a maximum range constraint. \
Add a minimum value to the `@@range` trait on this shape. \
This number shape in member `@{id}` of the operation input `@{var|structure}`
does not have a maximum range constraint.
Add a minimum value to the `@@range` trait on this shape.
For example, `@@range(>>> min: 1 <<<, max: 500)`.
"""
selector: """
Expand All @@ -54,9 +55,9 @@ metadata validators = [
id: "RawIntegerWithoutRangeMax"
configuration: {
messageTemplate: """
This number shape in member `@{id}` of the operation input `@{var|structure}` \
does not have a maximum range constraint. \
Add a maximum value to the `@@range` trait on this shape. \
This number shape in member `@{id}` of the operation input `@{var|structure}`
does not have a maximum range constraint.
Add a maximum value to the `@@range` trait on this shape.
For example, `@@range(min: 1, >>> max: 500 <<<)`.
"""
selector: """
Expand All @@ -71,7 +72,7 @@ metadata validators = [
id: "ListWithoutLengthConstraint"
configuration: {
messageTemplate: """
List shape `@{id}` does not have a length constraint specified. \
List shape `@{id}` does not have a length constraint specified.
Add the `@@length` trait to the list shape. For example, `@@length(min: 1, max: 2)`.
"""
selector: "list:not([trait|length])"
Expand All @@ -82,8 +83,8 @@ metadata validators = [
id: "ListWithoutLengthConstraintMinimum"
configuration: {
messageTemplate: """
List shape `@{id}` does not have a minimum length specified. \
Add a `min` value to the `@@length` trait on the list shape. \
List shape `@{id}` does not have a minimum length specified.
Add a `min` value to the `@@length` trait on the list shape.
For example, `@@length(>>> min: 1 <<<, max: 2)`.
"""
selector: "list[trait|length]:not([trait|length|min])"
Expand All @@ -94,8 +95,8 @@ metadata validators = [
id: "ListWithoutLengthConstraintMaximum"
configuration: {
messageTemplate: """
List shape `@{id}` does not have a maximum length specified. \
Add a `max` value to the `@@length` trait on the list shape. \
List shape `@{id}` does not have a maximum length specified.
Add a `max` value to the `@@length` trait on the list shape.
For example, `@@length(min: 1, >>> max: 2 <<<)`.
"""
selector: "list[trait|length]:not([trait|length|max])"
Expand All @@ -108,10 +109,10 @@ metadata validators = [
namespaces: ["example.common"]
configuration: {
messageTemplate: """
This String shape in member `@{id}` of the operation input `@{var|structure}` \
does not have a pattern constraint. \
Add the `@@pattern` trait to this string shape and provide a regex pattern. \
For example, `@@pattern("^[\\S\\s]+$")`.
This String shape in member `@{id}` of the operation input `@{var|structure}`
does not have a pattern constraint.
Add the `@@pattern` trait to this string shape and provide a regex pattern.
For example, `@@pattern("^[a-zA-z]+$")`.
"""
selector: """
operation -[input]-> $structure(*) > member
Expand Down

0 comments on commit 3ef3926

Please sign in to comment.