Open liamfallon opened 3 months ago
The original statement is only partly true. Structured rendering results are returned in the status.renderStatus
field of the PackageRevisionResources object returned by an Update operation. (see e.g. here)
However, I would expect to see the same rendering results when I simply query PackageRevisionResources objects. But in this case status.renderStatus
will always be empty, similar to this:
status:
renderStatus:
error: ""
result:
exitCode: 0
metadata:
creationTimestamp: null
even if the package has a non-empty pipeline.
To be able to query the status of the last kpt package rendering, the renderStatus value should be persisted, IMHO in the (git/oci) repository.
One option would be to write it into the Kptfile's status field, and handle it similarly to how we handle PackageRevision's status.conditions
.
Related to #730 and https://github.com/nephio-project/porch/pull/75
Original issue URL: https://github.com/kptdev/kpt/issues/3628 Original issue user: https://github.com/droot Original issue created at: 2022-10-18T23:25:06Z Original issue last updated at: 2023-01-31T19:55:36Z Original issue body: Porch has two runtimes (
builtin
andpodevaluator
). Both the runtimes doesn't return structuredResult.I am seeing following error in porch during testing a package with
kubeval
function:It clearly has the correct validation errors but somehow the function runtime machinery (with render library) is not returning this validation errors in structured error format.
Original issue comments: Comment user: https://github.com/droot Comment created at: 2022-10-18T23:26:52Z Comment last updated at: 2022-10-18T23:26:52Z Comment body: /cc @ChristopherFry Making some progress in surfacing errors and results now. The above error is returned as part of the
packagerevisionresources
API (ignore the formatting the error message itself :))Comment user: https://github.com/yuwenma Comment created at: 2023-01-13T13:58:47Z Comment last updated at: 2023-01-13T13:58:47Z Comment body: @droot I feel like this can be a good "good first issue" candidate. Please remove the label if you prefer to take it.
Comment user: https://github.com/droot Comment created at: 2023-01-31T19:55:36Z Comment last updated at: 2023-01-31T19:55:36Z Comment body: > @droot I feel like this can be a good "good first issue" candidate. Please remove the label if you prefer to take it.
Sg. Unassigned so that someone can pick this up.