You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Your demo and blogs on CaptureExtension have been super helpful for me developing my extension ❤️.
But, on this given issue, I didn't think the reason that the main App was terminated is that it doesn't start a capture session when launched. Actually it is because the AVCaptureEventInteraction was not added to the window.
With executing these let view = await WidgetControlIntentDependency.shared.getAVCaptureEventInteractionHoldingView() if let vc = UIViewController.topMost, let view = view { vc.view.addSubview(view) view.frame = .init(origin: .zero, size: .zero) }
the main App would not be terminated by the system under any circumstances.
Thanks for sharing. I just tested on this PR by removing the viewModel.setupTemperaryCameraSession() line which setup a temporary camera session.
Since once the AVCaptureEventInteraction is setup, it will no longer be removed. But I find that the main app will still be terminated in the following steps:
Launch the main app, put it in the settings page.
Go to the home screen.
Press Camera Control to launch the app.
Stay in the settings page, and a few seconds later, it will be terminated.
Currently I am using iOS 18.3.1, but I think Apple still doesn't fix this issue yet.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR demonstrates and provides a workaround for this issue:
https://developer.apple.com/forums/thread/769024#769024021