Skip to content

Cloud code broken in 2.2.7 #1579

Closed
Closed

Description

@antonfire

Check out this issue for an ideal bug report. The closer your issue report is to that one, the more likely we are to be able to help, and the more likely we will be to fix the issue quickly!

For implementation related questions or technical support, please refer to the Stack Overflow and Server Fault communities.

Make sure these boxes are checked before submitting your issue -- thanks for reporting issues back to Parse Server!

Environment Setup

elastic beanstalk
mongodb
parse server 2.2.7

Steps to reproduce

I was running 2.1.6 and just upgraded to 2.2.7, on 2.1.6 everything was running fine. In cloud code I was retrieving the user Facebook id as follows:

var FBid = request.user.attributes.authData.facebook.id;

Looking at logs it reports that request.user.attributes.authData is undefined.

What has changed?

Thanks

Logs/Trace

See above

Activity

  1. antonfire commented on Apr 21, 2016

    @antonfire
    Author

    It seems that this issue was resolved in #755, but I am experiencing the same problems, have these commits not hit 2.2.7?

  2. steven-supersolid commented on Apr 21, 2016

    @steven-supersolid
    Contributor

    Please see #1568
    This has been fixed and merged so will be in the next release

  3. antonfire commented on Apr 21, 2016

    @antonfire
    Author

    @steven-supersolid Ok great thanks.

  4. miracle7 commented on Apr 22, 2016

    @miracle7

    @steven-supersolid So for now we continue using 2.2.6 and then jump straight to 2.2.8 when it comes out?

  5. drew-gross commented on Apr 22, 2016

    @drew-gross
    Contributor

    Closing as fixed. Please wait for version 2.2.8 if you are seeing this issue.

  6. steven-supersolid commented on Apr 22, 2016

    @steven-supersolid
    Contributor

    2.2.6 has a bug with non-expiring session tokens but if your session tokens don't expire then should be safe to keep using it.

    Can see other changes here in case there were any other bugs fixed that might affect you:
    2.2.6...2.2.7

    If you need a bit more flexibility then you could fork parse-server and choose which commit to work from, then use a git dependency in your package.json to your own repo. You can even then merge your own PR while waiting for PR to be approved in the main repo.

  7. antonfire commented on Jun 4, 2016

    @antonfire
    Author

    @drew-gross It seems this wasn't fixed in 2.2.8. Was this fix accidentally omitted?

  8. antonfire commented on Jun 10, 2016

    @antonfire
    Author

    @steven-supersolid This fix has not been applied, any idea what's happening with it?

  9. steven-supersolid commented on Jun 22, 2016

    @steven-supersolid
    Contributor

    There was a bug with authData being removed from any _User query, and that was fixed. However, I see that you are missing info on request.user.

    We noticed when moving from Parse.com to parse-server that request.user was missing attributes so changed our cloud code to always query/fetch the user when we require attributes. Really this should be fixed to be the same as Parse.com.

    I suggest opening a new issue for this, especially if you have some code or a test that worked in an earlier version of parse-server. I thought I saw a related issue some time ago but can't find it so a new issue would help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions