google-cloud-datastore

Appengine bulk downloader is not downloading list properties

你说的曾经没有我的故事 提交于 2020-02-28 12:31:17
问题 This is related to a previous question of mine, but with new information. I'm trying to configure the bulkdownloader to download data from my Java appengine app in such a way that a list of owned objects is transformed into a nested XML path inside each parent object. I have been using the export transform transform.child_node_from_list . However, the list property is never actually being downloaded and passed to that transform! This seems similar to the effect you get when looking at an

Appengine bulk downloader is not downloading list properties

[亡魂溺海] 提交于 2020-02-28 12:30:28
问题 This is related to a previous question of mine, but with new information. I'm trying to configure the bulkdownloader to download data from my Java appengine app in such a way that a list of owned objects is transformed into a nested XML path inside each parent object. I have been using the export transform transform.child_node_from_list . However, the list property is never actually being downloaded and passed to that transform! This seems similar to the effect you get when looking at an

different entity group on transaction using google-cloud-ndb

↘锁芯ラ 提交于 2020-02-28 09:48:49
问题 I would like to run a transaction operation in Google App Engine using google-cloud-ndb. I deployed this app. Here is my code. # -*- coding: utf-8 -*- from flask import Flask from google.cloud import ndb import time app = Flask(__name__) class Book(ndb.Model): hoge = ndb.IntegerProperty() class Book2(ndb.Model): hoge = ndb.IntegerProperty() @ndb.transactional() def test1(): ent = ndb.Key(Book, "a").get() print("after get: %s", ent) ent.hoge = ent.hoge + 1 ent.put() print("after put: %s", ent)

different entity group on transaction using google-cloud-ndb

自闭症网瘾萝莉.ら 提交于 2020-02-28 09:48:34
问题 I would like to run a transaction operation in Google App Engine using google-cloud-ndb. I deployed this app. Here is my code. # -*- coding: utf-8 -*- from flask import Flask from google.cloud import ndb import time app = Flask(__name__) class Book(ndb.Model): hoge = ndb.IntegerProperty() class Book2(ndb.Model): hoge = ndb.IntegerProperty() @ndb.transactional() def test1(): ent = ndb.Key(Book, "a").get() print("after get: %s", ent) ent.hoge = ent.hoge + 1 ent.put() print("after put: %s", ent)

Using an enum contained in a Cloud Endpoint model on a Android client

折月煮酒 提交于 2020-02-24 12:09:33
问题 I'm trying to implement an enum in a entity called CargoWrapper. In my android app I'm constructing a CargoWrapper object to send to an endpoint method, and then calling my CargoWrapper setters to set the instance varialbes. One of CargoWrappers instance variables is an enum and it's indexed. The only methods generated for my front end are the setter and getters, I can't see the enum. Does anyone know how to set the enum instance variable from a android client, seems like it should be very

Using an enum contained in a Cloud Endpoint model on a Android client

回眸只為那壹抹淺笑 提交于 2020-02-24 12:06:48
问题 I'm trying to implement an enum in a entity called CargoWrapper. In my android app I'm constructing a CargoWrapper object to send to an endpoint method, and then calling my CargoWrapper setters to set the instance varialbes. One of CargoWrappers instance variables is an enum and it's indexed. The only methods generated for my front end are the setter and getters, I can't see the enum. Does anyone know how to set the enum instance variable from a android client, seems like it should be very

Using an enum contained in a Cloud Endpoint model on a Android client

懵懂的女人 提交于 2020-02-24 12:06:31
问题 I'm trying to implement an enum in a entity called CargoWrapper. In my android app I'm constructing a CargoWrapper object to send to an endpoint method, and then calling my CargoWrapper setters to set the instance varialbes. One of CargoWrappers instance variables is an enum and it's indexed. The only methods generated for my front end are the setter and getters, I can't see the enum. Does anyone know how to set the enum instance variable from a android client, seems like it should be very

GAE Datastore - workaround for updating entity?

一世执手 提交于 2020-02-04 07:34:25
问题 Assume: class Contacts(db.Model): first_name = StringProperty() last_name = StringProperty() phone_number = PhoneNumberProperty() new_contact = Contacts(first_name="Homer", last_name="Simpson", phone_number = 1234566) new_contact.put() I am new to GAE Datastore, but per GAE Datastore Docs (see below if interested), i can't modify a single property of the entity (eg, phone_number). I have to re-declare all properties, and then put() the new entity. Omitting previously-declared properties from

app engine datastore transaction exception

寵の児 提交于 2020-01-30 12:08:16
问题 In app engine transactions documentation I have found the following note: Note: If your app receives an exception when submitting a transaction, it does not always mean that the transaction failed. You can receive Timeout, TransactionFailedError, or InternalError exceptions in cases where transactions have been committed and eventually will be applied successfully. Whenever possible, make your Datastore transactions idempotent so that if you repeat a transaction, the end result will be the

apache beam 2.7.0 craches in utf-8 decoding french characters

旧巷老猫 提交于 2020-01-30 05:24:40
问题 I am trying to write a csv from a bucket of google cloud platform into datastore, containing french characters/accents but I have an error message regarding decoding. After trying encoding and decoding from " latin-1 " to " utf-8 " without success (using unicode, unicodedata and codecs ) I tried to change things manually... The Os I am using, has the " ascii " encoding by default and I manually changed in " Anaconda3/envs/py27/lib/site.py " into utf-8. def setencoding(): """Set the string