-
Notifications
You must be signed in to change notification settings - Fork 2
Description
Reproduction steps
When building an App with XCode 15 (and therefore Swift 5), the iOS build fails (see logs below)
I suspect this is because of a breaking change with Swift 6 in the CFNetworkExecuteProxyAutoConfigurationURL (+ CFNetworkExecuteProxyAutoConfigurationScript)
(see: https://developer.apple.com/documentation/ios-ipados-release-notes/ios-ipados-18-release-notes#CFNetwork)
In order to fix this, I suppose a swift version check could be added around the function calls, to make it compatible with Swift versions below 6
Expected behavior
The build should work for XCode 15 and Swift 5
Actual Behavior
The build failed
Logs
`
Failed to build iOS app
Swift Compiler Error (Xcode): Cannot assign value of type 'Unmanaged' to type 'CFRunLoopSource'
/Users/runner/.pub-cache/hosted/pub.dev/proxy_selector-0.0.3/ios/Classes/SwiftProxySelectorPlugin.swift:365:33
Swift Compiler Error (Xcode): Cannot convert value of type 'Unmanaged' to expected argument type 'CFRunLoopSource'
/Users/runner/.pub-cache/hosted/pub.dev/proxy_selector-0.0.3/ios/Classes/SwiftProxySelectorPlugin.swift:367:58
Swift Compiler Error (Xcode): Cannot convert value of type 'Unmanaged' to expected argument type 'CFRunLoopSource?'
/Users/runner/.pub-cache/hosted/pub.dev/proxy_selector-0.0.3/ios/Classes/SwiftProxySelectorPlugin.swift:369:50
Swift Compiler Error (Xcode): Cannot convert value of type 'Unmanaged' to expected argument type 'CFRunLoopSource?'
/Users/runner/.pub-cache/hosted/pub.dev/proxy_selector-0.0.3/ios/Classes/SwiftProxySelectorPlugin.swift:371:53
Swift Compiler Error (Xcode): Cannot assign value of type 'Unmanaged' to type 'CFRunLoopSource'
/Users/runner/.pub-cache/hosted/pub.dev/proxy_selector-0.0.3/ios/Classes/SwiftProxySelectorPlugin.swift:419:33
Swift Compiler Error (Xcode): Cannot convert value of type 'Unmanaged' to expected argument type 'CFRunLoopSource'
/Users/runner/.pub-cache/hosted/pub.dev/proxy_selector-0.0.3/ios/Classes/SwiftProxySelectorPlugin.swift:421:58
Swift Compiler Error (Xcode): Cannot convert value of type 'Unmanaged' to expected argument type 'CFRunLoopSource?'
/Users/runner/.pub-cache/hosted/pub.dev/proxy_selector-0.0.3/ios/Classes/SwiftProxySelectorPlugin.swift:423:50
Swift Compiler Error (Xcode): Cannot convert value of type 'Unmanaged' to expected argument type 'CFRunLoopSource?'
/Users/runner/.pub-cache/hosted/pub.dev/proxy_selector-0.0.3/ios/Classes/SwiftProxySelectorPlugin.swift:425:53
Encountered error while archiving for device.
`
Environment
No response