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

fix: runtime: fix (*App).RegisterMoodules inconsistency in checking/memoizing appModule #14128

Merged

Conversation

odeke-em
Copy link
Collaborator

@odeke-em odeke-em commented Dec 1, 2022

Fixes an inconsistency in checking for duplicates in ModuleManager's Modules[name] then also basicManager[name] in which memoization could happen for .Module[name] but fail after a duplicate check in basicManager[name]. This change instead only memoizes the AppModule after the duplicate checks have all cleared.

Fixes #14006

…emoizing appModule

Fixes an inconsistency in checking for duplicates in ModuleManager's
Modules[name] then also basicManager[name] in which memoization could
happen for .Module[name] but fail after a duplicate check in
basicManager[name]. This change instead only memoizes the AppModule
after the duplicate checks have all cleared.

Fixes #14006
@odeke-em odeke-em requested a review from a team as a code owner December 1, 2022 21:43
@odeke-em odeke-em changed the title fix: runtime: fix (*App).RegisterMoodules inconsistency in checking/m… fix: runtime: fix (*App).RegisterMoodules inconsistency in checking/memoizing appModule Dec 1, 2022
@sonarcloud
Copy link

sonarcloud bot commented Dec 1, 2022

[Cosmos SDK] Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

0.0% 0.0% Coverage
0.0% 0.0% Duplication

@aaronc aaronc merged commit 3aff993 into main Dec 1, 2022
@aaronc aaronc deleted the runtime-fix-RegisterModules-inconsistency-in-memoizing branch December 1, 2022 22:18
@julienrbrt
Copy link
Member

@Mergifyio backport release/v0.47.x

@mergify
Copy link
Contributor

mergify bot commented Dec 1, 2022

backport release/v0.47.x

✅ Backports have been created

mergify bot pushed a commit that referenced this pull request Dec 1, 2022
…emoizing appModule (#14128)

Fixes an inconsistency in checking for duplicates in ModuleManager's
Modules[name] then also basicManager[name] in which memoization could
happen for .Module[name] but fail after a duplicate check in
basicManager[name]. This change instead only memoizes the AppModule
after the duplicate checks have all cleared.

Fixes #14006

(cherry picked from commit 3aff993)
tac0turtle pushed a commit that referenced this pull request Dec 2, 2022
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

Successfully merging this pull request may close these issues.

runtime: small inconsistency in (*App).RegisterModules memoizing appModule
3 participants