Message Boards Message Boards

0
|
7717 Views
|
2 Replies
|
0 Total Likes
View groups...
Share
Share this post:

Private Permissions to Cloud Applications

Posted 9 years ago

I want to deploy an application to the Wolfram Programming Cloud set up with private permissions. I have been testing this functionality and getting behaviors I can't explain or overcome.

The model I'm using is from the help "Wolfram Language How To" -- "How to Set Cloud Object Permissions" - CloudDeploy[APIFunction[{"x" -> "Integer"}, #x^#x &], Permissions -> {{"user@email.com"} -> "Execute"}]

For my testing purposes, I have simplified the example while maintaining the same syntax -- CloudDeploy["Hello", Permissions -> {{“gmailuser@gmail.com"} -> "Execute"}]

For this purpose, I set up a free Cloud account using gmailuser@gmail.com for that purpose. (NB: I am not showing the actual email. "gmailuser@gmail.com" is a dummy for the purposes of this post.

I'm running this in a notebook using Mathematica 10.0.2.0 on Yosemite. I am logged into my Cloud account using my primary Wolfram user ID.

In testing this functionality I always begin by quitting the kernel. The first time I run the Deploy function I get this error -- "StringJoin::string: String expected at position 2 in user-<>None. >>" and I also get a CloudObject[URL] as output.

Interestingly, if I quit the kernel and run CloudDeploy[APIFunction[{"x" -> "Integer"}, #x^#x &], Permissions -> {{"user@email.com"} -> "Execute"}], in the "How To" notebook I get the same "StringJoin" error along with a URL.

The second time the Deploy function runs, there is no "StringJoin" error.

With regard to the URLs that are returned:

I paste them into a "new Private Window". As expected, a sign in box is returned requesting Wolfram ID and Password.

However, after entering The Wolfram ID and password (I am using as ID the email above -- "gmailuser@gmail.com").

The following message is always returned: “Something Went Wrong” “Oops. An error occurred. Please try again.” "If you continue to experience problems, please contact us."

I know the password is correct because if I enter the incorrect password, I am told that the account is not recognized.

This is a threshold issue I would like to get past before investing a lot of development time.

I would appreciate any thoughts? Thanks.

POSTED BY: Robert Fine
2 Replies

Are you still seeing this problem today? I think that there were some recent issues with the cloud servers. I tried the following, and it worked just fine with my accounts (note that I deleted the apifunction, so it's url won't work):

In[1]:= CloudConnect["chadk@wolfram.com", "xxx"]
Out[1]= "chadk@wolfram.com"

In[2]:= co = 
 CloudDeploy[APIFunction["x" -> "Number", #x + 1 &], 
  Permissions -> {"user@gmail.com" -> "x"}]
Out[2]= CloudObject["https://www.wolframcloud.com/objects/287f4f2e-\
90c3-402d-a732-2f5e9e54f4af"]

In[3]:= URLExecute[co, {"x" -> 3}]
Out[3]= 4

In[4]:= CloudConnect["user@gmail.com", "xxx"]
Out[4]= "user@gmail.com"

In[5]:= URLExecute[co, {"x" -> 3}]
Out[5]= 4
POSTED BY: Chad Knutson
Posted 9 years ago

Thanks for the response.

The behavior that is problematic is when user@gmail.com, who has a free cloud account, is not logged into that account and pastes the generated url into a browser (I have tried Safari, Chrome, and IE).

A Sign-in screen appears and I fill in the required credentials and click "Sign-In": enter image description here

However, the "Hello" page is not returned. Rather I get this error page: enter image description here

Interestingly, I have realized that this action has in fact logged user@gmail.com into his Wolfram Programming Cloud account. So that next time the url is run in the browser "Hello" appears in Programming Cloud desktop.

enter image description here

My preference is to have the user be able to cleanly log into my cloud application without having previously logged into his cloud account.

Is this possible.

POSTED BY: Robert Fine
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract