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

Use moduleCalls.Declared as source for module.calls #987

Merged
merged 10 commits into from
Jul 8, 2022

Conversation

dbanck
Copy link
Member

@dbanck dbanck commented Jul 5, 2022

This PR updates the module.calls command to rely on the decoded module calls metadata, introduced in #882.

This allows us to instantly update the module calls view when a file inside the module is changed. In addition, because we're not relying on data from the .terraform folder anymore, the view never contains stale data.

Since we're only getting information about the current module and loose some information about nested modules, we're removing any nested views from the tree view.

Before

CleanShot 2022-07-06 at 12 56 58@2x

After

CleanShot 2022-07-06 at 12 57 19@2x

Resolves #725

@dbanck dbanck added the enhancement New feature or request label Jul 5, 2022
@dbanck dbanck self-assigned this Jul 5, 2022
@dbanck dbanck force-pushed the f-module-calls-from-config branch from 83d3214 to b492bb3 Compare July 6, 2022 10:43
@dbanck dbanck marked this pull request as ready for review July 6, 2022 13:08
@dbanck dbanck requested a review from a team as a code owner July 6, 2022 13:08
Copy link
Member

@radeksimko radeksimko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A few suggestions/questions in-line.

internal/terraform/datadir/module_types.go Outdated Show resolved Hide resolved
internal/langserver/handlers/command/module_calls.go Outdated Show resolved Hide resolved
internal/langserver/handlers/command/module_calls.go Outdated Show resolved Hide resolved
docs/commands.md Outdated Show resolved Hide resolved
@dbanck dbanck force-pushed the f-module-calls-from-config branch from 958cbe8 to e15ed9c Compare July 8, 2022 12:14
@dbanck dbanck requested a review from radeksimko July 8, 2022 12:15
Copy link
Member

@radeksimko radeksimko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just one minor suggestion about the formatting of the source address.

Looks so smooth now! 🌟 😍
2022-07-08 13 33 31

internal/langserver/handlers/command/module_calls.go Outdated Show resolved Hide resolved
internal/langserver/handlers/command/module_calls_test.go Outdated Show resolved Hide resolved
internal/langserver/handlers/command/module_calls_test.go Outdated Show resolved Hide resolved
@radeksimko radeksimko added this to the v0.29.0 milestone Jul 8, 2022
@dbanck dbanck merged commit 60986be into main Jul 8, 2022
@dbanck dbanck deleted the f-module-calls-from-config branch July 8, 2022 16:48
@github-actions
Copy link

github-actions bot commented Aug 8, 2022

I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 8, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Use configuration as the primary source for module.calls
2 participants