code
stringlengths
3
6.57k
time.time()
int(now - start_wait)
time.time()
logger.warning("No remote file specified, returning empty dict")
os.path.join(temp_dir, ".tmp.json")
open(local_target_file, "rt")
json.load(f)
get_local_json_content(local_file: Optional[str], )
logger.warning("No local file specified, returning empty dict")
open(local_file, "rt")
json.load(f)
os.path.join(temp_dir, "output.log")
open(output_log_file, "wt")
f.write(logs)
boto3.client("s3")
s3_client.upload_file(output_log_file, bucket, f"{location}/output.log")
artifacts.items()
os.path.join(temp_dir, name)
dict(contains=test_name)
dict(count=20, paging_token=paging_token)
logger.info(f"Found sessions {session.name}")
session.name.startswith(test_name)
session_state.get("test_name")
status (str)
command_link (str)
command (Anyscale web UI)
last_logs (str)
logs (excerpt)
artifacts (dict)
Todo (mid-term)
_load_config(local_dir, cluster_config_rel_path)
get("app_config", None)
_load_config(local_dir, app_config_rel_path)
get("compute_template", None)
_load_config(local_dir, compute_tpl_rel_path)
multiprocessing.Event()
multiprocessing.Queue()
int(time.time()
tempfile.mkdtemp()
get("results", None)
get("state", None)
os.environ.get("RAY_ADDRESS", "auto")
open(os.path.join(local_dir, ".anyscale.yaml")
f.write(f"project_id: {project_id}")
os.chdir(local_dir)
AnyscaleSDK(auth_token=GLOBAL_CONFIG["ANYSCALE_CLI_TOKEN"])
get("timeout", 1800)
int(os.environ.get("RELEASE_OVERRIDE_TIMEOUT", str(timeout)
get("long_running", False)
get("use_connect")
get("autosuspend_mins", 5)
sdk.get_cluster_environment_build(build_id_override)
install_app_config_packages(app_config)
install_matching_ray()
_update_results(results: Dict)
time.time()
logger.info("Command finished successfully.")
_update_results(results)
test_config.get("log_lines", 50)
test_config.get("artifacts", {})
logger.info("Fetched results and stored on the cloud. Returning.")
test_config.get("stable", True)
time.time()
_process_finished_client_command(returncode: int, logs: str)
logger.info("Stored results on the cloud. Returning.")
get_local_json_content(local_file=results_json, )
int(returncode == 0)
_update_results(results)
time.time()
_run(logger)
get("use_connect")
search_running_session(sdk, project_id, session_name)
logger.info("No session found.")
logging.info("Starting session with cluster config")
json.dumps(cluster_config)
logging.info("Starting session with app/compute config")
anyscale_compute_tpl_url(compute_tpl_id)
wait_for_build_or_raise(sdk, app_config_id)
get("prepare")
os.path.join(local_dir, "test_state.json")
open(test_state_file, "wt")
time.time()
logger.info("Syncing files to session...")
logger.info("Syncing test state to session...")
_check_stop(stop_event, "file_sync")
get("args", [])
result_queue.put(State("CMD_RUN", time.time()
_process_finished_client_command(returncode, logs)
get("args", [])
join(args)
State("END", time.time()
except (ReleaseTestTimeoutError, Exception)
logger.error(e, exc_info=True)
str(e)
test_config.get("log_lines", 50)
logger.error(e2, exc_info=True)
isinstance(e, ReleaseTestTimeoutError)
isinstance(e, CommandTimeoutError)
elif (isinstance(e, PrepareCommandTimeoutError)
isinstance(e, FileSyncTimeoutError)