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

[Xcode 16] Mutating property of a fragment causes compile time error #3398

Closed
martin-muller opened this issue Jun 24, 2024 · 4 comments · Fixed by apollographql/apollo-ios-dev#417
Assignees
Labels
bug Generally incorrect behavior high-priority needs investigation planned-next Slated to be included in the next release

Comments

@martin-muller
Copy link

Summary

Mutating property of a fragment annotated with @apollo_client_ios_localCacheMutation directive causes the following compile time error in Xcode 16 b1 with Swift 6:

Setter for 'fragments' is unavailable: mutate properties of the fragment instead.

I had a look around online but don't see mentions of changes to behaviour of modify anywhere, do you know if this is issue in Swift or change will have to be done in apollo?

Version

1.12.2

Steps to reproduce the behavior

this issue is reproducible in tests for this project:

Logs

No response

Anything else?

No response

@martin-muller martin-muller added bug Generally incorrect behavior needs investigation labels Jun 24, 2024
@AnthonyMDev
Copy link
Contributor

Thanks for making us aware of this. We'll look into this one ASAP. I haven't seen anything in the Swift 6 language that obviously would cause this, but there must be something that changed here.

Copy link
Contributor

Do you have any feedback for the maintainers? Please tell us by taking a one-minute survey. Your responses will help us understand Apollo iOS usage and allow us to serve you better.

@PSinha1202
Copy link

I am pointing to latest tag 1.15.0 and still see the issue. I expected this to be fixed and ready in latest tags, am I missing something?

@AnthonyMDev
Copy link
Contributor

Have you re-run the code generation with the latest version? This fix changes the generated models to remove the warning.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Generally incorrect behavior high-priority needs investigation planned-next Slated to be included in the next release
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants