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

desc: fix caching when wrapping protoreflect.Descriptor instances #606

Merged
merged 1 commit into from
Apr 9, 2024

Conversation

jhump
Copy link
Owner

@jhump jhump commented Apr 9, 2024

Several places used a noopCache, which could lead to issues if the same file appears in the root element's transitive dependencies more than once.

This fixes a similar issue in desc.WrapFiles -- though it uses a mapCache, it wasn't previously checking it for the files explicitly given. So if one of the explicitly named files was also in the transitive dependencies of an earlier named file, it would get wrapped more than once. This was the cause of fullstorydev/grpcurl#417.

@jhump jhump merged commit 48670ae into main Apr 9, 2024
6 checks passed
@jhump jhump deleted the jh/desc-fix-caching-wrapping branch April 9, 2024 20:28
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.

1 participant