mirror of
https://github.com/All-Hands-AI/OpenHands.git
synced 2026-04-29 03:00:45 -04:00
* Feat: add stream output to exec_run * Using command timeout to control the exec_box's timeout. * add bash -c to source command to compatible for sh. Signed-off-by: ifuryst <ifuryst@gmail.com> * Feat: add stream output to SSHBox execute Signed-off-by: ifuryst <ifuryst@gmail.com> * fix the test case fail. Signed-off-by: ifuryst <ifuryst@gmail.com> * fix the test case import wrong path for method. Signed-off-by: ifuryst <ifuryst@gmail.com> --------- Signed-off-by: ifuryst <ifuryst@gmail.com>
31 lines
867 B
Python
31 lines
867 B
Python
import argparse
|
|
|
|
import pytest
|
|
|
|
from opendevin.config import config
|
|
|
|
if __name__ == '__main__':
|
|
"""Main entry point of the script.
|
|
|
|
This script runs pytest with specific arguments and configuration.
|
|
|
|
Usage:
|
|
python script_name.py [--OPENAI_API_KEY=<api_key>] [--model=<model_name>]
|
|
|
|
"""
|
|
parser = argparse.ArgumentParser(
|
|
description='This script runs pytest with specific arguments and configuration.'
|
|
)
|
|
parser.add_argument(
|
|
'--OPENAI_API_KEY', type=str, required=True, help='Your OpenAI API key'
|
|
)
|
|
parser.add_argument(
|
|
'--model', type=str, required=True, help='The model name to use'
|
|
)
|
|
|
|
parser_args = parser.parse_args()
|
|
config.config['OPENAI_API_KEY'] = parser_args.OPENAI_API_KEY
|
|
args = ['-v', 'evaluation/regression/cases', f'-o model={parser_args.model}']
|
|
|
|
pytest.main(args)
|