aws-amplify / amplify-swift

A declarative library for application development using cloud services.
Apache License 2.0
442 stars 192 forks source link

Crash in AWSS3StorageService.upload(serviceKey:uploadSource:contentType:metadata:accelerate:onEvent:) + 14 #3785

Open amruth-movano opened 1 month ago

amruth-movano commented 1 month ago

Describe the bug

          Crashed: com.apple.root.user-initiated-qos.cooperative
0  libswiftCore.dylib             0x398c0 _assertionFailure(_:_:file:line:flags:) + 264
1  Evie Ring                      0x7bf460 specialized static Fatal.die(reason:extra:file:line:) + 77 (Fatal.swift:77)
2  Evie Ring                      0x7bec1c static Fatal.require(_:file:line:) + 55 (Fatal.swift:55)
3  Evie Ring                      0x14cd298 specialized FileSystem.getFileSize(fileURL:) + 172 (FileSystem.swift:172)
4  Evie Ring                      0x14ebcd0 UploadSource.getFile(fileSystem:) + 21 (UploadSource.swift:21)
5  Evie Ring                      0x14bbae8 closure #2 in AWSS3StorageService.upload(serviceKey:uploadSource:contentType:metadata:accelerate:onEvent:) + 14 (UploadSource.swift:14)
6  libswift_Concurrency.dylib     0x4d764 swift::runJobInEstablishedExecutorContext(swift::Job*) + 436
7  libswift_Concurrency.dylib     0x4e9c8 swift_job_runImpl(swift::Job*, swift::ExecutorRef) + 72
8  libdispatch.dylib              0x15894 _dispatch_root_queue_drain + 392
9  libdispatch.dylib              0x1609c _dispatch_worker_thread2 + 156
10 libsystem_pthread.dylib        0x48f8 _pthread_wqthread + 228
11 libsystem_pthread.dylib        0x10cc start_wqthread + 8

Steps To Reproduce

- Occurring sometimes

Expected behavior

App should not crash wile uploading file to s3

Amplify Framework Version

2.35.4

Amplify Categories

Storage

Dependency manager

Swift PM

Swift version

5.9

CLI version

12.1.1

Xcode version

15.0

Relevant log output

No response

Is this a regression?

Yes

Regression additional context

-

Platforms

iOS

OS Version

iOS 17.5.1

Device

iPhone 11 Pro

Specific to simulators

No response

Additional context

No response

thisisabhash commented 1 month ago

Thank you for posting this - Could you please post the code snippets used, verbose logs with sensitive information redacted and steps to reproduce this issue?

amruth-movano commented 1 month ago

@thisisabhash this is from firebase on the local run we are not able to reproduce this issue

ruisebas commented 1 month ago

Thanks, could you please provide the full symbolicated crashlog?

It includes additional information that might help us root cause the issue.

amruth-movano commented 1 week ago

@ruisebas We are unable to reproduce this scenario using Xcode and the only stack trace which we have is I have already added