daltoniam / Starscream

Websockets in swift for iOS and OSX
Apache License 2.0
8.36k stars 1.21k forks source link

Crash WebSocket.createHTTPRequest() WebSocket.swift:591 #992

Open light-cloud opened 11 months ago

light-cloud commented 11 months ago

Receive this crash. What could cause this?

In file WebSocket.swift:591 I see this:

request.setValue(headerWSConnectionValue, forHTTPHeaderField: headerWSConnectionName)

Environment:

From Crashlytics:

Crashed: com.walletconnect.sdk.network.monitor
0  CoreFoundation                 0x6e44 CF_IS_OBJC + 76
1  CoreFoundation                 0x1256c CFGetAllocator + 48
2  CFNetwork                      0xdd5a8 _CFStreamErrorFromCFError + 1868
3  CFNetwork                      0xdf3f8 _CFStreamErrorFromCFError + 9628
4  CFNetwork                      0x2940 CFURLRequestSetHTTPHeaderFieldValue + 136
5  Foundation                     0x12e184 specialized URLRequest._applyMutation<A>(_:) + 336
6                              0xea2168 WebSocket.createHTTPRequest() + 591 (WebSocket.swift:591)
7  WalletConnectSwiftV2           0x34bbc closure #1 in AutomaticSocketConnectionHandler.setUpNetworkMonitoring() + 68 (AutomaticSocketConnectionHandler.swift:68)
8  Combine                        0x59b8 Subscribers.Sink.receive(_:) + 96
9  Combine                        0x5948 protocol witness for Subscriber.receive(_:) in conformance Subscribers.Sink<A, B> + 24
10 Combine                        0x29808 Publishers.Autoconnect.Inner.receive(_:) + 52
11 Combine                        0x29764 Publishers.Multicast.Inner.receive(_:) + 236
12 Combine                        0x2966c protocol witness for Subscriber.receive(_:) in conformance Publishers.Multicast<A, B>.Inner<A1> + 24
13 Combine                        0x22ec8 PassthroughSubject.Conduit.offer(_:) + 708
14 Combine                        0x22bf4 partial apply for closure #1 in PassthroughSubject.send(_:) + 68
15 Combine                        0x22b90 ConduitList.forEach(_:) + 272
16 Combine                        0x22a2c PassthroughSubject.send(_:) + 264
17 Combine                        0x1a1c8 SubjectSubscriber.receive(_:) + 188
18 Combine                        0x1a0fc protocol witness for Subscriber.receive(_:) in conformance SubjectSubscriber<A> + 24
19 Combine                        0x24de0 CurrentValueSubject.Conduit.offer(_:) + 784
20 Combine                        0x24ac0 partial apply for closure #1 in CurrentValueSubject.send(_:) + 68
21 Combine                        0x22b90 ConduitList.forEach(_:) + 272
22 Combine                        0x3981c CurrentValueSubject.send(_:) + 372
23 WalletConnectSwiftV2           0x830e8 closure #1 in NetworkMonitor.init() + 28 (NetworkMonitoring.swift:28)
24 Network                        0x16fd48 partial apply for closure #1 in NWPathMonitor.startLocked(lockedState:) + 92
25 Network                        0x166e28 thunk for @escaping @callee_guaranteed @Sendable () -> () + 36
26 libdispatch.dylib              0x26a8 _dispatch_call_block_and_release + 32
27 libdispatch.dylib              0x4300 _dispatch_client_callout + 20
28 libdispatch.dylib              0xb894 _dispatch_lane_serial_drain + 748
29 libdispatch.dylib              0xc3c4 _dispatch_lane_invoke + 380
30 libdispatch.dylib              0x17004 _dispatch_root_queue_drain_deferred_wlh + 288
31 libdispatch.dylib              0x16878 _dispatch_workloop_worker_thread + 404
32 libsystem_pthread.dylib        0x1964 _pthread_wqthread + 288
33 libsystem_pthread.dylib        0x1a04 start_wqthread + 8
bukira commented 2 months ago

I have similar issue, do we have any update?

alexanderkhitev commented 2 months ago

Hello! Any news or updates? Thanks!

bukira commented 2 months ago

mine was due to no host in my url