Frameworks

RSS for tag

Ask questions about APIs that can drive features in your apps.

Posts under Frameworks tag

200 Posts
Sort by:

Post

Replies

Boosts

Views

Activity

How to programatically fetch the unique ID of user who installed/paid the app
Hello, Which API can be used to programatically fetch the ID of user who installed/paid the app? This is useful if an app has to create a path hierarchy for different users who have installed/paid the app, for instance, /AppName//user_files, how to get the uniqueUserID, and also, to get the information about which user these files belong to based on this uniqueUserID. App is using Swift, SwiftUI. Thanks.
0
0
251
Mar ’24
Capturing POSIX Error Codes from Network Framework for macOS 10.15+ and iOS 12+
Hi everyone, I'm currently working on a project that involves using the Network framework on macOS 10.15 and iOS 12. While implementing error handling for my network connections, I encountered a warning about the conformance of 'NWError' to 'CustomNSError', which is only available in macOS 13.3 or newer. Here's the warning message I received while compiling the code: Warning: conformance of 'NWError' to 'CustomNSError' is only available in macOS 13.3 or newer self.vConnection = try NWConnection (to: self.vBaseSocketProperties!.uEndpoint!, using: self.vBaseSocketProperties!.uParamters!) self.vConnection?.stateUpdateHandler = { connectionState in switch connectionState { case .failed(let err): error_code = err.errorCode //Below all the other cases are also handled. }
1
0
537
Mar ’24
In what cases do the upcoming third-party SDK requirements apply exactly?
Please help me understand the phrasing from Apple's articles about this topic. Of course, I am referring to the SDKs from the official list, as only those are affected by the new regulations. 1, https://developer.apple.com/support/third-party-SDK-requirements/ Starting in spring 2024, you must include the privacy manifest for any SDK listed below when you submit new apps in App Store Connect that include those SDKs, or when you submit an app update that adds one of the listed SDKs as part of the update. That states 2 cases in which fresh SDK versions are needed, containing privacy information: If you submit a completely new app If your app update contains a framework which was not present in the previous version of the app So, according to my understanding, if I create an app update, which does not contain any new SDKs, only the ones that I have been using for a while now, I can keep using these older SKD versions. And it is not mandatory to update them to newer versions. Does Apple state anywhere that we have to update every SDK from the list this spring in every case? Because that would contradict what I quoted from the article. 2, https://developer.apple.com/news/?id=3d8a9yyh And if you add a new third-party SDK that’s on the list of commonly used third-party SDKs, these API, privacy manifest, and signature requirements will apply to that SDK. Again, this states that you have to use a fresh version of an SDK in case you add it newly to your app. This seems to reinforce my point that if a 3rd party SDK was already used in previous app versions, the new requirements do not apply to that SDK and I can keep using its older release which does not have its own privacy manifest file. My main concern here is that there are many 3rd party SDKs from the list that we already use in our projects, and it would be a huge effort if my team had to update all those SDKs in every project by May. But if I'm right, it is not mandatory for us. (Of course, it would be wise to update the SDKs every now and then, but that's not the point here.) Can anybody confirm whether my understanding is correct? Maybe link some proof if I'm not right? It would be nice to have a reply from someone working at Apple, to have a reliable answer.
2
0
1k
Mar ’24
How to Support for Static Library(.a) Privacy Manifest
Our team uses a static library (.a) consisting of C and C++. Our team is developing static libraries internally and not sharing them to the outside. Should we still provide 'Privacy Manifest' in this case?? I added the contents of our team's static library (.a) to the app's 'Privacy Manifest' and there was no problem. Nevertheless, if I have to add it separately to the static library (.a), should I create a new framework project itself and not use the .a? Or can I just create a new framework and wrap the .a file??
1
0
562
Apr ’24
SPM - Including privacy manifest in binary target
When distributing a 3rd party SDK as an XCFramework in order to include the privacy manifest to the bundle you need to include the resources key in the target configuration to point to the correct file, for example: resources: [.process("Resources/PrivacyInfo.xcprivacy")] However, when distributing the xcframework as a binaryTarget resources is not available. How can I include my privacy manifest when configuring Package.swift ?
0
2
666
Mar ’24
QUIC connection error
Hi, we are currently implementing below method for a quick POC in iOS (Xcode 15.3/macOS Sonoma 14.0): func startQUICConnection() async { // Set the initial stream to bidirectional. options.direction = .bidirectional self.mainConn?.stateUpdateHandler = { [weak self] state in print("Main Connection State: \(state)") switch state { case .ready: print("Ready...") default: break } } // Don't forget to start the connection. self.mainConn?.start(queue: self.queue) } This is what we have in the initializer of the class: parameters = NWParameters(quic: options) mainConn = NWConnection(to: endpoint, using: parameters) These are the class's properties: let endpoint = NWEndpoint.hostPort(host: "0.0.0.0", port: .init(integerLiteral: 6667)) let options = NWProtocolQUIC.Options(alpn: ["echo"]) let queue = DispatchQueue(label: "quic", qos: .userInteractive) var mainConn: NWConnection? = nil let parameters: NWParameters! As per the logs, we never get to the .ready state for the NWConnection. Logs: nw_path_evaluator_create_flow_inner failed NECP_CLIENT_ACTION_ADD_FLOW (null) evaluator parameters: quic, attach protocol listener, attribution: developer, context: Default Network Context (private), proc: 022B7C28-0271-3628-8E5E-26B590B50E5B nw_path_evaluator_create_flow_inner NECP_CLIENT_ACTION_ADD_FLOW 8FEBF750-979D-437F-B4A8-FB71F4C5A882 [22: Invalid argument] nw_endpoint_flow_setup_channel [C2 0.0.0.0:6667 in_progress channel-flow (satisfied (Path is satisfied), interface: en0[802.11], ipv4, ipv6, dns, uses wifi)] failed to request add nexus flow Main Connection State: preparing Main Connection State: waiting(POSIXErrorCode(rawValue: 22): Invalid argument) We're running a local server using proxygen on port 6667. It connects with the proxygen client though... Have tried several thing but results are the same.
1
0
994
Mar ’24
How do I tell if i added a sdk as a binary dependency as referred to in the Apple Privacy docs?
In https://developer.apple.com/support/third-party-SDK-requirements/ it says "Signatures are also required in these cases where the listed SDKs are used as binary dependencies. " As I am clueless regarding the technicalities of how sdks are added to a host app, the term binary dependency means nothing to me. For reference, our app uses Cocoapods to install all of the sdks.
1
0
447
Mar ’24
Is it allowed in iOS - Swift Dynamic Framework - Contains multiple Multiple Static Library
I have developed a framework for my customer, thats a swift dyanmic framework. For code modularization i have divided this framework features in to multiple static libraries as shown in the diagram below. Currently we have on main swift dynamnic framework and it contains 2 static libraries too. Also the first static library here in turn nested with another static library, Key points to note here is My static libraries contains other third party iOS frameworks My static libraries using CoccoaPods as the dependency for Alarmofire at the moment. My questios are Is there any problem in the current architecture , because i heard nested libraries are not supported in iOS . but since we dont have frameworks nested here, all of our second level frameworks are static libraries only. What are link/libary search path guidance we needed to take care to make a successful build.
5
0
636
Mar ’24
nw_interface_radio_type_t
我想用Network.framework中path_monitor来监听网络状态的变化,在Network.framework的interface.h中有一个枚举定义nw_interface_radio_type_t,我没有找到关于它的使用方法。 I want to use path_monitor in Network.framework to monitor changes in network status. There is an enumeration definition nw_interface_radio_type_t in interface.h of Network.framework. I have not found how to use it.
1
0
335
Mar ’24
Question: Asset validation error about self-made framework lib
Prepared archive for validation Validation failed error: Asset validation failed Missing Bundle Identifier. The application bundle contains a tool or framework [aaa.bbb.ccc.ddd.pkg/Payload/my.app/Contents/Frameworks/Abc.framework] that is missing the bundle identifier in its Info.plist file. (ID: 8d117580-6d15-4b9e-8a0c-3bd069c66c77) error: Asset validation failed Bad Bundle Executable. You must include a valid CFBundleExecutable key in the nested bundle [aaa.bbb.ccc.ddd.pkg/Payload/shudou.app/Contents/Frameworks/Abc.framework] property list file. (ID: 62894f06-c782-4d67-85df-91912d1b6609) Abc.framwork is a pre-built lib used in swift. I put following keys in Abc.xcframework's Info.plist, but no effect. <key>CFBundleIdentifier</key> <string>aaa.bbb.ccc.ddd.Libname</string> <key>CFBundleExecutable</key> <string>Libname</string>
1
0
427
Mar ’24
Cannot load module '***' built with SDK 'iphoneos16.4' when using SDK 'iphoneos17.0'
While building xcode is giving me the **** error Cannot load module '***' built with SDK 'iphoneos16.4' when using SDK 'iphoneos17.0': /Users/***/Library/Developer/Xcode/DerivedData/project-biopprgumksoaqgnrhztiivzzjkq/Build/Products/Debug-iphoneos/Turf.framework/Modules/Turf.swiftmodule/arm64-apple-ios.swiftmodule It's working fine on xcode 14.3 but giving error on xcode 15
1
0
1.3k
Mar ’24
Runner/Frameworks Files Are Not Created
I am creating a project with Flutter, but in the Runner/Frameworks folder, all files such as Pods_Runner.framework etc. are red and the file is not located in the specified folder. The same situation exists in my old projects. I don't know where I'm doing wrong, it was normal until a few days ago, but now even if I create a new project, I get the same error. Flutter Version: 3.13.9 Cocoapods Version: 1.15.2 XCode: 15.1
0
0
253
Mar ’24
Very bad journal suggestion api!!!
Why not give devs pvt file bundle, with only image and video, it's not live photo!!! I can't use the quick look framework to preview it, and I also can't share to another app as live photo example: save it back to photos or share it by iMessage 🙄 . I can't understand this design, why not any detail? Another thing is so bad, the music data type has no store ID for musickit play item, so the Apple Journal app can play the music, but other apps can't do it! The live photo is the same. What are you doing Apple?
1
0
463
Mar ’24
'CLBeaconIdentityCondition' in scope
With Xcode 15.3, iOS SDK 17.4, in a iOS App, I have this error : TestClass.swift:11:27: error: cannot find 'CLBeaconIdentityCondition' in scope let beaconCondition = CLBeaconIdentityCondition(uuid: UUID(uuidString: "12345678-1234-1234-1234-123456789012"), major: 1, minor: 2) I can reproduce with this swift code : import CoreLocation class TestClass: NSObject{ let beaconCondition = CLBeaconIdentityCondition(uuid: UUID(uuidString: "12345678-1234-1234-1234-123456789012"), major: 1, minor: 2) } And this compilation command : xcrun swiftc -target arm64-apple-ios17.4 -sdk $(xcrun --sdk iphoneos --show-sdk-path) -emit-executable TestClass.swift -o TestClassExecutable -F /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/Library/Frameworks -framework CoreLocation
1
0
243
Mar ’24
Is codeSignature required for static framework? (xcode)
0 In other frameworks, I've seen codeSignature included in dynamic cases. because dynamic frameworks have "embed and sign" option. but this time Apple said, "Signatures are so required in these cases where the listed SDKs are used as binary dependencies." Does that mean that even if the ".framework" file of the SDK you are deploying is static, you have to include codeSignature? and if a framework is not included in Privacy-Impacting SDKs list, is it okay not to sign?
0
0
200
Mar ’24
Signing xcframework SDK's
The current structure of my SDK xcframework is XXXX-Release.xcframework. Inside that, I have an XXXX.xcframework and a LICENSE.md file. Currently, this structure works fine in Swift Package Manager, dropping the XXXX-Release.xcframework file into Xcode and CocoaPods. When I sign my xcframework as per Apple's requirements, I need to sign XXXX.xcframework, which is on the second level. Signing this works fine. Will this meet Apple's requirements for signing an xcframework? I just want to make sure the current structure of my SDK does not need to change. Thanks
1
0
607
Mar ’24
iOS 17.4 (21E217) CMAltimeter not working
I have apps using CMAltimeter to get sensor data, but recently they stop working with iOS 17.4, it is not release but some user running beta version, the is no access to the sensor data anymore (altitude and barometer). Some user report they can fix it by manual the "Motion & Fitness" permission but it only appear on some device. Report has been sent to Apple but I post here to find the solution to fix it.
15
4
4.2k
Mar ’24