I saved an app to my company's gallery, and when I click run from the gallery to test it, I get the above error.
This is not a workflow result error, this is an error thrown when trying to run the app in the first place. The app never does begin to run, or even load.
The only error I got when saving the app to the gallery while it was validating, is that it couldn't find the file path I'm specifying at the input stage of my directory tools. Which is normal, since it was a path relative to my PC and the server worker does not recognize that. But I don't care about that because I also put in 2 folder browse interface tools, and that "unrecognized" path would be updated with the folders the user selects anyway.
So why is this happening?
Solved! Go to Solution.
I believe that this thread addresses what you are experiencing: https://community.alteryx.com/t5/Alteryx-Server-Knowledge-Base/Folder-Browse-Not-Available-on-Galler...
Can you try this approach as an alternative?
Hi @AkisM
The lack of Directory Browser in the Gallery is annoying, but you can get around it using the following technique
Use a File Browse Interface tool, connected to a Text Input. Have the user select any file in the target directory. The Formula tool gets the directory path from the User's selected file and passes this on for further processing.
The only case where this won't work is when the target directory is empty.
Dan
Thanks @danilang but then how do I connect to the directory tool? It can only take interface inputs as it has no input anchor. My workflow starts with a directory tool, and I'm not sure how to feed a formula tool into that. It needs to start with a directory tool as the user will need to select a path where multiple input files will be located and all of them need to be read into the workflow.
Hi @AkisM
You can use the technique demonstrated on the right
Connect the File Browse interface tool to a directory tool and configure the action tool to "Update Value with Formula" and set the formula to FileGetDir([#1]). This will get the path of the selected file and update the directory in the Directory tool.
Dan
Hi @danilang ,
That does not work either unfortunately when I run the app from the gallery. I pick a file from each directory, but in the output it returns only 2 records (the 2 files I picked) rather than 50+ records which is the total number of files contained in those 2 directories together. Attaching below the relevant excerpt from my workflow for reference.
From what I see in the thread posted by Brandon, this is not possible.
"the complication with files on a user's local machine is that analytical apps are running from the security context of the Server's login. That means that it probably will not have any access to files on a user's machine.
What you can do is to get your users do drop the files they want to work with, on a network location that the server login has permission to access. You can address this using a UNC path like \\servername\share\folder"
Hi @AkisM
Yes. Gallery apps can not read from your local computer. You'll need to have a shared drive that is accessible to the users and service account that runs the gallery.
As for the issue with only the 2 files, it appears that the file browse tool copies the selected files to the staging directory when run from the gallery. That's why only the 2 files show up in the output. This was something that I wasn't aware of. Sorry about the confusion.
Assuming you get the shared drive set up, here's another workaround method that works on my gallery/network.
This one uses the Tree Interface tool configured to use the File system Directory as the source and Single Selection
You'll need to replace \\server\share with the values from your shared Drive
The UI will look something like this in the Gallery
Select one file in each tree. The directory of the 2 selected files will be extracted by the connected action tools and passed to the Directory tools
Dan
I am getting the same error but we do not have folder browse tool in our workflow. Is their any other reason that could cause this error too? We are using file browse tools (more than one) instead.