crossplane-runtime
crossplane-runtime copied to clipboard
Consider allowing for "comment only" YAML documents in package parser
What problem are you facing?
Currently, the package parser will ignore empty YAML documents and those that only contain whitespace. However, it does not accommodate for a YAML document that contains content which is only comments (which is effectively the same as the previous two document scenarios).
How could Crossplane help solve your problem?
We should consider allowing for "comment only" documents in packages and skipping them during parsing.
Relevant Yaml spec: https://yaml.org/spec/1.0/#id2561718
... A document header line may be used to start a document ...
@luebken to be clear, this is not due to a leading document header, but rather due to the fact that there is a complete document that only contains comment data. The xpkg specification restricts what can be included in a package. We currently also allow for "empty documents", but a document full of comments is not empty, which is why this scenario results in rejection.
Crossplane does not currently have enough maintainers to address every issue and pull request. This issue has been automatically marked as stale because it has had no activity in the last 90 days. It will be closed in 14 days if no further activity occurs. Leaving a comment starting with /fresh will mark this issue as not stale.