(dt=None)
return (ensure_aware_datetime(dt) - EPOCH).total_seconds()
Returns the number of seconds since the Unix epoch.
    If `dt` is not specified or `None`, the current time in UTC is assumed.
Returns the number of seconds since the Unix epoch.
    If `dt` is not specified or `None`, the current time in UTC is assumed.
Returns the number of seconds since the Unix epoch . If dt is not specified or None the current time in UTC is assumed .
def get_timestamp(dt=None):
    """
    Returns the number of seconds since the Unix epoch.
    If `dt` is not specified or `None`, the current time in UTC is assumed.
    """
    if dt is None:
        # The precision is different between Python 2 and 3
        return epoch_offset()

    # TODO: when we drop support for Python 2 switch to:
    # return ensure_aware_datetime(dt).timestamp()
    return (ensure_aware_datetime(dt) - EPOCH).total_seconds()
def get_timestamp ( dt = None ) : if dt is None : # The precision is different between Python 2 and 3 return epoch_offset ( ) # TODO: when we drop support for Python 2 switch to: # return ensure_aware_datetime(dt).timestamp() return ( ensure_aware_datetime ( dt ) - EPOCH ) . total_seconds ( )