def format_uptime(start_time):
    try:
        delta = datetime.now() - start_time
        days = delta.days
        hours = delta.seconds / 3600
        minutes = (delta.seconds % 3600) / 60
        seconds = (delta.seconds % 3600) % 60
        return "%dd %dh %dm %ds" % (days, hours, minutes, seconds)
    except __HOLE__:
        return 'n/a'
dataset/ETHPy150Open onefinestay/gonzo/gonzo/scripts/utils.py/format_uptime