Skip to main content
This is a pre-production deployment of Warehouse. Changes made here affect the production instance of PyPI (
Help us improve Python packaging - Donate today!

Synchronization primitives for ndb tasklets on Google App Engine (GAE)

Project Description

Inspired by pythons new asyncio, this package implements the most basic synchronization primitives to work with ndb’s tasklets for the Google AppEngine (GAE)


pip install ndb-x


We have the three primitives Lock, Semaphore and BoundedSemaphore. Usage is, what you expect, straightforward:

from google.appengine.ext import ndb
from ndbx.locks import Lock

lock = Lock()

def work_async():
    # using a context-manager will release the lock automatically
    with (yield lock.acquire()):
        rv = yield do_something_async()

def traditional_flow():
    yield lock.acquire()
        # do something
Release History

Release History

This version
History Node


Download Files

Download Files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date (8.2 kB) Copy SHA256 Checksum SHA256 Source Apr 28, 2014

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting