mapreduce/model.py
def _get_descending_key(gettime=time.time, getrandint=random.randint):
  """Returns a key name lexically ordered by time descending.

  This lets us have a key name for use with Datastore entities which returns
  rows in time descending order when it is scanned in lexically ascending order,
  allowing us to bypass index building for descending indexes.

  Args:
    gettime: Used for testing.
    getrandint: Used for testing.

  Returns:
    A string with a time descending key.
  """
  now_descending = int((_FUTURE_TIME - gettime()) * 100)
  tie_breaker = getrandint(0, 100)
  return "%d%d" % (now_descending, tie_breaker)
Returns a key name lexically ordered by time descending.

  This lets us have a key name for use with Datastore entities which returns
  rows in time descending order when it is scanned in lexically ascending order,
  allowing us to bypass index building for descending indexes.

  Args:
    gettime: Used for testing.
    getrandint: Used for testing.

  Returns:
    A string with a time descending key.
  
Returns a key name lexically ordered by time descending.
This lets us have a key name for use with Datastore entities which returns
rows in time descending order when it is scanned in lexically ascending order,
allowing us to bypass index building for descending indexes.
Returns a key name lexically ordered by time descending . This lets us have a key name for use with Datastore entities which returns rows in time descending order when it is scanned in lexically ascending order allowing us to bypass index building for descending indexes .
def _get_descending_key(gettime=time.time, getrandint=random.randint):
  now_descending = int((_FUTURE_TIME - gettime()) * 100)
  tie_breaker = getrandint(0, 100)
  return "%d%d" % (now_descending, tie_breaker)
def _get_descending_key ( gettime = time . time , getrandint = random . randint ) : now_descending = int ( ( _FUTURE_TIME - gettime ( ) ) * 100 ) tie_breaker = getrandint ( 0 , 100 ) return "%d%d" % ( now_descending , tie_breaker )
Returns a key name lexically ordered by time descending.
Returns a key name lexically ordered by time descending .
"""Returns a key name lexically ordered by time descending.

  This lets us have a key name for use with Datastore entities which returns
  rows in time descending order when it is scanned in lexically ascending order,
  allowing us to bypass index building for descending indexes.

  Args:
    gettime: Used for testing.
    getrandint: Used for testing.

  Returns:
    A string with a time descending key.
  """
A string with a time descending key.
A string with a time descending key .
gettime
Used for testing.
Used for testing .
getrandint
Used for testing.
Used for testing .