api-linter
api-linter copied to clipboard
AIP-133 parent detection shouldn't trigger for top-level resources
https://linter.aip.dev/133/request-parent-required will show a warning whenever there is no parent field. AIP-133 specifically mentions: A parent field must be included unless the resource being created is a top-level resource (since top-level resources don't have a parent, by definition).
It would be better if the linter could try to detect probable top-level resources. It would also be better if the language of the linter warning specifically called out the possibility that this is a top-level resource, and gave guidance on what to do (e.g. standard language for disabling the linter warning for that resource).