Skip to content

configs: Fix module loader nil pointer panic#31060

Merged
jbardin merged 1 commit intomainfrom
alisdair/fix-configload-snapshot-panic
May 23, 2022
Merged

configs: Fix module loader nil pointer panic#31060
jbardin merged 1 commit intomainfrom
alisdair/fix-configload-snapshot-panic

Conversation

@alisdair
Copy link
Copy Markdown
Contributor

In configurations which have already been initialized, updating the source of a non-root module call to an invalid value could cause a nil pointer panic. This commit fixes the bug and adds test coverage.

Fixes #31056.

@alisdair alisdair added config 1.2-backport If you add this label to a PR before merging, backport-assistant will open a new PR once merged labels May 16, 2022
@alisdair alisdair requested a review from a team May 16, 2022 20:47
@alisdair alisdair self-assigned this May 16, 2022
In configurations which have already been initialized, updating the
source of a non-root module call to an invalid value could cause a nil
pointer panic. This commit fixes the bug and adds test coverage.
@alisdair alisdair force-pushed the alisdair/fix-configload-snapshot-panic branch from 7928da3 to d1e35a3 Compare May 17, 2022 13:13
@alisdair
Copy link
Copy Markdown
Contributor Author

I updated the test to be less specific about the diagnostics, since they originate from a separate package, and all we care about is that there are error diags but no panic.

@jbardin
Copy link
Copy Markdown
Member

jbardin commented May 23, 2022

Merging and backporting so we can get an early release out.

@jbardin jbardin merged commit a6968b5 into main May 23, 2022
@github-actions
Copy link
Copy Markdown
Contributor

Reminder for the merging maintainer: if this is a user-visible change, please update the changelog on the appropriate release branch.

@github-actions
Copy link
Copy Markdown
Contributor

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 contributions.
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 Jun 23, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

1.2-backport If you add this label to a PR before merging, backport-assistant will open a new PR once merged config

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Crash when planning with an invalid module source in a parent module

3 participants