Skip to content

Lint required optional#3929

Merged
k8s-ci-robot merged 12 commits intokubernetes-sigs:mainfrom
rikatz:lint-required-optional
Jul 31, 2025
Merged

Lint required optional#3929
k8s-ci-robot merged 12 commits intokubernetes-sigs:mainfrom
rikatz:lint-required-optional

Conversation

@rikatz
Copy link
Copy Markdown
Member

@rikatz rikatz commented Jul 17, 2025

What type of PR is this?
/kind cleanup
/kind test

What this PR does / why we need it: This PR enables the optionalorrequired linter and fixes violations on API, without causing breaking changes

Which issue(s) this PR fixes:
Fixes #3928

Does this PR introduce a user-facing change?:

NONE

@k8s-ci-robot k8s-ci-robot added release-note-none Denotes a PR that doesn't merit a release note. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. kind/test cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Jul 17, 2025
@k8s-ci-robot k8s-ci-robot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Jul 17, 2025
Comment thread config/crd/experimental/gateway.networking.k8s.io_gateways.yaml
Comment thread apis/v1/gateway_types.go Outdated
Comment thread apis/v1/gateway_types.go Outdated
Comment thread apis/v1/grpcroute_types.go
Comment thread .golangci-kal.yml
Comment thread apis/v1alpha2/tlsroute_types.go Outdated
Comment thread apis/v1/gateway_types.go Outdated
Comment thread .golangci-kal.yml
Comment thread apis/v1/gateway_types.go
Comment thread apis/v1/gateway_types.go Outdated
Comment thread apis/v1/grpcroute_types.go
@youngnick
Copy link
Copy Markdown
Contributor

This is a great change, thanks @rikatz! I think that with the GRPCRoute .spec changes pulled out into #3937, once that merges, this should be good to go - as all the existing changes are ones where we are just mandating things that we mandate in other places anyway (like having at least one Condition in Gateway's status.conditions array - we mandate you have at least two, actually, Accepted and Programmed).

/approve
/hold for further discussion though.

@k8s-ci-robot k8s-ci-robot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jul 22, 2025
@k8s-ci-robot
Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: rikatz, youngnick

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jul 22, 2025
@rikatz rikatz force-pushed the lint-required-optional branch 2 times, most recently from 455736d to dc7812b Compare July 28, 2025 20:33
@rikatz rikatz force-pushed the lint-required-optional branch from dc7812b to 97d42d2 Compare July 31, 2025 13:18
@rikatz rikatz force-pushed the lint-required-optional branch from 97d42d2 to 3904698 Compare July 31, 2025 13:24
@rikatz
Copy link
Copy Markdown
Member Author

rikatz commented Jul 31, 2025

/retest

@robscott
Copy link
Copy Markdown
Member

Thanks @rikatz!

/lgtm
/hold cancel

@k8s-ci-robot k8s-ci-robot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jul 31, 2025
@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jul 31, 2025
@k8s-ci-robot k8s-ci-robot merged commit 657b265 into kubernetes-sigs:main Jul 31, 2025
19 checks passed
tylerauerbeck pushed a commit to tylerauerbeck/gateway-api that referenced this pull request Nov 27, 2025
* Add missing required markers on gateway types

* Add missing required markers on grpcroute types

* Add missing required markers on httproute types

* Add missing required markers on obj_reference types

* Add missing required markers on shared types

* Add missing required markers on experimental types

* Add missing required markers on v1beta1 types

* Add missing required markers on v1alpha3 types

* Add missing required markers on v1alpha2 types

* Enable optionalorrequired linter

* Revert objectmeta field doc

* Revert minItems changes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. kind/test lgtm "Looks good to me", indicates that a PR is ready to be merged. release-note-none Denotes a PR that doesn't merit a release note. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

LINTER: Implement "optionalorrequired" on APIs

7 participants