kubernetes-sigs / kubernetes-sigs/reference-docs
gen-apidocs Markdown backend omits ContainerStatus from the Pod API reference
Nobody has claimed this yet.
- Dominant language
- HTML
- Stars
- 130
- Forks
- 135
- Avg merge
- 16h 27m
- Merged PRs (30d)
- 3
Description
Problem
The gen-apidocs Markdown backend omits the ContainerStatus definition from the generated Pod API reference.
The OpenAPI input contains the complete io.k8s.api.core.v1.ContainerStatus definition, and PodStatus references it through:
containerStatusesinitContainerStatusesephemeralContainerStatuses
However, the generated core/pod-v1.md only displays the unlinked type ContainerStatus array.
The generated Markdown contains neither:
- a
## ContainerStatussection inpod-v1.md; nor - a standalone
ContainerStatuspage underdefinitions/.
As a result, the ContainerStatus schema and its fields are not reachable from the generated Markdown API reference.
Steps to reproduce
-
Clone
kubernetes-sigs/reference-docsand check outmaster. -
Generate the Kubernetes 1.36 Markdown API reference:
export K8S_RELEASE=1.36.0
make apimd
- Confirm that the OpenAPI input contains
ContainerStatus:
rg -n '"io.k8s.api.core.v1.ContainerStatus"' \
gen-apidocs/config/v1_36/swagger.json
The complete definition is present.
- Confirm that the generated Pod page references the type:
rg -n 'ContainerStatus array' \
gen-apidocs/build/markdown/core/pod-v1.md
This finds containerStatuses, initContainerStatuses, and ephemeralContainerStatuses.
- Search for a generated
ContainerStatussection:
rg -n '^## ContainerStatus ' \
gen-apidocs/build/markdown/core/pod-v1.md
This produces no output and exits with status 1.
- Check for a standalone definition page:
find gen-apidocs/build/markdown \
-iname '*container-status*'
This also produces no output.
Actual behavior
The generated Pod status fields contain an unlinked type:
ContainerStatus array
No ContainerStatus definition is emitted anywhere in the Markdown output.
Expected behavior
ContainerStatus should be generated and reachable from the Pod API reference, either as a section in pod-v1.md or as a linked standalone definition.
Environment
- Repository:
kubernetes-sigs/reference-docs - Branch:
master - Backend:
markdown - Kubernetes release:
1.36.0 - Commit:
<output of git rev-parse HEAD>
Related issues
- kubernetes/website#56427
- kubernetes/website#56463
The website issue reports the user-visible symptom, and #56463 attempted to address the generated page directly. This issue tracks the behavior reproduced using the current gen-apidocs Markdown backend.
I'm interested in working on a fix and adding a regression test.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Run make apimd and inspect the Markdown backend using gen-apidocs/config/v1_36/swagger.json as input. Trace how core/pod-v1.md and definitions/ are generated, then add a regression test for ContainerStatus emission and linking. Done means the ContainerStatus schema and fields are reachable in the generated Markdown output.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- markdown, openapi
- Domain
- documentation, tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 58/100