Skip to main content

Questions tagged [swift]

WARNING: Questions relating to programming generally belong on Stack Overflow. Scripting and automation questions using Swift are on topic here and SO but may be received better here if the overall question is less about the details of the Swift language.

Filter by
Sorted by
Tagged with
0 votes
0 answers
8 views

Convert ckpt model file to CoreML Model [closed]

I want to convert this audio to audio model from ckpt to CoreML model. I checked coremltools library, but I don't how to trace or script this model, as I don't know the architecture of this model, ...
Om Soni's user avatar
0 votes
0 answers
5 views

Keyboard is getting dismissed after typing one character in the search bar [migrated]

First I enter some text in the search bar controller, it works fine. Next I delete the text and retype the same text or different text. In this case the keyboard is getting dismissed immediately after ...
Nandini's user avatar
1 vote
1 answer
38 views

Apple programming-libraries & software: What's the meaning of the prefix "Core"? [closed]

Many Apple-libraries got this Prefix "Core", like for example "Core Location", "Core Data", "Core Graphics", "Core Storage". What's the meaning of &...
mizech's user avatar
  • 1,255
0 votes
0 answers
42 views

Sandbox: Testing in app purchase issue (no products retrieved from app store connect)

All of a sudden, I am no longer able to test in app purchases on testflight builds. try await Product.products(for: [productID]) returns an empty array. Production (app in app store) functions just ...
Roselinn Hoareau's user avatar
1 vote
2 answers
398 views

Is macOS `prefPane` app possible containing virus?

So I came across this unusual program, https://doomlaser.com/cursorcerer-hide-your-cursor-at-will/. I'd want to install it, however it's built using a macOS feature called prefPane, which lets you add ...
Joseph's user avatar
  • 113
0 votes
1 answer
73 views

How to debug Distributed Notification Center

I have two Swift macOS apps with running from XCode which are simple listener-notifier programs based on DistributedNotificationCenter. It all seems straightforward, but it is not always working. And ...
Przemekeke's user avatar
0 votes
0 answers
24 views

Any cheap way to build Swift iOS without using VMs?

I need a way to build code that I do at home for a school project, at school we have macbook PROs so it's not a problem here, however it means I cannot keep working when I'm at home and that's not ...
Akariiinnn's user avatar
2 votes
1 answer
228 views

Developing a new app: Is there a way to share the app with my remote Client so he can beta test the app on his iphone?

I'm developing a simple iPhone app (using Xcode & SwiftUI) for a Client who is in another state (here in the US). I have a valid up-to-date developer account. I'd like to release the app to his ...
raddevus's user avatar
  • 163
0 votes
2 answers
180 views

How to decode/decompress Apple's vCard notes

I have vCards that were exported from the Contacts app of Mac OS X 10.8.2. From what I can tell, Apple exported the notes with RTF that was compressed with LZF and converted the compressed data to ...
fractional_ideal's user avatar
0 votes
0 answers
39 views

Why Stable Diffusion model in .mlpackage not need 'vocab.json' and 'merges.txt' but .mlmodelc need?

ml-stable-diffusion image generation using python with .mlpackage format stable diffusion models. And there is neither 'vocab.json' nor 'merges.txt' file in the folder. But if generating images using ...
timyau's user avatar
  • 131
0 votes
1 answer
39 views

How to tell Applescript to call a Fondation's class's init?

A subquestion could be: how to find the AppleScript name of a class's instances? Context: I use the following to access NSTimeZone variables and apply methods. use scripting additions -- essential to ...
Recycleur's user avatar
0 votes
1 answer
104 views

What is difference between putting a macOS app as "open at login" and putting a macOS app in "allow in the background"? [closed]

I can see on my mac there are some apps like Google Chrome that launch automatically when I start my Mac and also I can see apps like Magnet which it is not in auto launch but in allow in background. ...
bulletproof software engineer's user avatar
1 vote
0 answers
102 views

How can I run bash command with having Sandbox in Swift? [closed]

I made a working app which hides and shows the desktop icons using bash the terminal command for making it, easier to do this job with an UI, it works ok without sandbox and if there is sandbox it ...
bulletproof software engineer's user avatar
4 votes
1 answer
102 views

Where do iOS Apps store their persistent keychain data when run on an M1 Mac?

iOS apps can persist data between uninstalls as explained here If an iOS app is run on a Mac, where would this data live? Is it accessible by the keychain viewer?
yspreen's user avatar
  • 151
1 vote
1 answer
429 views

Can I open any app from app store in xcode?

I just start learning iOS development and still haven't finish the course but I'm too curios to know if I can open an app from app store in xcode to see all of the code inside of it as it will make it ...
ms12's user avatar
  • 13
0 votes
0 answers
101 views

How can I tell if a macOS app is native or just a wrap around a website?

I've got a cookie notice when launching an app for the first time on macOS, which I didn't know was a thing. Looking at the processes running, I see 3 processes spawned by the app. One looks like a ...
Scb's user avatar
  • 101
2 votes
1 answer
772 views

chmod +x not working as expected, running another tool instead

Just wrote a simple commandline tool which works fine with swift but doesn't run as executable after chmod +x ... This is happening on my system so might be configuration related but not sure how to ...
staticVoidMan's user avatar
1 vote
1 answer
58 views

How to disable Apple Watch SOS crash detection temporarily out of app?

I'm currently developing a Apple Watch App for surfers. I've received many requests if we can pause or disable the crash detection of a watch in case our surfers app is running to prevent automatic ...
Mr. Jo's user avatar
  • 113
0 votes
2 answers
579 views

What happened to CreateMLUI? Has it been removed?

In my Swift project in Xcode, import CreateMLUI says no such module. Has this been replaced or just removed?
Micheal Bee's user avatar
0 votes
0 answers
107 views

How change value of "Press Fn to" in Keyboard preferences programmatically?

I need to change value of "Press Fn to" programmatically to "Do Nothing". I can't find a direct way to switch this. I believe that is possible do this with AppleScript, but will ...
a_kira's user avatar
  • 101
0 votes
0 answers
2k views

Run an AppleScript from Swift

I'm trying to return a value from AppleScript to Swift (in XCode). If I do this simple code it works: let myAppleScript = """ return "hello world" ""&...
PruitIgoe's user avatar
  • 101
-3 votes
1 answer
117 views

apparent Obsolescence in Apple Xcode and Swift [closed]

am desperately trying to develop in Xcode, Swift, and particularly SwiftUI. have perfectly good (and incredibly expensive) Apple hardware that is now about 8 to 10 years old. apparently this means i ...
James Knight's user avatar
0 votes
0 answers
87 views

Exists someway to update dock preferences plist without killall Dock? [duplicate]

AppleSpacesSwitchOnActivate is represented by the second button on print below In the code below, I get the current value and after I change. This can be tested in terminal with defaults read -g ...
a_kira's user avatar
  • 101
6 votes
2 answers
3k views

iOS Private APIs

I am interested in some of the technical details behind Apple's private APIs in iOS. I can't seem to find a good writeup on some of these details (beyond how to call the private API functions), though ...
Jack Humphries's user avatar
1 vote
1 answer
255 views

Can app developers control the way their app handles iCloud save conflicts?

I saved data to iCloud on laptop A, then opened the document on laptop B to update a part of it (with data only available on laptop B). After saving on laptop B, I realized that iCloud didn't give me ...
iconoclast's user avatar
  • 10.1k
0 votes
1 answer
259 views

Creating your own SF Symbol - for unfound emoji?

I've been looking all around SF Symbols - I can find symbols for lungs - nose - bunny - all kinds of things but no SF Icon for the emoji i want Is there a way to create my own SF Symbol ? For my use ...
Aristidios's user avatar
1 vote
1 answer
86 views

What password is sent when a router does not have a password set?

I promise this is not a hypothetical question. I am trying to use this GitHub repo - https://github.com/braineo/airport-bssid The latest OS X version does not allow specifying the BSSID so I am using ...
Dev's user avatar
  • 21
0 votes
2 answers
4k views

Installing cocoapods to macOS Catalina

In my mac mini I've running Catalina 10.15.7. I've also installed Xcode 12.4. Now as I'm using third party library I'm trying to install cocoapods in my mac. So I used this - sudo gem install ...
mefahimrahman's user avatar
1 vote
0 answers
328 views

Unable to receive packets onto utun interface?

I'm using the NetworkExtension framework to create a virtual utun interface. My application receives packets from a client and the application writes the packet into the utun interface. Since I have ...
SunflowerNetworks's user avatar
2 votes
1 answer
822 views

How can I read the battery level of a MacBook in Swift?

I have seen many post here/on SO and many docs on Apple's website about reading the battery level on iOS, but what's the best way to do this on a MacBook? In the past the only way I've found to do ...
Pixelated Fish's user avatar
2 votes
2 answers
311 views

A website to upload my ios app that anyone can download

Hi there I am looking for a website to upload my ios app(with swift) there and get it's link so that anyone can download it through the link. thanks for your help :)
Bardia Modaberi's user avatar
1 vote
3 answers
1k views

Getting Latest Version of Swift

I’m starting to learn Swift, and have tried the Swift shell. I notice that it is Apple Swift version 5.1.3 . I though it was up to 5.2 by now. How do I get the latest version of Swift on my MacOS? Is ...
Manngo's user avatar
  • 3,535
3 votes
1 answer
5k views

Is there a way to prevent predictive text from learning what the user typed

I want to prevent predictive text from being stored on the iOS device. Is there a way to do it? If I turn off predictive text, the app doesn't show the predictive text toolbar, but it still learns the ...
Frank Lau's user avatar
0 votes
2 answers
48 views

Are there any guidelines by Apple on what content apple TV app should have

We are in the process of developing app for Apple TV, are there any guidelines that app should be either a video playing or gaming app, can I submit app with just readonly content like an iOS app and ...
prasad's user avatar
  • 101
1 vote
1 answer
2k views

Cheapest mac for latest xcode? [closed]

I am doing a uni course which is called iPhone Software Engineering and it says that I need a mac that is able to run latest version of 'Xcode' for app developement and current SWIFT and the Apple iOS ...
Sabih's user avatar
  • 11
3 votes
1 answer
337 views

Upgrade Swift without upgrading MacOS X

I am currently using Mac OS Sierra 10.12.6. I cannot upgrade to a more recent OS version as the business applications I am using for WFH will not work. The default swift installed is 3.1. I want to ...
CurveGamma's user avatar
2 votes
1 answer
1k views

App for macOS to add words to personal vocabulary list?

I search for a way to add unknown words in a personal dictionary or vocabulary list only by right-clicking the word and choosing the add option (in macOS). It would be very helpful for me to add the ...
Shervin's user avatar
  • 23
1 vote
1 answer
550 views

Swift Playgrounds on MacOS performs badly, spinning up the fans and working the CPU

Using the basic "Learn to Code 1" playground results in the MacBooks that I've tested on, including a 2020 MacBook Air, working far harder than I'd expect. The fans spin up and the CPU usage increases ...
David B's user avatar
  • 121
2 votes
1 answer
1k views

Where to find the keychain stored by KeychainSwift

I use KeychainSwift to store my user's keychain data using my created iOS app. The question is: Where can I see the data it stored? I already tried going to Settings -> Password & ...
Dylan's user avatar
  • 123
0 votes
1 answer
223 views

Core Graphics or SpriteKit? [closed]

I'm a junior iOS Developer and I have the requirements for a drawing app I need to build for my employee. I need to be able to add graphic elements on the canvas on different layers. These elements ...
Toto's user avatar
  • 87
0 votes
2 answers
6k views

xCODE 11.3.1 - Failed to create provisioning profile

I'm trying to create a project, which will run on the xCODE's simulator, not on an iPhone. Right after the project is created, there are multiple errors. The first one is: Failed to create ...
random's user avatar
  • 19
1 vote
0 answers
193 views

Modify iTunes library from a script

In my project, I have a bunch of music tracks in a directory of my computer. I want to add them to my iTunes library in an automated way. I also want to group them in playlists depending on the ...
SinLey's user avatar
  • 11
1 vote
1 answer
3k views

In iOS: Can my app launch another app and get a response/acknowledgement back? [closed]

In iOS, is there anyway i can launch another app to do something and then get a response back saying that it’s done. For example: My iOS app APP A launches another app APP B (e.g. Google Pay) to make ...
Vishnu Rana's user avatar
3 votes
1 answer
3k views

Mac swift process blocks system, high memory pressure

Recently, since XCode 11 when I use it, builds and indexes grab a lot of memory. Activity monitor shows a process (it seems like it does so when indexing or building files) called swift and my Mac ...
Cristian Bănărescu's user avatar
0 votes
1 answer
67 views

Tools, languages, libraries and API's for development of a MacOS wide application [closed]

Please just assume that the user has accepted whatever permission are required. Is it possible to listen to window actions under MacOS? In Swift preferably? For instance, if a window moves, is ...
mjs's user avatar
  • 258
4 votes
1 answer
268 views

VoiceOver reading results of Swift Playground print statements in Xcode

(By way of background I have been helping a local blind child learn coding. He's switching schools from a Windows based school to a Mac based school so I am trying to familiarise myself with VoiceOver ...
dumbledad's user avatar
  • 179
1 vote
0 answers
92 views

iOS Newsstand app background mode [closed]

Does Apple still support Newsstand apps? I searched a lot but I can't find any tutorial or a demo for such an app with NewsstandKit. If this is not used anymore, why does the Newsstand background ...
Bathant Hegazy's user avatar
0 votes
1 answer
359 views

Why when I make a change to a project on xcode the previous project is affected? [closed]

I recognize that I'm new in using Xcode but I noticed A very strange behavior from XCODE, when I clone a project and I make changes in the Localizable.strings. these changes are automatically ...
AndroPro's user avatar
1 vote
1 answer
109 views

Do you need a Macbook Pro w touchID to test the authentication in your Swift app?

I'm thinking of buying a MBP base model for Swift programming, and I know that Xcode has a simulator for the touch-bar, but do I need the one with actual touchID hardware if I want my app to require a ...
Michel Buron's user avatar
1 vote
1 answer
230 views

Can I lock my app until user give me a permission (like location permission)?

I am developing an app and I am highly in need of location services and without that my app is not working. Can I block users from using my app (showing a page to them) until they go to settings and ...
aakpro's user avatar
  • 121