Goal: import images using SwiftUI .fileImporter modifier, on MacOS Catalyst.
Xcode Version 12.4 (12D4e)
MacOS 11.2.3 (20D91)
Problem: When I lick to import an image, I get the crash bellow:
ERROR: Unable to display open panel: your app is missing the User Selected File Read app sandbox entitlement. Please ensure that your app's target capabilities include the proper entitlements.
Any help is much appreciated! : )
<UIDocumentPickerViewController: 0x7faf38ee9d20> from detached view controller <TtGC7SwiftUI19UIHostingControllerVVS_22_VariadicView_Children7Element: 0x7faf38e9f8e0> is discouraged.
2021-04-13 11:18:03.882067+0200 tStudio[12670:69301] [OpenSavePanels] ERROR: Unable to display open panel: your app is missing the User Selected File Read app sandbox entitlement. Please ensure that your app's target capabilities include the proper entitlements.
Fixed with this. Just go to your target, and check file access as bellow
Related
I have run my Collection.
I have Exported results "***API.postman_test_run.json" file using Export Results option into my local folder:
I closed the Runner tab (Run Summary) on Postman.
And then I tried to open (to Import) this json file somewhere in Postman in order to view these results again and I do not see how I can do that.
My question is - how I can view exported results in Postman?
Is it possible at all or I need to open results in some other application like Visual Studio Code?
Here is an update: I have found the icon Runner in the right bottom part of my Postman desktop.
I clicked on it and got an interface to import the previous collection runs:
However, when I click on button Import I am getting an error: Failed to import collection run.
What could be the reason of it?
Open Postman
Click Import, click Choose Files and specify "***API.postman_test_run.json" from your pc.
-An import success message appears for each collection imported
-Click the Eye icon to setup an Environment
Click Add
-Enter an Environment name. for example, FTAPI
-Copy your API Key from the email sent to you in the previous step
-Enter a Key and a Value
-Click Add
I have written to the Postman Support and got an answer that this issue that I noticed of getting an error on importing of the run results (postman_test_run.json) is the one which exists on Postman. They are working on it now.
I am trying to get a simple SwiftUI iOS custom document app work with Airdrop. The app successfully opens a document when opened from Files or a Mail attachment. However when sending a document of the custom type by Airdrop from my mac, when the app is selected from the Airdrop notification, the app launches but only displays the file browser and the file does not seem to be copied over. No DocumentGroup view is displayed.
If I select Files from the Airdrop menu I can save the file.
I tried this with Apples sample code for DocumentBased apps, and it exhibits exactly the same behavior on my iPhone (iOS 16.0.2). Either this is a bug, or there is some extra secret sauce needed to get a SwiftUI Document app to receive files by Airdrop.
My custom type conforms to public.content, which I understand is required for Airdrop support.
Has anyone managed to get Airdrop reception working with a SwiftUI document app ?
I faced the same issue.
What I found out so far:
1.
Documents which are received via Airdrop are placed in your "Inbox" folder. This directory is located here:
let docUrl = FileManager.default.urls(for: .documentDirectory, in: .userDomainMask).first!
You can add an UIApplicationDelegate and UISceneDelegate to your swiftui application. Here you get a trigger when new files are received via Airdrop.
func scene(_ scene: UIScene, openURLContexts URLContexts: Set<UIOpenURLContext>)
This function is normally trigged when you open your app with a URL in your browser.
I'm waiting for a integrated solution in the DocumentGroup.
https://developer.apple.com/documentation/swiftui/documentgroup
I have an old Superset dashboard which was backed up to JSON and I'm now trying to load into the hosted version of Preset. Other dashboards I've tested have loaded fine but the Preset GUI hangs when loading this one dashboard. There's no error displayed in the Preset GUI. The browser console returns a generic Error: 500. My assumptions are that either there is a cap on the size of the dashboard file that can be uploaded, or else my file is corrupt in some non-obvious way.
Is there a way of getting more detailed information on the error or else of validating the dashboard JSON template prior to upload?
From your description you might be impacted by two bugs that are currently affecting Preset Cloud:
Dashboard Import is not working if Charts excluded from the filters were removed from the Dashboard: This could be causing the 500 you are receiving.
Dashboard import operation dialog hangs when the operation fails: it seems that the import dialog is not throwing an error when it fails.
You can submit a support ticket on Preset Support page so that their support team can confirm if the root-cause is indeed that bug and help you modifying the file to import the Dashboard properly.
I am using Ionic 2 and want to open a PDF file from a remote server using the device's default browser. I have a couple of problems:
First, I am unable to run this on the browser. I get this error:
Native: InAppBrowser is not installed or you are running on a browser. Falling back to window.open.
The ionic docs seem to indicate support for all devices and browsers. Am I doing something wrong or the docs are wrong?
Secondly, when I run the app, the PDF file does not open in the system's default browser but within the app. I am using Ionic View to do the testing. Here is my code:
import { InAppBrowser } from '#ionic-native/in-app-browser';
constructor(public appGlobal: AppGlobal, private iab: InAppBrowser) {
const browser = this.iab.create('www.google.com', '_system');
browser.show();
Also, if I change the URL to my php script that generates and returns a PDF file, it does not work at all.
To use the device's default browser, you don't need to use the IAB. You just need to open a new window with _system. Your device will do the rest.
window.open(url, '_system');
You can also do what you're doing if you want to keep the IPB, just omit the open function.
Adding the _system target means you don't need to do this anymore as it crashes the app.
uninstall inappbrowser plugin and simply try this:
window.open(pdf_url, '_system', 'location=yes');
When you use _system browser, it's not necessary use browser.show()
this.iab.create('www.google.com, '_system');
I'm trying to use window.top.location as the link property when sharing content from an application using the JS SDK. This is an iframe canvas app.
When I send in window.top.location I get the following error:
Error: Permission denied to access property 'toJSON' Source File:
http://connect.facebook.net/en_US/all.js Line: 9
I also tried to pass in the href property of window.top.location but I get a similar error in my own code:
Error: Permission denied to access property 'herf' Source File:
http://localhost:2888/Scripts/quickView.js Line: 65
I'm assuming this is a XSS issue, but I was wondering if there was a way around it. I could always pass the canvas page url to the client from the server, but I would like to see if we can get this working instead.
Appreciate your thoughts on this.
A little late on the follow up, but Shawn eluded to the correct answer. The issue is only present when running the application locally. In a hosted environment I can access this property without issue.