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

JSON decoder not properly decoding proxyType in some projects #596

Closed
tjwio opened this issue Dec 15, 2020 · 0 comments · Fixed by #598
Closed

JSON decoder not properly decoding proxyType in some projects #596

tjwio opened this issue Dec 15, 2020 · 0 comments · Fixed by #598

Comments

@tjwio
Copy link
Contributor

tjwio commented Dec 15, 2020

Context 🕵️‍♀️

We have some Xcode projects that are generated by BUCK with proxyType as a number instead of a string.

What 🌱

This means that the decodeIntIfPresent will throw when it tries to decode it as a string and then bool. We hit this recently in one of our Xcode projects:

Error: typeMismatch(Swift.Bool, Swift.DecodingError.Context(codingPath: [CodingKeys(stringValue: "proxyType", intValue: nil)], debugDescription: "Expected to decode Bool but found a number instead.", underlyingError: nil))

Proposal 🎉

PR here: #598

pepicrft pushed a commit that referenced this issue Dec 17, 2020
* fix int bug and tests

* fix comment

* changelog

Co-authored-by: Tim Wong <[email protected]>
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 a pull request may close this issue.

1 participant