Module Import alias Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str ImportFrom alias ImportFrom alias alias ImportFrom alias ImportFrom alias alias alias ImportFrom alias alias alias alias alias alias alias alias alias ImportFrom alias alias alias alias ImportFrom alias alias Assign NameStore ListLoad Str ClassDef bases NameLoad body Assign NameStore Call NameLoad Str Assign NameStore Call NameLoad Str Assign NameStore Call NameLoad Str Assign NameStore Call NameLoad Str FunctionDef arguments args NameParam NameParam NameParam NameParam defaults NameLoad body Expr Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr BinOpMod Str TupleLoad NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad If NameLoad body Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad If NameLoad body Return Call AttributeLoad NameLoad attr NameLoad Return Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr keyword NameLoad keyword AttributeLoad NameLoad attr attr If CompareIs NameLoad NameLoad body Return Call NameLoad Str Assign AttributeStore NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr Expr Call AttributeLoad NameLoad attr Return Call NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr BinOpMod Str Call NameLoad NameLoad Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr keyword NameLoad keyword AttributeLoad NameLoad attr attr If CompareIsNot NameLoad NameLoad body Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr If NameLoad body Expr Call AttributeLoad NameLoad attr Call NameLoad keyword AttributeLoad NameLoad attr keyword NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr BinOpMod Str NameLoad Return Call NameLoad Str orelse Return Call NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr keyword NameLoad attr If NameLoad body Return Call AttributeLoad NameLoad attr NameLoad orelse Return Call NameLoad Str decorator_list FunctionDef arguments args NameParam NameParam defaults body Assign NameStore AttributeLoad NameLoad attr If BoolOpAnd Call NameLoad GeneratorExp CompareEq AttributeLoad NameLoad attr AttributeLoad NameLoad attr comprehension NameStore NameLoad CompareEq Call NameLoad NameLoad AttributeLoad AttributeLoad NameLoad attr attr body Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr TryExcept body Expr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad AttributeLoad NameLoad attr attr handlers ExceptHandler body Pass decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Assign NameStore IfExp CompareIn Str NameLoad AttributeLoad NameLoad attr NameLoad Assign NameStore IfExp CompareIn Str NameLoad AttributeLoad NameLoad attr NameLoad Assign NameStore IfExp CompareIn Str NameLoad Call NameLoad AttributeLoad NameLoad attr Num Assign NameStore IfExp CompareIn Str NameLoad Call NameLoad AttributeLoad NameLoad attr Num Assign NameStore IfExp NameLoad Call AttributeLoad Call AttributeLoad NameLoad attr keyword NameLoad attr ListLoad If BoolOpAnd NameLoad NameLoad body Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr keyword NameLoad keyword NameLoad keyword NameLoad attr NameLoad NameLoad orelse If BoolOpAnd NameLoad UnaryOpNot NameLoad body Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr keyword NameLoad keyword NameLoad attr NameLoad NameLoad orelse If BoolOpAnd UnaryOpNot NameLoad NameLoad body Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr keyword NameLoad keyword NameLoad attr NameLoad NameLoad orelse Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr keyword NameLoad attr NameLoad NameLoad Return Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str For NameStore Call AttributeLoad AttributeLoad NameLoad attr attr body TryExcept body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr keyword BinOpSub Call AttributeLoad AttributeLoad NameLoad attr attr Call NameLoad keyword NameLoad keyword AttributeLoad NameLoad attr keyword NameLoad For NameStore NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad handlers ExceptHandler type NameLoad name NameStore body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Assign NameStore AttributeLoad NameLoad attr Expr Call AttributeLoad AttributeLoad NameLoad attr attr BinOpMod Str NameLoad Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr keyword NameLoad attr Assign NameStore AttributeLoad NameLoad attr For NameStore NameLoad body TryExcept body Assign NameStore NameLoad Assign NameStore Call NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr Str Num Assign NameStore BinOpBitOr Call NameLoad keyword AttributeLoad NameLoad attr Call NameLoad keyword AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad Call AttributeLoad Call AttributeLoad NameLoad attr keyword NameLoad keyword NameLoad keyword NameLoad attr NameLoad attr If CompareEq AttributeLoad NameLoad attr AttributeLoad NameLoad attr body If CompareLt NameLoad NameLoad body Assign NameStore BinOpSub NameLoad NameLoad Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr keyword NameLoad keyword NameLoad keyword AttributeLoad NameLoad attr attr If CompareGt NameLoad Num body Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str Return orelse Expr Call AttributeLoad AttributeLoad NameLoad attr attr BinOpMod Str TupleLoad AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr Break orelse If CompareEq AttributeLoad NameLoad attr AttributeLoad NameLoad attr body If CompareEq Call AttributeLoad AttributeLoad NameLoad attr attr Str AttributeLoad NameLoad attr body Continue Expr Call AttributeLoad AttributeLoad NameLoad attr attr BinOpMod Str TupleLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr If CompareLt NameLoad NameLoad body Assign NameStore BinOpSub NameLoad NameLoad Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr keyword NameLoad keyword NameLoad keyword AttributeLoad NameLoad attr attr If CompareGt NameLoad Num body Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str Return Expr Call AttributeLoad AttributeLoad NameLoad attr attr BinOpMod Str TupleLoad AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr Break handlers ExceptHandler type NameLoad name NameStore body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Assign AttributeStore NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad If NameLoad body If CompareNotIn AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Raise Call NameLoad Str If CompareLt Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr body Return NameLoad orelse Raise Call NameLoad Str orelse Raise Call NameLoad BinOpMod Str NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Assign NameStore NameLoad If BoolOpOr UnaryOpNot NameLoad UnaryOpNot NameLoad body Return NameLoad If CompareEq AttributeLoad NameLoad attr AttributeLoad NameLoad attr body If CompareIn AttributeLoad NameLoad attr AttributeLoad NameLoad attr body If CompareEq SubscriptLoad AttributeLoad NameLoad attr Index AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Assign NameStore Call NameLoad Str orelse If CompareEq SubscriptLoad AttributeLoad NameLoad attr Index AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Assign NameStore Call NameLoad Str orelse If CompareEq AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Assign NameStore Call NameLoad Str Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad If UnaryOpNot NameLoad body Raise Call NameLoad Str Assign NameStore Call AttributeLoad NameLoad attr Call NameLoad keyword NameLoad keyword NameLoad keyword NameLoad Return Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults body Assign NameStore AttributeLoad NameLoad attr Assign NameStore AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults body Assign NameStore Dict Str Str Str Str Str Str Call NameLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr IfExp AttributeLoad NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr Str IfExp AttributeLoad NameLoad attr Call NameLoad AttributeLoad AttributeLoad NameLoad attr attr Str Call NameLoad AttributeLoad NameLoad attr Call NameLoad AttributeLoad NameLoad attr If CompareNotEq AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Return NameLoad Assign NameStore ListLoad For NameStore AttributeLoad NameLoad attr body If CompareEq AttributeLoad NameLoad attr AttributeLoad NameLoad attr body TryExcept body Assign NameStore AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Str Str Assign NameStore SubscriptLoad NameLoad Index Str Assign NameStore BinOpAdd NameLoad BinOpMod Str TupleLoad NameLoad NameLoad Expr Call AttributeLoad NameLoad attr Dict Str Str Str SubscriptLoad NameLoad Index Str NameLoad NameLoad handlers ExceptHandler type NameLoad name NameStore body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Assign SubscriptStore NameLoad Index Str AttributeLoad NameLoad attr Return NameLoad Assign SubscriptStore NameLoad Index Str NameLoad Assign NameStore ListLoad If CompareEq AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr body For NameStore AttributeLoad NameLoad attr body Assign NameStore AttributeLoad NameLoad attr For NameStore Call AttributeLoad AttributeLoad NameLoad attr attr keyword NameLoad body If AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr Dict Str Str AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr orelse For NameStore AttributeLoad NameLoad attr body Assign NameStore AttributeLoad NameLoad attr If BoolOpOr UnaryOpNot NameLoad UnaryOpNot AttributeLoad NameLoad attr body Continue For NameStore AttributeLoad NameLoad attr body If AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr Dict Str Str AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign SubscriptStore NameLoad Index Str NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad If UnaryOpNot NameLoad body Raise Call NameLoad BinOpMod Str NameLoad If UnaryOpNot NameLoad body Return NameLoad Assign NameStore AttributeLoad NameLoad attr Assign NameStore ListComp AttributeLoad NameLoad attr comprehension NameStore NameLoad If CompareNotIn AttributeLoad NameLoad attr NameLoad body Raise Call NameLoad BinOpMod Str TupleLoad NameLoad AttributeLoad NameLoad attr Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults body Expr Str Assign NameStore Call NameLoad keyword ListLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr keyword NameLoad keyword NameLoad Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr If NameLoad body AugAssignBitAnd NameStore Call NameLoad keyword NameLoad Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr NameLoad attr If NameLoad body Return NameLoad Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword NameLoad keyword NameLoad keyword NameLoad attr If NameLoad body Assign AttributeStore NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr BinOpMod Str NameLoad Assign NameStore Call AttributeLoad NameLoad attr keyword NameLoad If UnaryOpNot NameLoad body Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str Return Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr If UnaryOpNot NameLoad body Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str Return Return Call AttributeLoad NameLoad attr Call NameLoad keyword NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr Assign SubscriptStore NameLoad Index Str Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Assign NameStore Call NameLoad Lambda arguments args NameParam defaults AttributeLoad NameLoad attr AttributeLoad NameLoad attr If CompareIn AttributeLoad NameLoad attr NameLoad body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Expr Call AttributeLoad AttributeLoad NameLoad attr attr BinOpAdd BinOpAdd Str Call NameLoad AttributeLoad NameLoad attr Str orelse Expr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr BinOpAdd BinOpAdd Str Call NameLoad AttributeLoad NameLoad attr Str decorator_list decorator_list
N/A N/A sys N/A N/A N/A N/A sys path append .. datetime timedelta werkzeug.exceptions PreconditionFailed NotFound mongoengine Q hackathon Component RequiredFeature Context hackathon.constants EStatus VERemoteProvider VE_PROVIDER VEStatus ReservedUser HACK_NOTICE_EVENT HACK_NOTICE_CATEGORY CLOUD_PROVIDER HACKATHON_CONFIG hackathon.hmongo.models Experiment User Hackathon UserHackathon hackathon.hackathon_response not_found ok N/A __all__ N/A ExprManager ExprManager N/A Component N/A N/A user_manager N/A RequiredFeature user_manager N/A hackathon_manager N/A RequiredFeature hackathon_manager N/A admin_manager N/A RequiredFeature admin_manager N/A template_library N/A RequiredFeature template_library start_expr N/A N/A self user template_name hackathon_name N/A None N/A N/A 
        A user uses a template to start a experiment under a hackathon
        :param hackathon_name:
        :param template_name:
        :param user_id:
        :return:
         N/A N/A N/A N/A self log debug N/A try to start experiment for hackathon %s using template %s N/A hackathon_name template_name N/A hackathon N/A N/A self __verify_hackathon hackathon_name N/A template N/A N/A self __verify_template hackathon template_name N/A user N/A N/A expr N/A N/A self __check_expr_status user hackathon template N/A expr N/A N/A N/A N/A self __report_expr_status expr N/A N/A N/A self __start_new_expr hackathon template user N/A heart_beat N/A N/A self expr_id N/A N/A N/A expr N/A N/A N/A N/A Experiment objects id expr_id status N/A EStatus RUNNING first N/A N/A expr None N/A N/A N/A not_found Experiment is not running N/A N/A expr last_heart_beat_time N/A N/A N/A self util get_now N/A N/A N/A expr save N/A N/A ok N/A stop_expr N/A N/A self expr_id N/A N/A N/A 
        :param expr_id: experiment id
        :return:
         N/A N/A N/A N/A self log debug N/A begin to stop %s N/A str expr_id N/A expr N/A N/A N/A N/A Experiment objects id expr_id status N/A EStatus RUNNING first N/A N/A expr None N/A N/A starter N/A N/A self get_starter N/A expr hackathon N/A expr template N/A starter N/A N/A N/A N/A starter stop_expr N/A Context experiment_id N/A expr id experiment expr N/A N/A N/A N/A self log debug N/A experiment %s ended success expr_id N/A N/A ok OK N/A N/A N/A ok N/A get_expr_status N/A N/A self expr_id N/A N/A N/A expr N/A N/A N/A N/A Experiment objects id expr_id first N/A expr N/A N/A N/A N/A self __report_expr_status expr N/A N/A N/A not_found Experiment Not found N/A check_expr_status N/A N/A self experiment N/A N/A N/A virtual_environment_list N/A experiment virtual_environments N/A N/A N/A all N/A N/A N/A x status N/A VEStatus RUNNING N/A x virtual_environment_list N/A N/A len virtual_environment_list N/A N/A experiment template virtual_environment_count N/A N/A N/A experiment status N/A EStatus RUNNING N/A N/A N/A experiment save N/A N/A N/A N/A N/A N/A self template_library template_verified N/A N/A experiment template id N/A N/A N/A N/A N/A get_expr_list_by_hackathon_id N/A N/A self hackathon context N/A N/A N/A user_name N/A N/A user_name context N/A context user_name None N/A status N/A N/A status context N/A context status None N/A page N/A N/A page context N/A int N/A context page 1 N/A per_page N/A N/A per_page context N/A int N/A context per_page 10 N/A users N/A user_name N/A N/A N/A N/A User objects name user_name all N/A N/A N/A user_name status N/A N/A experiments_pagi N/A N/A N/A N/A Experiment objects hackathon hackathon status status user__in users paginate page per_page N/A N/A N/A user_name N/A status N/A N/A experiments_pagi N/A N/A N/A N/A Experiment objects hackathon hackathon user__in users paginate page per_page N/A N/A N/A N/A user_name status N/A N/A experiments_pagi N/A N/A N/A N/A Experiment objects hackathon hackathon status status paginate page per_page N/A N/A experiments_pagi N/A N/A N/A N/A Experiment objects hackathon hackathon paginate page per_page N/A N/A N/A N/A self util paginate experiments_pagi N/A self __get_expr_with_detail N/A scheduler_recycle_expr N/A N/A self N/A N/A N/A recycle experiment according to hackathon basic info on recycle configuration

        According to the hackathon's basic info on 'recycle_enabled', find out time out experiments
        Then call function to recycle them

        :return:
         N/A N/A N/A N/A self log debug start checking recyclable experiment ...  N/A hackathon N/A N/A N/A self hackathon_manager get_recyclable_hackathon_list N/A N/A N/A N/A mins N/A N/A N/A self hackathon_manager get_recycle_minutes hackathon N/A exprs N/A N/A Experiment objects create_time__lt N/A N/A N/A N/A self util get_now N/A timedelta minutes mins status N/A EStatus RUNNING hackathon hackathon N/A expr exprs N/A N/A N/A N/A self __recycle_expr expr N/A N/A N/A Exception N/A e N/A N/A N/A N/A N/A self log error e N/A pre_allocate_expr N/A N/A self context N/A N/A N/A hackathon_id N/A context hackathon_id N/A N/A N/A N/A self log debug N/A executing pre_allocate_expr for hackathon %s  hackathon_id N/A hackathon N/A N/A N/A N/A Hackathon objects id hackathon_id first N/A hackathon_templates N/A hackathon templates N/A template hackathon_templates N/A N/A N/A N/A template template N/A pre_num N/A int N/A N/A N/A hackathon config get pre_allocate_number 1 N/A query N/A N/A Q status N/A EStatus STARTING N/A Q status N/A EStatus RUNNING N/A curr_num N/A N/A N/A N/A N/A N/A Experiment objects user None hackathon hackathon template template filter query count N/A N/A N/A template provider N/A VE_PROVIDER AZURE N/A N/A N/A curr_num pre_num N/A N/A remain_num N/A pre_num curr_num N/A start_num N/A N/A N/A N/A Experiment objects user None template template status N/A EStatus STARTING count N/A N/A start_num 0 N/A N/A N/A N/A N/A self log debug there is an azure env starting, will check later ...  N/A N/A N/A N/A N/A N/A self log debug N/A no starting template: %s , remain num is %d ...  N/A N/A template name remain_num N/A N/A N/A self start_expr None N/A template name N/A hackathon name N/A N/A N/A N/A N/A template provider N/A VE_PROVIDER DOCKER N/A N/A N/A N/A N/A N/A hackathon config get cloud_provider N/A CLOUD_PROVIDER ALAUDA N/A N/A N/A N/A N/A N/A self log debug N/A template name is %s, hackathon name is %s N/A N/A template name N/A hackathon name N/A N/A curr_num pre_num N/A N/A remain_num N/A pre_num curr_num N/A start_num N/A N/A N/A N/A Experiment objects user None template template status N/A EStatus STARTING count N/A N/A start_num 0 N/A N/A N/A N/A N/A self log debug there is an docker container starting, will check later ...  N/A N/A N/A N/A N/A self log debug N/A no idle template: %s, remain num is %d ...  N/A N/A template name remain_num N/A N/A N/A self start_expr None N/A template name N/A hackathon name N/A N/A N/A N/A Exception N/A e N/A N/A N/A N/A N/A self log error e N/A N/A N/A N/A self log error check default experiment failed N/A assign_expr_to_admin N/A N/A self expr N/A N/A N/A assign expr to admin to trun expr into pre_allocate_expr

        :type expr: Experiment
        :param expr: which expr you want to assign

        :return:
         N/A N/A expr user None N/A N/A N/A expr save N/A __verify_hackathon N/A N/A self hackathon_name N/A N/A N/A validate the event_start_time and event_end_time of a hackathon

        Will return None if hackathon not found or current time is not between its start time and end time
         N/A hackathon N/A N/A N/A self hackathon_manager get_hackathon_by_name hackathon_name N/A hackathon N/A N/A N/A N/A HACKATHON_CONFIG CLOUD_PROVIDER N/A hackathon config N/A N/A N/A PreconditionFailed No cloud resource is configured for this hackathon. N/A N/A N/A N/A N/A self util get_now N/A hackathon event_end_time N/A N/A hackathon N/A N/A N/A PreconditionFailed Hackathon was already ended N/A N/A N/A NotFound N/A Hackathon with name %s not found hackathon_name N/A get_starter N/A N/A self hackathon template N/A N/A N/A starter None N/A N/A N/A hackathon N/A template N/A N/A starter N/A N/A N/A template provider N/A VE_PROVIDER DOCKER N/A N/A N/A N/A HACKATHON_CONFIG CLOUD_PROVIDER N/A hackathon config N/A N/A N/A N/A N/A hackathon config N/A N/A HACKATHON_CONFIG CLOUD_PROVIDER N/A CLOUD_PROVIDER AZURE N/A N/A starter N/A RequiredFeature azure_docker N/A N/A N/A N/A N/A hackathon config N/A N/A HACKATHON_CONFIG CLOUD_PROVIDER N/A CLOUD_PROVIDER ALAUDA N/A N/A starter N/A RequiredFeature alauda_docker N/A N/A N/A N/A template provider N/A VE_PROVIDER AZURE N/A N/A starter N/A RequiredFeature azure_vm N/A starter N/A __start_new_expr N/A N/A self hackathon template user N/A N/A N/A starter N/A N/A self get_starter hackathon template N/A N/A starter N/A N/A N/A PreconditionFailed either template not supported or hackathon resource not configured N/A context N/A N/A starter start_expr N/A Context template template user user hackathon hackathon N/A N/A N/A self __report_expr_status N/A context experiment N/A on_expr_started N/A N/A self experiment N/A N/A N/A hackathon N/A experiment hackathon N/A user N/A experiment user N/A __report_expr_status N/A N/A self expr N/A N/A N/A ret N/A expr_id status hackathon_name hackathon create_time last_heart_beat_time N/A str N/A expr id N/A expr status N/A N/A expr hackathon N/A N/A expr hackathon name N/A N/A expr hackathon N/A str N/A N/A expr hackathon id N/A str N/A expr create_time N/A str N/A expr last_heart_beat_time N/A N/A N/A expr status N/A EStatus RUNNING N/A N/A ret N/A remote_servers N/A N/A ve N/A expr virtual_environments N/A N/A N/A N/A ve remote_provider N/A VERemoteProvider Guacamole N/A N/A N/A N/A guacamole_config N/A ve remote_paras N/A guacamole_host N/A N/A N/A self util safe_get_config guacamole.host localhost:8080 N/A name N/A guacamole_config N/A name N/A url N/A guacamole_host N/A /guacamole/#/client/c/%s?name=%s N/A name name N/A N/A N/A remote_servers append N/A name guacamole_host url N/A guacamole_config N/A name guacamole_host url N/A N/A N/A Exception N/A e N/A N/A N/A N/A N/A self log error e N/A N/A ret N/A status N/A EStatus STARTING N/A ret N/A N/A ret N/A remote_servers remote_servers N/A public_urls N/A N/A N/A N/A N/A expr template provider N/A VE_PROVIDER DOCKER N/A N/A ve N/A expr virtual_environments N/A N/A container N/A ve docker_container N/A p N/A N/A N/A container port_bindings filter is_public True N/A N/A N/A p url N/A N/A N/A N/A public_urls append N/A name url N/A p name N/A N/A N/A p url format N/A N/A container host_server public_dns N/A p public_port N/A N/A ve N/A expr virtual_environments N/A N/A vm N/A ve azure_resource N/A N/A N/A vm N/A N/A vm end_points N/A N/A N/A endpoint N/A vm end_points N/A N/A N/A endpoint url N/A N/A N/A N/A public_urls append N/A name url N/A endpoint name N/A N/A N/A endpoint url format N/A vm dns N/A endpoint public_port N/A N/A ret N/A public_urls public_urls N/A ret N/A __verify_template N/A N/A self hackathon template_name N/A N/A N/A template N/A N/A N/A self template_library get_template_info_by_name template_name N/A N/A template N/A N/A N/A NotFound N/A template cannot be found by name '%s' template_name N/A N/A hackathon N/A N/A template N/A hackathon_templates N/A hackathon templates N/A template_ids N/A N/A t id N/A t hackathon_templates N/A N/A N/A template id template_ids N/A N/A N/A PreconditionFailed N/A template '%s' not allowed for hackathon '%s' N/A template_name N/A hackathon name N/A template N/A __check_expr_status N/A N/A self user hackathon template N/A N/A N/A 
        check experiment status, if there are pre-allocate experiments, the experiment will be assigned directly
        :param user:
        :param hackathon:
        :param template:
        :return:
         N/A criterion N/A Q status__in N/A N/A EStatus RUNNING N/A EStatus STARTING hackathon hackathon user user N/A is_admin N/A N/A N/A self admin_manager is_hackathon_admin N/A hackathon id N/A user id N/A is_admin N/A N/A criterion N/A Q template template N/A expr N/A N/A N/A N/A Experiment objects criterion first N/A expr N/A N/A expr N/A expr N/A N/A N/A N/A Experiment objects status N/A EStatus RUNNING hackathon hackathon template template user None first N/A expr N/A N/A N/A expr user user N/A N/A N/A expr save N/A expr N/A roll_back N/A N/A self expr_id N/A N/A N/A 
        roll back when exception occurred
        :param expr_id: experiment id
         N/A N/A N/A N/A self log debug N/A Starting rollback experiment %s... expr_id N/A expr N/A N/A Experiment objects id expr_id N/A N/A expr N/A N/A N/A N/A N/A self log warn rollback failed due to experiment not found N/A N/A starter N/A N/A self get_starter N/A expr hackathon N/A expr template N/A N/A starter N/A N/A N/A N/A N/A self log warn rollback failed due to no starter found N/A N/A N/A N/A starter rollback N/A Context experiment expr N/A __get_expr_with_detail N/A N/A self experiment N/A N/A N/A info N/A N/A experiment dic N/A N/A info N/A user N/A N/A N/A self user_manager user_display_info N/A experiment user N/A info N/A __recycle_expr N/A N/A self expr N/A N/A N/A recycle expr

        If it is a docker experiment , stop it ; else assign it to default user

        :type expr: Experiment
        :param expr: the exper which you want to recycle

        :return:
         N/A providers N/A map N/A N/A N/A x N/A N/A x provider N/A expr virtual_environments N/A N/A N/A VE_PROVIDER DOCKER providers N/A N/A N/A N/A self stop_expr N/A expr id N/A N/A N/A N/A self log debug N/A N/A it's stopping  N/A str N/A expr id  inactive experiment now N/A N/A N/A N/A self assign_expr_to_admin expr N/A N/A N/A N/A self log debug N/A N/A assign  N/A str N/A expr id  to default admin N/A N/A