Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add a subcommand into diff processor to detect missing docs #20883

Conversation

modular-magician
Copy link
Collaborator

#14743
Part 1 - add missing docs command into diff-processor to detect new fields or new resource without doc. This only covers resource, NOT data sources.

  • For all field diffs, it gets the resource doc
  • Parse resource doc to get the list of existing arguments and attributes defined in the doc
    • returned as a list of string, each string represented a flattend field, eg. a.b.c
    • the parse might not be 100% accurate and not covered all corner cases. Whether a field is a nested object is determined by whether that field description contains a nested tag (some resource, eg. compute_instance params field does not have that in the description)
  • If the field is argument and not int he argument list returned by doc parser, then it's included in the result; similary for attribute
    • however, i'm not sure about the argument/attribute condition written in the code is correct or not.

Release Note Template for Downstream PRs (will be copied)


Derived from GoogleCloudPlatform/magic-modules#11156

…p#11156)

[upstream:4f7ee52795cf5a3df2854c4ba782c2a4376fcef2]

Signed-off-by: Modular Magician <magic-modules@google.com>
@modular-magician modular-magician requested a review from a team as a code owner January 10, 2025 21:55
@modular-magician modular-magician merged commit d96ea1b into hashicorp:main Jan 10, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant