Skip to content

Commit 40776cc

Browse files
RichieEscarezMike Petersen
and
Mike Petersen
authored
Update API build and generate 0.19 API docs (#3043)
* remove eventing-contrib * update gen-crd-api-reference-docs version to fix API build errors * API docs build for 0.19 * revert API version and add troubleshooting docs * revert file * remove whitespace * Update docs/reference/api/README.md Co-authored-by: Mike Petersen <[email protected]> * add more detail * and now fix my typo Co-authored-by: Mike Petersen <[email protected]>
1 parent a3cc35c commit 40776cc

File tree

6 files changed

+4977
-5317
lines changed

6 files changed

+4977
-5317
lines changed

docs/reference/api/README.md

+19-4
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ The API source files are located at:
99

1010
- [Serving API](./serving.md)
1111
- [Eventing API](./eventing/eventing.md)
12-
- [Eventing-contrib resources API](./eventing/eventing-contrib.md)
1312

1413
## Updating API Reference docs (for Knative maintainers)
1514

@@ -57,7 +56,6 @@ To generate a version of the API:
5756

5857
- [Serving](https://github.com/knative/serving/releases/)
5958
- [Eventing](https://github.com/knative/eventing/releases/)
60-
- [Eventing-contrib resources](https://github.com/knative/eventing-contrib/releases/)
6159

6260
1. To run the `gen-api-reference-docs.sh` command from the `hack` directory, you
6361
specify the commits or tags for each of the corresponding Knative component
@@ -68,7 +66,6 @@ To generate a version of the API:
6866
6967
KNATIVE_SERVING_COMMIT=[commit_or_tag] \
7068
KNATIVE_EVENTING_COMMIT=[commit_or_tag] \
71-
KNATIVE_EVENTING_CONTRIB_COMMIT=[commit_or_tag] \
7269
./gen-api-reference-docs.sh
7370
```
7471

@@ -82,6 +79,25 @@ To generate a version of the API:
8279
After a successful build, the tool automatically opens that folder in the
8380
`tmp` directory.
8481

82+
If the script fails, there are a couple possible causes.
83+
84+
* If you get the
85+
`F1116 15:21:23.549503 63473 main.go:129] no API packages found in ./pkg/apis`
86+
error, check if a new version of the script is available:
87+
https://github.com/ahmetb/gen-crd-api-reference-docs/tags
88+
89+
The script is kept up-to-date with changes that go into the Kubernetes API.
90+
As Knative adds support for those APIs, you might need to make sure the
91+
corresponding
92+
[script `gen-crd-api-reference-docs` version](https://github.com/knative/docs/blob/master/hack/gen-api-reference-docs.sh#L26)
93+
is used.
94+
95+
* If you get the
96+
`F0807 13:58:20.621526 168834 main.go:444] type invalid type has kind=Unsupported which is unhandled`
97+
error, the import target might have moved. There might be other causes for that error but view
98+
[#2054](https://github.com/knative/docs/pull/2054) (and the linked Issues) for details about how we handled that error
99+
in the past.
100+
85101
1. Copy the generated API files into the `docs/reference` directory of your
86102
knative/docs clone.
87103

@@ -107,6 +123,5 @@ v0.18.0 API source files:
107123
```
108124
KNATIVE_SERVING_COMMIT=v0.18.0 \
109125
KNATIVE_EVENTING_COMMIT=v0.18.0 \
110-
KNATIVE_EVENTING_CONTRIB_COMMIT=v0.18.0 \
111126
./gen-api-reference-docs.sh
112127
```

docs/reference/api/eventing/eventing-contrib-api.md

-10
This file was deleted.

0 commit comments

Comments
 (0)