Posts

Sort by:
Post not yet marked as solved
0 Replies
4 Views
Hello, I'm trying to simulate miscellaneous crashes to test my handlers. Things works as expected with NSException and C++ exceptions, however I cannot find a way to trig a C signal. I tried with this code: NSArray *runningApplications = [NSRunningApplication runningApplicationsWithBundleIdentifier:@"com.myCompany.myApp"]; NSRunningApplication *app = runningApplications[0]; UInt32 pid = [app processIdentifier]; kill(pid, SIGABRT); It is caught by my handler, but it doesn't crash the app (although it's detached from the debugger), I can even continue using the app normally. I'm wondering if this could be related to something wrong in my handler (especially on how it ends): signal(sig, SIG_IGN); dispatch_source_t source = dispatch_source_create(DISPATCH_SOURCE_TYPE_SIGNAL, sig, 0, dispatch_get_global_queue(0, 0)); dispatch_source_set_event_handler(source, ^{ // I write some logs on disk here, then uninstall the handlers associated with this or that signal: for(int i=0; i<SignalSourceCount; i++) { if (_signalSources[i]) { dispatch_source_cancel(_signalSources[i]); _signalSources[i] = NULL; } } }); dispatch_resume(source); I've seen some examples finishing rather with exit() or abort(). Abort crashes the app as expected, however the Crash Report produced by Apple then focuses on the handler instead of the code triggering the signal... Any help appreciated, thanks
Posted
by
-dp
Post not yet marked as solved
0 Replies
4 Views
Since April 30 (yesterday as of this writing) Xcode Cloud builds are failing randomly, usually citing an internal Apple network failure. NSLocalizedDescription=Communication with Apple failed, NSLocalizedRecoverySuggestion=A non-HTTP 200 response was received (502) for URL https://developerservices2.apple.com/services/QH65B2/listTeams.action?clientId=XABBG36SBA Because of this network failure, the build cannot fetch my app ID NSLocalizedDescription=Capabilities for bundle ID "Twine" could not be fetched. Please file a bug report at https://feedbackassistant.apple.com and include the Update Signing report from the Report navigator., IDEDistributionIssueSeverity=3 This is a multi platform app, iOS, macOS, and visionOS. Usually one or two platforms will succeed, with one or two failing. From build to build, with no source changes, the successful platform randomly changes. But I never get a complete build.
Posted
by
Post not yet marked as solved
0 Replies
6 Views
CoreData: Zone metadata is missing it's encoded share data but is marked for a mutation: <CKRecordZoneID: 0x600003f044e0; zoneName=com.apple.coredata.cloudkit.share.30BE5FAE-3FE0-4142-90C4-E78FFA90B2A2, ownerName=defaultOwner> - <decode: bad range for [%@] got [offs:312 len:1242 within:0]>
Posted
by
Post not yet marked as solved
0 Replies
13 Views
When the content exceeds 40 lines of text, crazy behaviour starts to happen. The content jumps up and down while typing. Is there any other way to implement simple editor that can handle around 200 lines without this crazy behaviour?
Posted
by
Post not yet marked as solved
0 Replies
13 Views
In App Store Connect, is an organization's Legal Entity name separate from the App Store display name? My organization currently has the same name for both App Store display name and Legal Entity name. It contains an apostrophe, which is desired on the App Store for brand consistency. However, an apostrophe is no longer permitted in the Legal Entity name (it was entered in before that restriction came into effect). If I remove the apostrophe from the Legal Entity name to satisfy compliance warnings, will that update the App Store display name as well? I ask here because I'm supposing that if I remove the apostrophe and it does update the display name, the input validation won't let me enter it back. Any help would be appreciated - thanks!
Post not yet marked as solved
0 Replies
21 Views
I have a container view implementation that reads preference values from child views: public struct Reader<Content>: View where Content: View { public var content: () -> Content public init(@ViewBuilder content: @escaping () -> Content) { self.content = content } public var body: some View { content() .onPreferenceChange(NumericPreferenceKey.self) { value in // ... } } } This works fine until the content passed in to the container view is a Group. At that point the onPreferenceChanged modifier is applied to every child of the group, which leads to bugs in my situation. One thing I can do is simply put the content in a VStack: public var body: some View { VStack(content: content) .onPreferenceChange(NumericPreferenceKey.self) { value in // ... } } And that works fine to "Ungroup" before applying the onPreferenceChanged modifier. However, is this best practice? Is there a better way to apply a modifier to content as a whole instead of to each member of a potential group? Is it concerning that I might have an extra VStack in the view hierarchy with this fix?
Posted
by
Post not yet marked as solved
0 Replies
16 Views
I'm running into this error, when the underlying SwiftData object changes (gets an object added to it): *" A NavigationLink is presenting a value of type “Project” but there is no matching navigationDestination declaration visible from the location of the link. The link cannot be activated. Note: Links search for destinations in any surrounding NavigationStack, then within the same column of a NavigationSplitView. "* For instance, when I first fire up the simulator, clicking on any existing project correctly takes me to its details page. However, as soon as I add a new project or delete a project, none of the navigation links work any more. If I reload the simulator, they all work again! Makes me suspect it's an error with not recomputing the links when the underlying data change, but I can't figure out what I need to change, as everything looks correct. Any help would be appreciated! ContentView: struct ContentView: View { @Environment(\.modelContext) var modelContext @Query(sort: \Project.endDate) var projects: [Project] var body: some View { NavigationStack { Group { if projects.isEmpty { ContentUnavailableView("Enter your first project.", systemImage: "clipboard") } else { List { ForEach(projects, id: \.id) { project in NavigationLink(value: project) { HStack { DaysTile( days: project.numWorkDaysNowUntilEnd, description: "Work Days Remaining" ) .padding(.trailing, 5) VStack(alignment: .leading) { Text(project.name) .font(.title) Text("Start: \(project.startDate.formatted(date: .abbreviated, time: .omitted))") .foregroundStyle(.secondary) Text("End: \(project.endDate.formatted(date: .abbreviated, time: .omitted))") .foregroundStyle(.secondary) } } } } .onDelete(perform: deleteProjects) } .navigationDestination(for: Project.self) { project in ProjectDetailView(project: project) } } } .navigationTitle("Project Tracker") .toolbar { NavigationLink { AddProjectView() } label: { Label("Add New Project", systemImage: "plus") } } } } func deleteProjects(at offsets: IndexSet) { for offset in offsets { let project = projects[offset] modelContext.delete(project) } } } #Preview { ContentView() .modelContainer(for: Project.self, inMemory: true) }
Posted
by
Post not yet marked as solved
0 Replies
14 Views
I can't find a way to download a USDZ at runtime and load it into a Reality View with Reality kit. As an example, imagine downloading one of the 3D models from this Apple Developer page: https://developer.apple.com/augmented-reality/quick-look/ I think the process should be: Download the file from the web and store in temporary storage with the FileManager API Load the entity from the temp file location using Entity.init (I believe Entity.load is being deprecated in Swift 6 - throws up compiler warning) - https://developer.apple.com/documentation/realitykit/loading-entities-from-a-file Add the entity to content in the Reality View. I'm doing this at runtime on vision os in the simulator. I can get this to work with textures using slightly different APIs so I think the logic is sound but in that case I'm creating the entity with a mesh and material. Not sure if file size has an effect. Is there any official guidance or a code sample for this use case?
Posted
by
Post not yet marked as solved
0 Replies
17 Views
Hi all. I really dont know if this is the place for this question. Shortly, when i go to https://developer.apple.com/account and click "Enroll today" - nothing happens. There's no error in the console, just a 302 redirect to developer.apple.com/account. Is this like a bug or is there something else i need to do?
Posted
by
Post not yet marked as solved
0 Replies
11 Views
I am implementing pan and zoom features for an app using a custom USB camera device, in iPadOS. I am using an update function (shown below) to apply transforms for scale and translation but they are not working. By re-enabling the animation I can see that the scale translation seems to initially take effect but then the image animates back to its original scale. This all happens in a fraction of a second but I can see it. The translation transform seems to have no effect at all. Printing out the value of AVCaptureVideoPreviewLayer.transform before and after does show that my values have been applied. private func updateTransform() { #if false // Disable default animation. CATransaction.begin() CATransaction.setDisableActions(true) defer { CATransaction.commit() } #endif // Apply the transform. logger.debug("\(String(describing: self.videoPreviewLayer.transform))") let transform = CATransform3DIdentity let translate = CATransform3DTranslate(transform, translationX, translationY, 0) let scale = CATransform3DScale(transform, scale, scale, 1) videoPreviewLayer.transform = CATransform3DConcat(translate, scale) logger.debug("\(String(describing: self.videoPreviewLayer.transform))") } My question is this, how can I properly implement pan/zoom for an AVCaptureVideoPreviewLayer? Or even better, if you see a problem with my current approach or understand why the transforms I am applying do not work, please share that information.
Posted
by
Post not yet marked as solved
0 Replies
25 Views
In our implementation of Platform SSO, we would like to show custom UI in both the beginDeviceRegistration call as well as the beginUserRegistration call. It works fine in the beginDeviceRegistration call when we use presentRegistrationViewController. When we try to apply the same logic in beginUserRegistration, the ViewController's view.window object is nil and thus using it to house our custom UI doesn't work. I'm not sure if this is an implementation flaw on our part or if presentRegistrationViewController is only intended to be used in beginDeviceRegistration. The call is only mentioned in the context of registering devices, which makes us wonder if it is limited to that. Any help would be appreciated!
Posted
by
Post not yet marked as solved
0 Replies
20 Views
Hello. I am trying to enable Metal to take advantage of SwiftUI+Shaders in an existing app. In my target, I have added metal.framework, added a .metal file and confirmed I see the Metal Compiler option in my Build Settings. When I add a colorEffect modifier using the ShaderLibrary, the object renders black. I confirmed this is working in a new project so I suspect there are more steps required to get this working in an existing application.
Posted
by
Post not yet marked as solved
0 Replies
19 Views
Hi, I'm trying to get IMessage to display a video as part of a link preview with specific dimensions. The video appears, however the dimensions are incorrect. I've set the following tags: <meta property="og:video:url" content={url} /> <meta property="og:video:secure_url" content={url} /> <meta property="og:video:width" content="600" /> <meta property="og:video:height" content="982" /> The video in question is 600x982, 1.1MB in size and an mp4. I've also tried setting the og dimensions to 390x736 since a separate working example url has those, but no luck. Does anyone know what may be the issue?
Posted
by
Post not yet marked as solved
0 Replies
20 Views
I'm trying to read meta information from MXF files without success. I get an empty AVAsset array. I saw that there are mentions of "MTRegisterProfessionalVideoWorkflowFormatReaders". But there is absolutely no documentation. I don't know where to look. Has anyone encountered this? Please help with any information
Posted
by
Post not yet marked as solved
0 Replies
21 Views
So in looking over the app review guidelines, where it reads, "They may not auto-launch or have other code run automatically at startup or login without consent" We currently present a popup to inform the user if they want to connect to our server. My question is, are we able to provide the user with a way to turn off this startup prompt (thus improving speed of app startup) It would be located within our apps own settings page, upon which the user would have the choice to turn off or leave on this startup prompt. Or would this go against apple's policy in any way?
Posted
by
Post not yet marked as solved
0 Replies
88 Views
During last night, Apple allegedly pushed new XProtect antivirus signatures. After that, I think XProtect found the malware Pirrit in my Xcode Simulator files from Apple. I'm not kidding. This is an excerpt from the XProtect log (notice the NSFilePath!): 2024-05-01 07:54:12.951 Pirrit 👉 no status_message report time 0.0000000 {"action":"report","path":{"modificationDate":732892166.8634809,"path":"\/Library\/Developer\/CoreSimulator\/Images\/1944D6AF-4D6B-4877-8F87-924EB62FC984.dmg","creationDate":732892166.8634809},"status":{"description":"Error deleting path: \/Library\/Developer\/CoreSimulator\/Images\/1944D6AF-4D6B-4877-8F87-924EB62FC984.dmg: Error Domain=NSCocoaErrorDomain Code=513 \"“1944D6AF-4D6B-4877-8F87-924EB62FC984.dmg” couldn’t be removed because you don’t have permission to access it.\" UserInfo={NSUserStringVariant=(\n Remove\n), NSFilePath=\/Library\/Developer\/CoreSimulator\/Images\/1944D6AF-4D6B-4877-8F87-924EB62FC984.dmg, NSUnderlyingError=0x1247612a0 {Error Domain=NSPOSIXErrorDomain Code=1 \"Operation not permitted\"}}.","causedBy":[],"code":24}} 2024-05-01 07:54:13.197 Pirrit message not in JSON format 2024-05-01 07:54:41.125 Pirrit ⚠️ FailedToRemediate time 0.0000280 {"caused_by":[],"execution_duration":2.8014183044433594e-05,"status_code":24,"status_message":"FailedToRemediate"} XProtect also detects another threat on my machine: 2024-05-01 10:09:58.530 BadGacha ⚠️ ThreatDetected time 0.0000120 {"caused_by":[],"execution_duration":1.2040138244628906e-05,"status_message":"ThreatDetected","status_code":21} Please check your XProtect logs. There is an app that can display these logs out there. Or you can use the system logging facility. I have deleted the whole Developer folders (both at / and ~) and reinstalled Xcode (not Beta). But a new XProtect scan finds Pirrit in the Core Simulator file again! I have also attempted to install an anti virus solution (Malwarebytes), but it does not detect anything. I am wondering if we should get someone from Apple involved. I am also wondering if I should reset my whole machine… Is anyone else seeing these issues in the XProtect log? It is unclear at this time whether there really is a Pirrit malware in Apple's Xcode simulator files or if there is some issue with XProtect like a faulty signature. Don't panic.
Posted
by
Post not yet marked as solved
1 Replies
44 Views
Hi, do you guys have any idea why this code block doesn't run properly on a designed iPad app running on a vision pro simulator? I'm trying to add a hovering effect to a view in UIKit but it just doesn't enter this if statement. if #available(iOS 17.0, visionOS 1.0, *) { someView.hoverStyle = .init(effect: .automatic) }
Posted
by
Post not yet marked as solved
0 Replies
32 Views
Hello, i am trying to record logs in my network extension class, and then i want to read it in my application class, i.e. viewModel. However, i am unable to read the data. I have tried different ways like UserDefaults, Keychain, FileManager, NotificationCenter and CoreData. I have also used Appgroups but still there is blocker for reading data outside the scope of Extension class.
Posted
by

TestFlight Public Links

Get Started

Pinned Posts

Categories

See all