def run_main(args, user_io=None, current_folder=None, user_folder=None, biiapi_client=None):
    try:
        user_folder = user_folder or os.path.expanduser("~")
        biicode_folder = os.path.join(user_folder, '.biicode')
        current_folder = current_folder or os.getcwd()
        user_io = user_io or create_user_io(biicode_folder)

        bii = Bii(user_io, current_folder, biicode_folder)

        # Update manager doesn't need proxy nor authentication to call get_server_info
        biiapi_client = biiapi_client or bii.biiapi
        updates_manager = get_updates_manager(biiapi_client, biicode_folder)

        try:  # Check for updates
            updates_manager.check_for_updates(bii.user_io.out)
        except ObsoleteClient as e:
            bii.user_io.out.error(e.message)
            return int(True)

        errors = bii.execute(args)
        return int(errors)
    except __HOLE__ as e:
        print str(e)
        return 1
dataset/ETHPy150Open biicode/client/shell/bii.py/run_main