Post

Replies

Boosts

Views

Activity

Reply to The network connection was lost kCFStreamErrorDomainKey and kCFStreamErrorCodeKey
At present, the error affects about one in seven customers in Australia. The host is based in Europe. Thus far, have been unable to reproduce. Have tried the Network Link Conditioner, Charles Proxy throttling and breakpoints, disabling wifi, disconnecting ethernet, and combinations thereof. All whilst connected to ExpressVPN Sydney using Xcode and simulator. This induced: -1004 "Could not connect to the server." -1009 "The Internet connection appears to be offline." but as yet no -1005. How does “could not connect” and “internet connection appears to be offline” differ from "network connection was lost”? After all, we are pulling the plug - literally - while the url is awaiting response. Please, any clues about how to induce a -1005, or the specific conditions in the private CFNetwork code that trigger a -1005, would be much appreciated. We have one of the team based in Sydney and can ask for his help if need be.
Topic: App & System Services SubTopic: General Tags:
Oct ’22
Reply to JSONDecoder Limit
Problem occurs with Xcode 12.4 (12D4e). Eight properties good, nine properties bad: import Foundation public struct Foo: Codable { public let a01: String public let a02: String public let a03: String public let a04: String public let a05: String public let a06: String public let a07: String public let a08: String public let a09: String } let foo = Foo(a01: "foo", a02: "foo", a03: "foo", a04: "foo", a05: "foo", a06: "foo", a07: "foo", a08: "foo", a09: "foo") do { let encoder = JSONEncoder() let data = try encoder.encode(foo) if let jsonString = String(data: data, encoding: .utf8) { print(jsonString) } } catch { print(error) } Exception as follows: CoderBug.xcplaygroundpage: error: Playground execution aborted: error: Execution was interrupted, reason: EXC_BAD_ACCESS (code=EXC_I386_GPFLT). The process has been left at the point where it was interrupted, use "thread return -x" to return to the state before expression evaluation.
Topic: Programming Languages SubTopic: Swift Tags:
Apr ’21
Reply to Polling With Combine’s dataTaskPublisher
Follow up on the above that I tried option 2. This worked in the sense that the subscription was received every minute according to the timer. This can be see in the Date output below. However, this did not cause the dataTaskPublisher to re-run. So the bytes shown are from the original request that ran once only. (2020-12-29 15:05:30 +0000, 61631 bytes) combined (2020-12-29 15:05:33 +0000, 61631 bytes) combined (2020-12-29 15:05:36 +0000, 61631 bytes) combined (2020-12-29 15:05:39 +0000, 61631 bytes) combined (2020-12-29 15:05:42 +0000, 61631 bytes) combined
Topic: Programming Languages SubTopic: Swift Tags:
Dec ’20