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

Show default values for supported timeouts #252

Open
tylerFowler opened this issue May 17, 2023 · 5 comments
Open

Show default values for supported timeouts #252

tylerFowler opened this issue May 17, 2023 · 5 comments

Comments

@tylerFowler
Copy link

The AWS provider resource docs show not only which timeouts are supported -but also their default values from code. This would be a great addition to tfplugindocs.

@jacobbednarz
Copy link
Contributor

this already works pretty well today - timeouts show up in the generated documentation if you include it explicitly on your schema. this isn't something i'd like to see on all my resources though.

@bflad
Copy link
Member

bflad commented May 18, 2023

Hi @tylerFowler 👋 As alluded to above, timeouts configuration will display in the default tfplugindocs resource documentation template in the schema section, if the attribute or block is in the schema. The AWS provider documentation for this resource is using a custom Markdown file to display the timeouts configuration section separately.

Are you looking for tfplugindocs to treat the timeouts attribute/block separately in the default resource template (removing it from the standard schema information and creating a separate Timeouts section)?

@tylerFowler
Copy link
Author

Oh sorry, no, I'd like the default time values to appear. The section formatting as-is is awesome, what I'm missing from tfplugindocs is the actual default value:

create - (Default 75m)

My generated docs do not contain that "Default 75m" bit, but would be massively helpful.

@jacobbednarz
Copy link
Contributor

i mentioned this in #71 (comment) as well, but have you tried adding something like https://github.com/cloudflare/terraform-provider-cloudflare/blob/master/internal/sdkv2provider/provider.go#L33-L39 to your provider configuration? i don't explicitly have any timeouts added anywhere but it should work?

@tylerFowler
Copy link
Author

I do yes but it doesn’t work for the separately-generated timeouts values

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

No branches or pull requests

3 participants