Skip to content

Commit

Permalink
Merge branch 'main' into release/1.51
Browse files Browse the repository at this point in the history
* main:
  chore: pin goreleaser to 2.3.x (#3598)
  fix: devcontainer update go version to 1.23 (#3597)
  docs: add MMartyn as a contributor for code (#3596)
  fix: update attachment messaging and size to allow 1mb (#3595)
  • Loading branch information
markphelps committed Nov 5, 2024
2 parents a182441 + dd3702c commit ad7cb67
Show file tree
Hide file tree
Showing 7 changed files with 21 additions and 11 deletions.
9 changes: 9 additions & 0 deletions .all-contributorsrc
Original file line number Diff line number Diff line change
Expand Up @@ -520,6 +520,15 @@
"contributions": [
"code"
]
},
{
"login": "MMartyn",
"name": "Matt Martyn",
"avatar_url": "https://avatars.githubusercontent.com/u/1448102?v=4",
"profile": "https://github.com/MMartyn",
"contributions": [
"code"
]
}
],
"contributorsPerLine": 7,
Expand Down
2 changes: 1 addition & 1 deletion .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
ARG GO_VERSION=1.22
ARG GO_VERSION=1.23

FROM golang:${GO_VERSION}

Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ jobs:
uses: goreleaser/goreleaser-action@v6
with:
distribution: goreleaser-pro
version: latest
version: "~> v2.3.0"
args: release --clean --nightly -f .goreleaser.${{ matrix.name }}.yml
env:
GORELEASER_CURRENT_TAG: ${{ env.GORELEASER_CURRENT_TAG }}
Expand Down Expand Up @@ -143,7 +143,7 @@ jobs:
uses: goreleaser/goreleaser-action@v6
with:
distribution: goreleaser-pro
version: latest
version: "~> v2.3.0"
args: release --nightly -f .goreleaser.nightly.yml
env:
GORELEASER_CURRENT_TAG: ${{ env.GORELEASER_CURRENT_TAG }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ jobs:
uses: goreleaser/goreleaser-action@v6
with:
distribution: goreleaser-pro
version: latest
version: "~> v2.3.0"
args: build --clean -f .goreleaser.${{ matrix.name }}.yml
env:
GORELEASER_KEY: ${{ secrets.GORELEASER_KEY }}
Expand Down Expand Up @@ -149,7 +149,7 @@ jobs:
uses: goreleaser/goreleaser-action@v6
with:
distribution: goreleaser-pro
version: latest
version: "~> v2.3.0"
args: release --clean
env:
GORELEASER_KEY: ${{ secrets.GORELEASER_KEY }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/snapshot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ jobs:
uses: goreleaser/goreleaser-action@v6
with:
distribution: goreleaser-pro
version: latest
version: "~> v2.3.0"
args: build --clean --snapshot -f .goreleaser.${{ matrix.name }}.yml
env:
GORELEASER_KEY: ${{ secrets.GORELEASER_KEY }}
Expand Down Expand Up @@ -117,7 +117,7 @@ jobs:
uses: goreleaser/goreleaser-action@v6
with:
distribution: goreleaser-pro
version: latest
version: "~> v2.3.0"
args: build --snapshot
env:
GORELEASER_KEY: ${{ secrets.GORELEASER_KEY }}
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -415,6 +415,7 @@ Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/d
</tr>
<tr>
<td align="center" valign="top" width="14.28%"><a href="https://github.com/devumesh"><img src="https://avatars.githubusercontent.com/u/58872100?v=4?s=100" width="100px;" alt="Umesh Balamurugan"/><br /><sub><b>Umesh Balamurugan</b></sub></a><br /><a href="https://github.com/flipt-io/flipt/commits?author=devumesh" title="Code">💻</a></td>
<td align="center" valign="top" width="14.28%"><a href="https://github.com/MMartyn"><img src="https://avatars.githubusercontent.com/u/1448102?v=4?s=100" width="100px;" alt="Matt Martyn"/><br /><sub><b>Matt Martyn</b></sub></a><br /><a href="https://github.com/flipt-io/flipt/commits?author=MMartyn" title="Code">💻</a></td>
</tr>
</tbody>
</table>
Expand Down
8 changes: 4 additions & 4 deletions rpc/flipt/validation.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ import (
)

const (
maxJsonStringSize = 10000
entityPropertyKey = "entityId"
maxJsonStringSizeKB = 1000
entityPropertyKey = "entityId"
)

// Validator validates types
Expand All @@ -32,9 +32,9 @@ func validateJsonParameter(jsonValue string, parameterName string) error {
return errors.InvalidFieldError(parameterName, "must be a json string")
}

if len(bytes) > maxJsonStringSize {
if len(bytes) > (maxJsonStringSizeKB * 1024) {
return errors.InvalidFieldError(parameterName,
fmt.Sprintf("must be less than %d KB", maxJsonStringSize),
fmt.Sprintf("must be less than %d KB", maxJsonStringSizeKB),
)
}

Expand Down

0 comments on commit ad7cb67

Please sign in to comment.