-
-
Notifications
You must be signed in to change notification settings - Fork 4.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cloud code returning {"code":209,"message":"invalid session token"} Google Login; #3003
Comments
Now able to register new user Server Log verbose: RESPONSE from [PUT] /server/classes/User/1hc7eZ3fo6: { but still not able to login with existing or this newly created user. |
This is the Server response while Login: |
You should probably use the 'native' method now. |
Hi flovilmart can you tell more about this |
Now i have implemented Google signup/login with OAuth provided by Parse-Server. |
which is version of parse-server supported Google signup/login with OAuth ? I see not on Docs |
I have upgrade server form 2.2.21 to 2.2.24 and it is working fine for me now. |
It's been supported for a while now. |
I have implemented google+ login with Parse.com by the Cloud code with the reference of https://groups.google.com/forum/#!topic/parse-developers/UUvTreGYOrI. Now our Parse app (Parse-server) is migrated to Heroku.
Login and signup with Email and password , with Facebook and with Twitter is working properly.
I have added ParseUser.enableRevocableSessionInBackground(); after the initialization of Parse for session migration (https://parse.com/tutorials/session-migration-tutorial) to migrate users session to revocable session .
With Google+ Signup/Login my app getting crashed, with some server logs i have found that sessionToken getting undefined which is required for ParseUser.becomeInBackground() for registering user.
Edit 1:
Now I have able to register new user without any error and getting session started with r: but login is still is not working for existing and newly created user.
I have already check following ref. but get nothing specific.
My App is already live on both Android and iOS platforms and now i want to migrate legacy sessions to improved revocable session, but now stuck on the undefined response from cloud code.
Expected Results
[sessionToken]
Actual Outcome
[undefined]
Environment Setup
Server
Database
Logs/Trace
You can turn on additional logging by configuring VERBOSE=1 in your environment.
[2016-11-03T13:48:13.965095+00:00 app[web.1]: verbose: REQUEST for [GET] /server/classes/_User/GJ2LHh1k6S: {} method=GET, url=/server/classes/_User/GJ2LHh1k6S, host=espressoft-parse-server.herokuapp.com, connection=close, user-agent=node-XMLHttpRequest, Parse/js1.9.1 (NodeJS 5.11.1), accept=/, content-type=text/plain, x-request-id=74772963-ec61-445b-bc21-03f881c4fd00, x-forwarded-for=54.87.78.152, x-forwarded-proto=http, x-forwarded-port=80, via=1.1 vegur, connect-time=1, x-request-start=1478180893972, total-route-time=0, content-length=217,
2016-11-03T13:48:14.067598+00:00 app[web.1]: verbose: RESPONSE from [GET] /server/classes/_User/GJ2LHh1k6S: {
2016-11-03T13:48:14.067601+00:00 app[web.1]: "response": {
2016-11-03T13:48:14.067602+00:00 app[web.1]: "objectId": "GJ2LHh1k6S",
2016-11-03T13:48:14.067603+00:00 app[web.1]: "username": "U7yt5Rolfb0W1/4HULJOe7JsShs8bAVR",
2016-11-03T13:48:14.067604+00:00 app[web.1]: "email": "kushal.aressindia@gmail.com",
2016-11-03T13:48:14.067604+00:00 app[web.1]: "firstName": "Kushal",
2016-11-03T13:48:14.067605+00:00 app[web.1]: "lastName": "Dixit",
2016-11-03T13:48:14.067606+00:00 app[web.1]: "account_type": "g",
2016-11-03T13:48:14.067606+00:00 app[web.1]: "createdAt": "2016-10-05T11:01:15.284Z",
2016-11-03T13:48:14.067607+00:00 app[web.1]: "updatedAt": "2016-10-05T11:01:15.284Z",
2016-11-03T13:48:14.067608+00:00 app[web.1]: "ACL": {
2016-11-03T13:48:14.067609+00:00 app[web.1]: "": {
2016-11-03T13:48:14.067609+00:00 app[web.1]: "read": true
2016-11-03T13:48:14.067610+00:00 app[web.1]: },
2016-11-03T13:48:14.067610+00:00 app[web.1]: "GJ2LHh1k6S": {
2016-11-03T13:48:14.067611+00:00 app[web.1]: "read": true,
2016-11-03T13:48:14.067612+00:00 app[web.1]: "write": true
2016-11-03T13:48:14.067612+00:00 app[web.1]: }
2016-11-03T13:48:14.067613+00:00 app[web.1]: }
2016-11-03T13:48:14.067614+00:00 app[web.1]: }
2016-11-03T13:48:14.067615+00:00 app[web.1]: } objectId=GJ2LHh1k6S, username=U7yt5Rolfb0W1/4HULJOe7JsShs8bAVR, email=kushal.aressindia@gmail.com, firstName=Kushal, lastName=Dixit, account_type=g, createdAt=2016-10-05T11:01:15.284Z, updatedAt=2016-10-05T11:01:15.284Z, read=true, read=true, write=true
2016-11-03T13:48:14.132654+00:00 app[web.1]: verbose: REQUEST for [PUT] /server/classes/TokenStorage/Egvw7pYR11: {} method=PUT, url=/server/classes/TokenStorage/Egvw7pYR11, host=espressoft-parse-server.herokuapp.com, connection=close, user-agent=node-XMLHttpRequest, Parse/js1.9.1 (NodeJS 5.11.1), accept=/*, content-type=text/plain, x-request-id=35692a8e-cddb-4ad0-bda6-8965f32aadae, x-forwarded-for=54.87.78.152, x-forwarded-proto=http, x-forwarded-port=80, via=1.1 vegur, connect-time=1, x-request-start=1478180894118, total-route-time=0, content-length=217,
2016-11-03T13:48:14.528455+00:00 heroku[router]: at=info method=POST path="/server/classes/TokenStorage/Egvw7pYR11" host=espressoft-parse-server.herokuapp.com request_id=35692a8e-cddb-4ad0-bda6-8965f32aadae fwd="54.87.78.152" dyno=web.1 connect=1ms service=408ms status=200 bytes=522
2016-11-03T13:48:14.532305+00:00 heroku[router]: at=info method=POST path="/server/functions/accessGoogleUser" host=espressoft-parse-server.herokuapp.com request_id=b6962a03-325a-4937-9f98-4fdf1b7a3a57 fwd="49.248.139.244" dyno=web.1 connect=1ms service=1149ms status=200 bytes=483
2016-11-03T13:48:14.506716+00:00 app[web.1]: verbose: RESPONSE from [PUT] /server/classes/TokenStorage/Egvw7pYR11: {
2016-11-03T13:48:14.506730+00:00 app[web.1]: "response": {
2016-11-03T13:48:14.506732+00:00 app[web.1]: "updatedAt": "2016-11-03T13:48:14.132Z"
2016-11-03T13:48:14.506732+00:00 app[web.1]: }
2016-11-03T13:48:14.506733+00:00 app[web.1]: } updatedAt=2016-11-03T13:48:14.132Z
2016-11-03T13:48:14.510413+00:00 app[web.1]: Session_Token:undefined
2016-11-03T13:48:14.511265+00:00 app[web.1]: info: Ran cloud function accessGoogleUser for user undefined with:
2016-11-03T13:48:14.511267+00:00 app[web.1]: Input: {"email":"kushal.aressindia@gmail.com","code":"ya29.CjGKAxy9fFeCNYtgI7Gswiug8iIH_rnFTy7RytNtWrsm5rku3CJdyviSiD1AR768Cg31"}
2016-11-03T13:48:14.511268+00:00 app[web.1]: Result: undefined functionName=accessGoogleUser, email=kushal.aressindia@gmail.com, code=ya29.CjGKAxy9fFeCNYtgI7Gswiug8iIH_rnFTy7RytNtWrsm5rku3CJdyviSiD1AR768Cg31, user=undefined
2016-11-03T13:48:14.511886+00:00 app[web.1]: verbose: RESPONSE from [POST] /server/functions/accessGoogleUser: {
2016-11-03T13:48:14.511899+00:00 app[web.1]: "response": {}
2016-11-03T13:48:14.511900+00:00 app[web.1]: } result=undefined]
The text was updated successfully, but these errors were encountered: