{"action":"created","issue":{"url":"https://api.github.com/repos/dgrtwo/ParsePy/issues/126","labels_url":"https://api.github.com/repos/dgrtwo/ParsePy/issues/126/labels{/name}","comments_url":"https://api.github.com/repos/dgrtwo/ParsePy/issues/126/comments","events_url":"https://api.github.com/repos/dgrtwo/ParsePy/issues/126/events","html_url":"https://github.com/dgrtwo/ParsePy/issues/126","id":108902833,"number":126,"title":"select_related needs deserialization support","user":{"login":"Greyvend","id":1615315,"avatar_url":"https://avatars.githubusercontent.com/u/1615315?v=3","gravatar_id":"","url":"https://api.github.com/users/Greyvend","html_url":"https://github.com/Greyvend","followers_url":"https://api.github.com/users/Greyvend/followers","following_url":"https://api.github.com/users/Greyvend/following{/other_user}","gists_url":"https://api.github.com/users/Greyvend/gists{/gist_id}","starred_url":"https://api.github.com/users/Greyvend/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Greyvend/subscriptions","organizations_url":"https://api.github.com/users/Greyvend/orgs","repos_url":"https://api.github.com/users/Greyvend/repos","events_url":"https://api.github.com/users/Greyvend/events{/privacy}","received_events_url":"https://api.github.com/users/Greyvend/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-09-29T16:07:36Z","updated_at":"2015-09-30T14:34:55Z","closed_at":"2015-09-30T05:36:11Z","body":"Here is the snippet that demonstrates the problem.\r\n\r\n    from parse_rest.connection import register\r\n    from parse_rest.datatypes import Object as ParseObject\r\n    \r\n    \r\n    APPLICATION_ID = \"APPLICATION_ID\"  # needs to be valid\r\n    REST_API_KEY = \"REST_API_KEY\"  # needs to be valid\r\n    \r\n    register(APPLICATION_ID, REST_API_KEY)\r\n    \r\n    \r\n    class MainObject(ParseObject):\r\n        pass\r\n    \r\n    \r\n    class RelatedObject(ParseObject):\r\n        pass\r\n    \r\n    \r\n    obj1 = RelatedObject(field1='val1', field2='val2')\r\n    obj1.save()\r\n    obj2 = RelatedObject(field1='val3', field2='val4')\r\n    obj2.save()\r\n    \r\n    array_of_related_objects = [obj1, obj2]\r\n    \r\n    main = MainObject(field1='val1_1', related_objects=array_of_related_objects)\r\n    main.save()\r\n    \r\n    main_objects = MainObject.Query.all().select_related('related_objects')\r\n    assert hasattr(main_objects[0].related_objects[0], 'field1')  # it fails! The type of related_objects is dict, not an Object.\r\n\r\nSo when using `select_related` method the specified attribute doesn't seem to be transformed from raw representation to Object.\r\n"},"comment":{"url":"https://api.github.com/repos/dgrtwo/ParsePy/issues/comments/144431196","html_url":"https://github.com/dgrtwo/ParsePy/issues/126#issuecomment-144431196","issue_url":"https://api.github.com/repos/dgrtwo/ParsePy/issues/126","id":144431196,"user":{"login":"felipe-lavratti","id":4923963,"avatar_url":"https://avatars.githubusercontent.com/u/4923963?v=3","gravatar_id":"","url":"https://api.github.com/users/felipe-lavratti","html_url":"https://github.com/felipe-lavratti","followers_url":"https://api.github.com/users/felipe-lavratti/followers","following_url":"https://api.github.com/users/felipe-lavratti/following{/other_user}","gists_url":"https://api.github.com/users/felipe-lavratti/gists{/gist_id}","starred_url":"https://api.github.com/users/felipe-lavratti/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/felipe-lavratti/subscriptions","organizations_url":"https://api.github.com/users/felipe-lavratti/orgs","repos_url":"https://api.github.com/users/felipe-lavratti/repos","events_url":"https://api.github.com/users/felipe-lavratti/events{/privacy}","received_events_url":"https://api.github.com/users/felipe-lavratti/received_events","type":"User","site_admin":false},"created_at":"2015-09-30T14:34:55Z","updated_at":"2015-09-30T14:34:55Z","body":"Perfect. Glad to help.\n\nOn Wed, Sep 30, 2015 at 2:36 AM, Serge Mosin <notifications@github.com>\nwrote:\n\n> Yes, your change fixes it. Fortunately, @dgrtwo\n> <https://github.com/dgrtwo> already merged it.\n>\n> —\n> Reply to this email directly or view it on GitHub\n> <https://github.com/dgrtwo/ParsePy/issues/126#issuecomment-144286846>.\n>\n\n\n\n-- \nSkype: felipeanl\n"}}