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
Copy file name to clipboardExpand all lines: .golangci-kal.yml
+11-2Lines changed: 11 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -124,6 +124,11 @@ linters:
124
124
text: "Properties should not use a map type, use a list type with a unique name/identifier instead"
125
125
linters:
126
126
- kubeapilinter
127
+
# It's simpler to check these fields against nil vs. using reflect.DeepEqual everywhere.
128
+
- path: "api/core/v1beta2/clusterclass_types.go"
129
+
text: "optionalfields: field (AdditionalProperties|Items|Not) (is optional and does not allow the zero value. It must have the omitzero tag|is optional and does not have a valid zero value. The field does not need to be a pointer)"
130
+
linters:
131
+
- kubeapilinter
127
132
128
133
## Removal of bool fields of existing types requires further discussion
text: "optionalfields: field AddressRef is optional and has a valid zero value \\({}\\), but the validation is not complete \\(e.g. min properties/adding required fields\\). The field should be a pointer to allow the zero value to be set. If the zero value is not a valid use case, complete the validation and remove the pointer."
219
+
- path: "api/.*"
220
+
text: "optionalfields: field (.*) is optional and (should have the omitempty tag|should be a pointer)"
221
+
linters:
222
+
- kubeapilinter
223
+
- path: "api/.*"
224
+
text: "optionalfields: field (.*) is optional and has a valid zero value \\({}\\), but the validation is not complete \\(e.g. min properties/adding required fields\\). The field should be a pointer to allow the zero value to be set. If the zero value is not a valid use case, complete the validation and remove the pointer."
0 commit comments