@@ -27,7 +27,7 @@ def run_server_script(args):
2727def run_start_script (args ):
2828 # Start the start.sh script in its own directory as a new process group
2929 process = subprocess .Popen (
30- ['bash' , 'start.sh' , '-t' , args .team_name , '--rpc-port' , args .rpc_port , '--rpc-type' , 'grpc' ],
30+ ['bash' , 'start.sh' if not args . debug else 'start-debug.sh' , '-t' , args .team_name , '--rpc-port' , args .rpc_port , '--rpc-type' , 'grpc' ],
3131 cwd = 'scripts/proxy' , # Corrected directory to where start.sh is located
3232 preexec_fn = os .setsid , # Create a new session and set the process group ID
3333 stdout = subprocess .PIPE ,
@@ -60,8 +60,9 @@ def kill_process_group(process):
6060 parser = argparse .ArgumentParser (description = 'Run server and team scripts.' )
6161 parser .add_argument ('-t' , '--team_name' , required = False , help = 'The name of the team' , default = 'CLS' )
6262 parser .add_argument ('--rpc-port' , required = False , help = 'The port of the server' , default = '50051' )
63+ parser .add_argument ('-d' , '--debug' , required = False , help = 'Enable debug mode' , default = False , action = 'store_true' )
6364 args = parser .parse_args ()
64-
65+
6566 try :
6667 # Check Python requirements
6768 start_team_logger .debug ("Checking Python requirements..." )
0 commit comments