aws-mobile-appsync-sdk-ios
aws-mobile-appsync-sdk-ios copied to clipboard
S3Object inside Input type does not upload automatically if optional
Describe the bug
When using the auto upload feature(AWSS3TransferUtility) of AppSync, the S3Object is not recognized if the parameter is marked as Optional.
To Reproduce
- Create a schema in which an input has a
S3ObjectInputproperty, making the property optional. - The input should be referenced as a parameter in a mutation(the sample in this repo would suffice along with the nested S3 integration test, given that step 1 is achieved)
- Generate the resulting API
- Call the mutation, passing in a valid
S3ObjectInput
Expected behavior The file should automatically upload to the AWS S3 bucket
Environment
- AppSync SDK Version: 2.10.3
- Dependency Manager: Cocoapods
- Swift Version : 4.2
Device Information:
- Device: any device or simulator
- iOS Version: presumably any OS Version, but running 12.1.4
Additional context I verified this by converting my generated Swift API so that the file was not optional. Re-ran my tests and the file uploaded successfully.
Hi @johnmurphy01 ,
Thanks for the report. We will investigate this issue.
Thank you for opening this issue. AWS AppSync SDK for iOS entered maintenance mode in September 2023 and will receive no further updates as of September 2024.
Please use Amplify Swift going forward. For information on upgrading to Amplify Swift, refer to the Upgrade from AppSync SDK documentation.