Fix context passed when resolving secrets in config file #2068
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What does this change
I was passing the context incorrectly when resolving secrets in the config file. This caused the trace spans to not be nested properly.
Here's what it looks like now, note that the plugin spans are not shown under the span in Porter where we called the plugin:
![Screen Shot 2022-05-17 at 7 05 13 PM](https://user-images.githubusercontent.com/1368985/168931769-0038d59f-d1ab-4fee-a0dd-a1c271ff9c16.png)
Here's what it looks like with the fix, now the spans are all nested in a way that matches the call graph
![Screen Shot 2022-05-17 at 7 07 45 PM](https://user-images.githubusercontent.com/1368985/168931813-bd18166a-bb67-426e-a66a-2655c5df689d.png)
:
What issue does it fix
The trace spans emitted when we load Porter's config file had the incorrect parent.
Notes for the reviewer
Checklist
Reviewer Checklist