<s> from __future__ import print_function , unicode_literals <EOL> """<STR_LIT>""" <EOL> import os <EOL> import threading <EOL> import sys <EOL> import time <EOL> original_path = os . path . abspath ( os . curdir ) <EOL> weblab_path = "<STR_LIT>" <EOL> os . chdir ( weblab_path ) <EOL> sys . path . append ( "<STR_LIT:.>" ) <EOL> from launch_sample import inner <EOL> condition = threading . Condition ( ) <EOL> event_notifier = threading . Condition ( ) <EOL> class Runner ( threading . Thread ) : <EOL> def run ( self ) : <EOL> self . launcher = inner ( condition = condition , event_notifier = event_notifier ) <EOL> self . launcher . launch ( ) <EOL> runner = Runner ( ) <EOL> runner . start ( ) <EOL> with event_notifier : <EOL> event_notifier . wait ( ) <EOL> os . chdir ( original_path ) <EOL> result = os . system ( <EOL> "<STR_LIT>" ) <EOL> os . chdir ( weblab_path ) <EOL> with condition : <EOL> condition . notify ( ) <EOL> sys . exit ( result ) </s>
