Post

Replies

Boosts

Views

Activity

Running under Parallels crashes XCode apps
I created a fresh SwiftUI project and added a button with no code. I built and ran the app and clicked the do nothing button. My app promptly crashed with the following complaint: validateComputeFunctionArguments:830: failed assertion `Compute Function(ciKernelMain): writes texture ([0]) whose usage (0x00) doesn't specify MTLTextureUsageShaderWrite (0x02)' Since the only unusual is that I am running under Parallels virtualization, it implies a conflict between it and a simple swift build.
5
1
993
Dec ’22
User’s home folders are not being seen as actual folders
Running a MacOS Intel app from XCode 14.1, trying to access the user’s home folders, in this case, the ~/Downloads folder. I get directoryEnumerator error at file:///Users/maurice/Library/Containers/com.utilitybeltsoftware.icloudstatus2/Data/Downloads/: Error Domain=NSCocoaErrorDomain Code=256 "The file “Downloads” couldn’t be opened." UserInfo={NSURL=file:///Users/maurice/Library/Containers/com.utilitybeltsoftware.icloudstatus2/Data/Downloads/, NSFilePath=/Users/maurice/Library/Containers/com.utilitybeltsoftware.icloudstatus2/Data/Downloads, NSUnderlyingError=0x6000011b2880 {Error Domain=NSPOSIXErrorDomain Code=20 "Not a directory"}} If I cd to this location, I do get access to the ~/Downloads folder, so the error is not telling the truth. Here is my entitlements plist <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <plist version="1.0"> <dict> <key>com.apple.security.app-sandbox</key> <true/> <key>com.apple.security.files.downloads.read-only</key> <true/> <key>com.apple.security.temporary-exception.files.home-relative-path.read-only</key> <array> <string>/Documents/</string> <string>/Desktop/</string> </array> <key>com.apple.security.files.user-selected.read-only</key> <true/> </dict> </plist> By the way, I don’t get prompted to grant access to the app and that seems suspicious.
3
0
1.7k
Dec ’22
Is there a programmatic way to know the icloud status of a given local file?
The Finder displays the iCloud status (in the cloud, downloading, local) of every file associated with iCloud. How does it do this? Is there a way to search a given local folder and discover what the Finder knows? Is there a way to tell it programmatically to download any icloud files that aren’t downloaded?
1
0
1.9k
Nov ’22
My client has been booted from App Store Connect
My client was apparently setup as an internal tester, and they got a message that their App Store Connect account had been deactivated for reasons unknown. Apparently to re-activate it, they have to provide "passport" info, which seems over the top. I thought about setting them up as an external tester, but apparently this requires the app be reviewed by a person who would have no access to the app's login as it restricted to the client. How can I proceed?
1
0
132
Nov ’25
Why is ScreenCaptureKit throttled to about 7 fps?
I have an app that records a 32 x 32 rect under the cursor as the user moves it around and it sends it to Flutter. It suffers from major lag. Instead of getting 30 fps, I get about 7 fps. That is, there are significant lags between screen grabs. This on an Intel Mac mini x64 with 15.7.3 and one display. flutter: NATIVE: ExplodedView framesIn=2 timeSinceStart=1115.7ms gapSinceLastFrame=838.8ms flutter: NATIVE: ExplodedView framesIn=4 timeSinceStart=1382.6ms gapSinceLastFrame=149.9ms flutter: NATIVE: ExplodedView framesIn=5 timeSinceStart=1511.0ms gapSinceLastFrame=128.4ms flutter: NATIVE: ExplodedView framesIn=7 timeSinceStart=1698.3ms gapSinceLastFrame=102.9ms flutter: NATIVE: ExplodedView STOP polling totalTime=4482.6ms framesIn=28 framesSent=28 acks=28 Here's a testable excerpt: import ScreenCaptureKit import CoreMedia import CoreVideo import QuartzCore final class Test: NSObject, SCStreamOutput, SCStreamDelegate { private let q = DispatchQueue(label: "cap.q") private var stream: SCStream? private var lastFrameAt: CFTimeInterval = 0 private var frames = 0 func start() { SCShareableContent.getExcludingDesktopWindows(false, onScreenWindowsOnly: true) { content, err in guard err == nil, let display = content?.displays.first else { print("shareableContent error: \(String(describing: err))"); return } let filter = SCContentFilter(display: display, excludingWindows: []) let config = SCStreamConfiguration() config.showsCursor = false config.queueDepth = 1 config.minimumFrameInterval = CMTime(value: 1, timescale: 30) config.pixelFormat = kCVPixelFormatType_32BGRA config.width = 32 config.height = 32 config.sourceRect = CGRect(x: 100, y: 100, width: 32, height: 32) let s = SCStream(filter: filter, configuration: config, delegate: self) try! s.addStreamOutput(self, type: .screen, sampleHandlerQueue: self.q) self.stream = s s.startCapture { startErr in print("startCapture err=\(String(describing: startErr))") } // Optional: move sourceRect at 30Hz (cursor-follow simulation) Timer.scheduledTimer(withTimeInterval: 1.0/30.0, repeats: true) { _ in let c2 = SCStreamConfiguration() c2.showsCursor = false c2.queueDepth = 1 c2.minimumFrameInterval = CMTime(value: 1, timescale: 30) c2.pixelFormat = kCVPixelFormatType_32BGRA c2.width = 32 c2.height = 32 let t = CACurrentMediaTime() c2.sourceRect = CGRect(x: 100 + (sin(t) * 50), y: 100, width: 32, height: 32) s.updateConfiguration(c2) { _ in } } } } func stream(_ stream: SCStream, didOutputSampleBuffer sb: CMSampleBuffer, of type: SCStreamOutputType) { guard type == .screen else { return } let now = CACurrentMediaTime() let gapMs = (lastFrameAt == 0) ? 0 : (now - lastFrameAt) * 1000 lastFrameAt = now frames += 1 if frames <= 10 || frames % 60 == 0 { print("frames=\(frames) gapMs=\(String(format: "%.1f", gapMs))") } } }
0
0
118
Dec ’25