{"action":"opened","issue":{"url":"https://api.github.com/repos/MongoEngine/mongoengine/issues/1257","repository_url":"https://api.github.com/repos/MongoEngine/mongoengine","labels_url":"https://api.github.com/repos/MongoEngine/mongoengine/issues/1257/labels{/name}","comments_url":"https://api.github.com/repos/MongoEngine/mongoengine/issues/1257/comments","events_url":"https://api.github.com/repos/MongoEngine/mongoengine/issues/1257/events","html_url":"https://github.com/MongoEngine/mongoengine/issues/1257","id":142444325,"number":1257,"title":"Can not save a Point into EmbeddedDocument","user":{"login":"juan-castano","id":2505605,"avatar_url":"https://avatars.githubusercontent.com/u/2505605?v=3","gravatar_id":"","url":"https://api.github.com/users/juan-castano","html_url":"https://github.com/juan-castano","followers_url":"https://api.github.com/users/juan-castano/followers","following_url":"https://api.github.com/users/juan-castano/following{/other_user}","gists_url":"https://api.github.com/users/juan-castano/gists{/gist_id}","starred_url":"https://api.github.com/users/juan-castano/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/juan-castano/subscriptions","organizations_url":"https://api.github.com/users/juan-castano/orgs","repos_url":"https://api.github.com/users/juan-castano/repos","events_url":"https://api.github.com/users/juan-castano/events{/privacy}","received_events_url":"https://api.github.com/users/juan-castano/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-03-21T19:17:53Z","updated_at":"2016-03-21T19:17:53Z","closed_at":null,"body":"I'm using python3 and I'm trying to save a Point using code below:\r\n\r\n```\r\nfrom mongoengine import StringField, PointField, \\\r\n                        EmbeddedDocument, Document, EmbeddedDocumentField\r\n\r\n\r\nclass Location(EmbeddedDocument):\r\n    name = StringField()\r\n    point = PointField()\r\n\r\n    def __str__(self):\r\n        self.name\r\n\r\n\r\nclass Person(Document):\r\n    name = StringField()\r\n    location = EmbeddedDocumentField(Location)\r\n\r\n    def __str__(self):\r\n        return self.name\r\n```\r\n\r\nOn console try this:\r\n\r\n```\r\n>>> location = Location()\r\n>>> location.name = \"Arroz\"\r\n>>> location.point = {\"type\": \"Point\", \"coordinates\": [12,22]}\r\n>>> person = Person()\r\n>>> person.name = \"Juan\"\r\n>>> person.location = location\r\n>>> person.save()\r\n```\r\nBut launch an except:\r\n`\r\nmongoengine.errors.OperationError: Could not save document (location object expected, location array not in correct format)`"}}