import time


def isoDateFromPySec(pySec=None, useGMT=True):
    """Return the time as an ISO date string (without a timezone suffix).

    Inputs:
    - pySec: time as returned by time.time(); if None then uses the current time
    - useGMT: treat the time as GMT, meaning no timezone information is applied

    Returns a string in this format: YYYY-MM-DD
    """
    if useGMT:
        timeTuple = time.gmtime(pySec)
    else:
        timeTuple = time.localtime(pySec)

    return time.strftime("%Y-%m-%d", timeTuple)