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

Deep merge toBeAdded type policies #8361

Merged
merged 5 commits into from
Jun 8, 2021
Merged

Deep merge toBeAdded type policies #8361

merged 5 commits into from
Jun 8, 2021

Conversation

Banou26
Copy link
Contributor

@Banou26 Banou26 commented Jun 8, 2021

Fix #7535

This PR deep-merge toBeAdded typePolicies instead of shallowly merging them

cc @brainkim

@apollo-cla
Copy link

@Banou26: Thank you for submitting a pull request! Before we can merge it, you'll need to sign the Apollo Contributor License Agreement here: https://contribute.apollographql.com/

@brainkim brainkim requested review from brainkim and benjamn June 8, 2021 18:44
Copy link
Member

@benjamn benjamn left a comment

Choose a reason for hiding this comment

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

Thanks for tracking this down and finding a solution and adding tests @Banou26!

I think I'm at fault here for not realizing the compact helper function would produce different results than just calling updateTypePolicy multiple times in a row (which works). Sorry about that!

I'm also sorry for keeping you waiting on #7535. Thanks for your patience.

src/cache/inmemory/policies.ts Outdated Show resolved Hide resolved
@brainkim
Copy link
Contributor

brainkim commented Jun 8, 2021

@Banou26 thank you so much for this!

@benjamn benjamn merged commit b6c18b2 into apollographql:main Jun 8, 2021
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 15, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Type policies broken starting 3.3.0
4 participants