Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(63)

Side by Side Diff: appengine/components/components/datastore_utils/monotonic.py

Issue 2013943002: Changing license header, again! (Closed) Base URL: git@github.com:luci/luci-py.git@master
Patch Set: Fixed third parties Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 # Copyright 2014 The LUCI Authors. All rights reserved. 1 # Copyright 2014 The LUCI Authors. All rights reserved.
2 # Use of this source code is governed by the Apache v2.0 license that can be 2 # Use of this source code is governed under the Apache License, Version 2.0
3 # found in the LICENSE file. 3 # that can be found in the LICENSE file.
4 4
5 """Monotonic addition of entities.""" 5 """Monotonic addition of entities."""
6 6
7 from google.appengine.api import datastore_errors 7 from google.appengine.api import datastore_errors
8 from google.appengine.ext import ndb 8 from google.appengine.ext import ndb
9 from google.appengine.runtime import apiproxy_errors 9 from google.appengine.runtime import apiproxy_errors
10 10
11 from components import utils 11 from components import utils
12 from . import txn 12 from . import txn
13 13
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after
217 root.current = flat[-1] 217 root.current = flat[-1]
218 return ndb.Key(flat=flat) 218 return ndb.Key(flat=flat)
219 219
220 extra = (extra or [])[:] 220 extra = (extra or [])[:]
221 extra.append(root) 221 extra.append(root)
222 result = yield insert_async(entity, _new_key_minus_one_current, extra=extra) 222 result = yield insert_async(entity, _new_key_minus_one_current, extra=extra)
223 raise ndb.Return(result) 223 raise ndb.Return(result)
224 224
225 225
226 store_new_version = utils.sync_of(store_new_version_async) 226 store_new_version = utils.sync_of(store_new_version_async)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698