Closed aaronroggow closed 1 year ago
We also had this issue. I'm fairly sure this is fixed here: https://github.com/apollographql/apollo-ios-codegen/commit/724674751239f30176ebdd0581f2f70bc6e250f2#diff-c054ba7c82703b1509c6b5be659111a24c57a86cdaf784893a6471f8ef9e8c86R10
However this introduces a new, different bug: https://github.com/apollographql/apollo-ios/issues/3269
Thanks all! As @scottasoutherland noted, this has been resolved but we are still tracking #3269 🙏🏻
Summary
When generating persisted query operation manifests, we are seeing that the generation occasionally fails to produce unique hashes for every operation.
Normally, our manifest would be generated like so:
But occasionally it gets generated like this instead:
In every instance that I've observed, the incorrect hash is always the duplicated hash of the operation preceding it. Seems that something in the generation isn't updating the hash value in some race condition before it actually gets written to the file.
Version
1.6.1
Steps to reproduce the behavior
Here are the relevant bits of our configuration:
To reproduce, I'm simply generating our code from our schema repeatedly, which also generates the manifest. We are using the
apollo-ios-cli
executable provided with the release packages to perform our generation.To detect the error, I'm attempting to sync it with our operations store, which performs a uniqueness validation.
Locally, I had to do this 18 times before I observed a failure case. On our CI, it happens as often as every 3rd or 4th run. Locally I'm running this on an M1 Pro, in CI, we're running this on a much slower Intel machine.
Logs
No response
Anything else?
No response