import uos as os
import time


def countdown():
    for i in range(5, 0, -1):
        print("start stubbing in {}...".format(i))
        time.sleep(1)
    import createstubs

    # import stub_lvgl


try:
    # only run import if no stubs yet
    os.listdir("stubs")
    print("stub folder was found, stubbing is not automatically started")

except OSError:
    countdown()

[(16, 'uos.listdir', 'os.listdir', True, 'import uos as os\n'), (8, 'time.sleep', 'time.sleep', False, 'import time\n')]