You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jun 20, 2024. It is now read-only.
Hello, again thank you very much for providing validation.
We are seeing 2 issues right now. Probably because it is not implemented, but i dont know!
when we define something like this : repeated Localization localizations = 3 [(protoc.gen.jsonschema.field_options).required = true,(validate.rules).repeated.min_items = 1];
we get this : "localizations": { "items": { "$ref": "#/definitions/Localization" }, "type": "array", "description": "localized values for this title scope and type."
no minItems = 1
FYI Localization look like that message Localization { string language = 1 [(protoc.gen.jsonschema.field_options).required = true,(protoc.gen.jsonschema.field_options).min_length=2, (protoc.gen.jsonschema.field_options).pattern = "^(?!\\s*$).+"]; string value = 2 [(protoc.gen.jsonschema.field_options).required = true, (protoc.gen.jsonschema.field_options).pattern = "^(?!\\s*$).+"]; }
we try to use validation on items as in the doc of protoc-gen-validate. Is it possible to do something like this: repeated string value = 2 [(protoc.gen.jsonschema.field_options).required = true, (validate.rules).repeated.min_items = 1, (validate.rules).repeated.items.string.min_len = 1]; or repeated.items.string.pattern = 'regex-something' ?
Regards
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Hello, again thank you very much for providing validation.
We are seeing 2 issues right now. Probably because it is not implemented, but i dont know!
repeated Localization localizations = 3 [(protoc.gen.jsonschema.field_options).required = true,(validate.rules).repeated.min_items = 1];
we get this :
"localizations": { "items": { "$ref": "#/definitions/Localization" }, "type": "array", "description": "localized values for this title scope and type."
no minItems = 1
FYI Localization look like that
message Localization { string language = 1 [(protoc.gen.jsonschema.field_options).required = true,(protoc.gen.jsonschema.field_options).min_length=2, (protoc.gen.jsonschema.field_options).pattern = "^(?!\\s*$).+"]; string value = 2 [(protoc.gen.jsonschema.field_options).required = true, (protoc.gen.jsonschema.field_options).pattern = "^(?!\\s*$).+"]; }
repeated string value = 2 [(protoc.gen.jsonschema.field_options).required = true, (validate.rules).repeated.min_items = 1, (validate.rules).repeated.items.string.min_len = 1];
or repeated.items.string.pattern = 'regex-something' ?Regards
The text was updated successfully, but these errors were encountered: