Post

Replies

Boosts

Views

Activity

Reply to Asynchronous json retrieval
You're passing a data task into the method, rather than the data that it needs. The error message is quite explicit about that. Try something like this: let url = URL(string: "https://www.TEST_URL.com/api_ios.php")! let config = URLSessionConfiguration.default config.requestCachePolicy = .reloadIgnoringLocalAndRemoteCacheData let session = URLSession.init(configuration: config) session.dataTask(with: url) {(data, response, error) in do { if let json = data { if let decodedData = try? JSONDecoder().decode(Item.self, from: json) { ... } } } }.resume()
Topic: Programming Languages SubTopic: Swift Tags:
Mar ’25
Reply to I deleted my notes from iCloud and can’t restore them. Я удалил заметки из iCloud и не могу восстановить.
I can only suggest you check out the support options on this page: https://support.apple.com/en-kz Or post on the Support Forums via the link I provided previously. This page explains how to recover notes via iCloud.com: https://support.apple.com/en-gb/guide/icloud/mm2f42f05cb9/icloud but it does mention that if you cannot see a "Recently Deleted" folder, then there were no notes in the folder, and you must've permanently deleted them. If that's the case, then you will have to reach out to support via those forums, and ask that they try to recover your notes before they permanently delete them. I can't really help you any more than that.
Mar ’25
Reply to SDK version issue
Third row down in the table on this page: https://developer.apple.com/support/xcode/ shows that Xcode 16 supports deployment targets for iOS of 12-18. Your app can be built with the iOS 18 SDK and still support older versions, you just need to handle them in the code. You can continue to use the iOS 17.0 SDK and release versions of your app built with that version, but not from April 24th 2025 onwards. What happens when you use the iOS 18 SDK and set the minimum version to 12? It should work correctly.
Mar ’25
Reply to I deleted my notes from iCloud and can’t restore them. Я удалил заметки из iCloud и не могу восстановить.
These are the Developer Forums, where developers of apps for Apple's platforms ask each other for hints and tips on coding. Your question is more of a product support one, so while I'd normally suggest you ask it over at the Apple Support Forums, it's easy enough to just answer it here (but, please, ask product support questions in the right place, not here). Recently deleted notes are in the "Recently Deleted" section in the Notes app. Just tap that, and you should be able to un-delete them. They should be there for at least 30 days:
Mar ’25
Reply to UITabbarController issue on iOS 18
Looks like a change in iOS 18, and it looks like it's correct now. You tapped a different tab, so the first action should be "I selected a tab", and the second would be "the tab I'm currently on is going to disappear". They shouldn't be the other way round because why would the tab start to disappear without some input? Is it causing an issue in your app on the two different iOS versions?
Topic: UI Frameworks SubTopic: UIKit Tags:
Mar ’25
Reply to iOS Share Extension Warning: Passing argument of non-sendable type outside of main actor-isolated context may introduce data races
I can't provide you with a full, completely working solution, but this doesn't cause any errors: class ShareViewController: UIViewController { override func viewDidLoad() { super.viewDidLoad() } override func loadView() { super.loadView() if let inputItem = extensionContext!.inputItems.first as? NSExtensionItem { if let itemProvider = inputItem.attachments?.first { itemProvider.loadItem(forTypeIdentifier: UTType.url.identifier as String) { [unowned self] (item, error) in let contentView = ShareView(extensionContext: extensionContext, url: item as! URL) DispatchQueue.main.async { let hostingView = UIHostingController(rootView: contentView) hostingView.view.frame = self.view.frame self.view.addSubview(hostingView.view) } } } } } } struct ShareView: View { var extensionContext: NSExtensionContext? var url: URL var body: some View { VStack{} .task{ await extractItems() } } func extractItems() async { try await downloadAndSaveMedia(reelURL: url.absoluteString) extensionContext?.completeRequest(returningItems: []) } } In your code you get all the attachments here: if let itemProviders = (extensionContext?.inputItems.first as? NSExtensionItem)?.attachments { and you send that array of NSItemProvider to ShareView(), but you then get just the first attachment here (first line of extractItems()): guard let itemProvider = itemProviders.first else { return }, so in my code I'm just using the first attachment. The distinction is that I do all that stuff in the loadView() method rather than in ShareView(). Might work for you, might not, but I don't think you've tried this. You can probably tidy it up a little.
Topic: Programming Languages SubTopic: Swift Tags:
Mar ’25
Reply to EU distribution
You need to confirm whether you're a trader under the EU's Digital Service Act (DSA) rules. Traders are those who make any money from their apps in the EU, i.e. paid apps, or free ones with in-app purchases. If you don't make any money from your apps, then you are not a trader and can confirm that you aren't. That would be all you need to do. There should be an option in App Store Connect to confirm your status. If you are a trader, you need to provide an address, email and phone number. But please note, those details will be displayed on your App Store pages so everyone in the EU can see them.
Mar ’25
Reply to UITextView crash on iOS 18.4 beta
You should probably raise this as a bug in the usual way. It won't really get progressed if it's only posted in these Developer Forums. You need to raise each issue you find separately at https://feedbackassistant.apple.com/ You can post the FB numbers here if you want, so that others can link to them.
Topic: UI Frameworks SubTopic: UIKit Tags:
Mar ’25
Reply to Where Should You Store Videos to Protect Them by Domain?
Why are you asking us? This is nothing to do with developing apps for Apple's platforms.
Replies
Boosts
Views
Activity
Mar ’25
Reply to Very strange behavoir of Safari.app, Notes.app on MacBook Pro
This is completely irrelevant to these forums.
Replies
Boosts
Views
Activity
Mar ’25
Reply to Asynchronous json retrieval
You're passing a data task into the method, rather than the data that it needs. The error message is quite explicit about that. Try something like this: let url = URL(string: "https://www.TEST_URL.com/api_ios.php")! let config = URLSessionConfiguration.default config.requestCachePolicy = .reloadIgnoringLocalAndRemoteCacheData let session = URLSession.init(configuration: config) session.dataTask(with: url) {(data, response, error) in do { if let json = data { if let decodedData = try? JSONDecoder().decode(Item.self, from: json) { ... } } } }.resume()
Topic: Programming Languages SubTopic: Swift Tags:
Replies
Boosts
Views
Activity
Mar ’25
Reply to I deleted my notes from iCloud and can’t restore them. Я удалил заметки из iCloud и не могу восстановить.
I can only suggest you check out the support options on this page: https://support.apple.com/en-kz Or post on the Support Forums via the link I provided previously. This page explains how to recover notes via iCloud.com: https://support.apple.com/en-gb/guide/icloud/mm2f42f05cb9/icloud but it does mention that if you cannot see a "Recently Deleted" folder, then there were no notes in the folder, and you must've permanently deleted them. If that's the case, then you will have to reach out to support via those forums, and ask that they try to recover your notes before they permanently delete them. I can't really help you any more than that.
Replies
Boosts
Views
Activity
Mar ’25
Reply to SDK version issue
Third row down in the table on this page: https://developer.apple.com/support/xcode/ shows that Xcode 16 supports deployment targets for iOS of 12-18. Your app can be built with the iOS 18 SDK and still support older versions, you just need to handle them in the code. You can continue to use the iOS 17.0 SDK and release versions of your app built with that version, but not from April 24th 2025 onwards. What happens when you use the iOS 18 SDK and set the minimum version to 12? It should work correctly.
Replies
Boosts
Views
Activity
Mar ’25
Reply to I deleted my notes from iCloud and can’t restore them. Я удалил заметки из iCloud и не могу восстановить.
These are the Developer Forums, where developers of apps for Apple's platforms ask each other for hints and tips on coding. Your question is more of a product support one, so while I'd normally suggest you ask it over at the Apple Support Forums, it's easy enough to just answer it here (but, please, ask product support questions in the right place, not here). Recently deleted notes are in the "Recently Deleted" section in the Notes app. Just tap that, and you should be able to un-delete them. They should be there for at least 30 days:
Replies
Boosts
Views
Activity
Mar ’25
Reply to Hubungi Bank BTN | Pusat Bantuan Whatsapp 081924363434
"App Store Connect Engineer", once again, this is clearly spam. Please just remove these as soon as you see them.
Replies
Boosts
Views
Activity
Mar ’25
Reply to My Game Was Rejected as Spam (4.3a) – Need Clarification & Guidance
"Spam" doesn't mean you copied bits from other games, it means your game is too similar to others on the Store. For example, if it's another solitaire card game then it's likely going to be marked as spam unless it has something new and innovative about it. What's your game about? Are there similar games on the Store already?
Replies
Boosts
Views
Activity
Mar ’25
Reply to UITabbarController issue on iOS 18
Looks like a change in iOS 18, and it looks like it's correct now. You tapped a different tab, so the first action should be "I selected a tab", and the second would be "the tab I'm currently on is going to disappear". They shouldn't be the other way round because why would the tab start to disappear without some input? Is it causing an issue in your app on the two different iOS versions?
Topic: UI Frameworks SubTopic: UIKit Tags:
Replies
Boosts
Views
Activity
Mar ’25
Reply to iOS Share Extension Warning: Passing argument of non-sendable type outside of main actor-isolated context may introduce data races
I can't provide you with a full, completely working solution, but this doesn't cause any errors: class ShareViewController: UIViewController { override func viewDidLoad() { super.viewDidLoad() } override func loadView() { super.loadView() if let inputItem = extensionContext!.inputItems.first as? NSExtensionItem { if let itemProvider = inputItem.attachments?.first { itemProvider.loadItem(forTypeIdentifier: UTType.url.identifier as String) { [unowned self] (item, error) in let contentView = ShareView(extensionContext: extensionContext, url: item as! URL) DispatchQueue.main.async { let hostingView = UIHostingController(rootView: contentView) hostingView.view.frame = self.view.frame self.view.addSubview(hostingView.view) } } } } } } struct ShareView: View { var extensionContext: NSExtensionContext? var url: URL var body: some View { VStack{} .task{ await extractItems() } } func extractItems() async { try await downloadAndSaveMedia(reelURL: url.absoluteString) extensionContext?.completeRequest(returningItems: []) } } In your code you get all the attachments here: if let itemProviders = (extensionContext?.inputItems.first as? NSExtensionItem)?.attachments { and you send that array of NSItemProvider to ShareView(), but you then get just the first attachment here (first line of extractItems()): guard let itemProvider = itemProviders.first else { return }, so in my code I'm just using the first attachment. The distinction is that I do all that stuff in the loadView() method rather than in ShareView(). Might work for you, might not, but I don't think you've tried this. You can probably tidy it up a little.
Topic: Programming Languages SubTopic: Swift Tags:
Replies
Boosts
Views
Activity
Mar ’25
Reply to EU distribution
You need to confirm whether you're a trader under the EU's Digital Service Act (DSA) rules. Traders are those who make any money from their apps in the EU, i.e. paid apps, or free ones with in-app purchases. If you don't make any money from your apps, then you are not a trader and can confirm that you aren't. That would be all you need to do. There should be an option in App Store Connect to confirm your status. If you are a trader, you need to provide an address, email and phone number. But please note, those details will be displayed on your App Store pages so everyone in the EU can see them.
Replies
Boosts
Views
Activity
Mar ’25
Reply to Dark mode on Apple Developer Forum
That's not gonna happen. Just raise a suggestion in the usual way, at: https://feedbackassistant.apple.com/
Replies
Boosts
Views
Activity
Mar ’25
Reply to Switching my App from UserDefaults to CoreData and CloudKit
If you're very new to coding, I don't think using AI for the entire app is the way to go. When are you going to learn anything? Do a search for how to implement SwiftData in your app (rather than CoreData). There is Apple Developer documentation that will help you with this. It also explains how to use CloudKit.
Topic: UI Frameworks SubTopic: SwiftUI
Replies
Boosts
Views
Activity
Mar ’25
Reply to UITextView crash on iOS 18.4 beta
You should probably raise this as a bug in the usual way. It won't really get progressed if it's only posted in these Developer Forums. You need to raise each issue you find separately at https://feedbackassistant.apple.com/ You can post the FB numbers here if you want, so that others can link to them.
Topic: UI Frameworks SubTopic: UIKit Tags:
Replies
Boosts
Views
Activity
Mar ’25