-
Notifications
You must be signed in to change notification settings - Fork 78
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
Fix Markdown rendering #39
Conversation
thanks @radeksimko! This looks good. I have a couple of questions but they aren't blockers: 1: What was the markdown bug you fixed? The branch and commit message indicate a bug. |
|
|
||
Provider Requirements: | ||
{{- range $name, $req := .RequiredProviders }} | ||
* **{{ $name }}{{ if $req.Source }} ({{ $req.Source | tt }}){{ end }}:** {{ if $req.VersionConstraints }}{{ commas $req.VersionConstraints | tt }}{{ else }}(any version){{ end }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mildwonkey These two lines are the only difference from the previous template.
🤔 Thanks for pointing out the change - can you add a test example with a provider source attribute, and (if you haven't already) make sure the registry folks know that output is changing? I believe they parse that field. |
also I am so sorry, you linked the issue right in this PR 🙄 I need to invite all my braincells to monday morning PR reviews next time |
I think this test covers that already? |
I requested review from @hashicorp/tf-self-serve - I'm not sure if we have any better-matching team on GitHub covering the Registry. FWIW the output is not changing for providers that do not have a source defined. It's rather the internal representation which broke markdown rendering. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the ping! This looks fine from the Registry perspective since it uses tfconfig as a library for module parsing and renders its own template based on the parsed components.
Fixes #38
I took the liberty to decouple the markdown rendering logic and added Markdown test data for all relevant test cases.