π OpenHands: AI-Driven Development
chore - Remove unneeded dependencies from main poetry (#7772)
Ray Myersfb02fefaca21
diff --git a/openhands/resolver/utils.py b/openhands/resolver/utils.pyindex 77c603e8a3..f9e8276a5a 100644--- a/openhands/resolver/utils.py+++ b/openhands/resolver/utils.py@@ -1,4 +1,3 @@-import jsonimport loggingimport multiprocessing as mpimport os@@ -7,7 +6,6 @@ from enum import Enumfrom typing import Callableimport httpx-import pandas as pdfrom openhands.controller.state.state import Statefrom openhands.core.logger import get_console_handler@@ -134,43 +132,6 @@ def cleanup() -> None:process.join()-def prepare_dataset(- dataset: pd.DataFrame, output_file: str, eval_n_limit: int-) -> pd.DataFrame:- assert 'instance_id' in dataset.columns, (- "Expected 'instance_id' column in the dataset. You should define your own "- "unique identifier for each instance and use it as the 'instance_id' column."- )- id_column = 'instance_id'- logger.info(f'Writing evaluation output to {output_file}')- finished_ids = set()- if os.path.exists(output_file):- with open(output_file, 'r') as f:- for line in f:- data = json.loads(line)- finished_ids.add(data[id_column])- logger.warning(- f'Output file {output_file} already exists. Loaded '- f'{len(finished_ids)} finished instances.'- )-- if eval_n_limit:- dataset = dataset.head(eval_n_limit)- logger.info(f'Limiting evaluation to first {eval_n_limit} instances.')-- new_dataset = [- instance- for _, instance in dataset.iterrows()- if instance[id_column] not in finished_ids- ]- logger.info(- f'Finished instances: {len(finished_ids)}, '- f'Remaining instances: {len(new_dataset)}'- )-- return pd.DataFrame(new_dataset)--def reset_logger_for_multiprocessing(logger: logging.Logger, instance_id: str, log_dir: str) -> None:diff --git a/poetry.lock b/poetry.lockindex 5dc727e2a5..9fbba25311 100644--- a/poetry.lock+++ b/poetry.lock@@ -1191,7 +1191,7 @@ version = "1.17.1"description = "Foreign Function Interface for Python calling C code."optional = falsepython-versions = ">=3.8"-groups = ["main", "runtime"]+groups = ["main", "runtime", "test"]files = [{file = "cffi-1.17.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:df8b1c11f177bc2313ec4b2d46baec87a5f3e71fc8b45dab2ee7cae86d9aba14"},{file = "cffi-1.17.1-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:8f2cdc858323644ab277e9bb925ad72ae0e67f69e804f4898c070998d50b1a67"},@@ -1261,6 +1261,7 @@ files = [{file = "cffi-1.17.1-cp39-cp39-win_amd64.whl", hash = "sha256:d016c76bdd850f3c626af19b0542c9677ba156e4ee4fccfdd7848803533ef662"},{file = "cffi-1.17.1.tar.gz", hash = "sha256:1c39c6016c32bc48dd54561950ebd6836e1670f2ae46128f67cf49e789c52824"},]+markers = {test = "platform_python_implementation == \"CPython\" and sys_platform == \"win32\""}[package.dependencies]pycparser = "*"@@ -1483,7 +1484,7 @@ version = "1.3.1"description = "Python library for calculating contours of 2D quadrilateral grids"optional = falsepython-versions = ">=3.10"-groups = ["main", "evaluation"]+groups = ["evaluation"]files = [{file = "contourpy-1.3.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:a045f341a77b77e1c5de31e74e966537bba9f3c4099b35bf4c2e3939dd54cdab"},{file = "contourpy-1.3.1-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:500360b77259914f7805af7462e41f9cb7ca92ad38e9f94d6c8641b089338124"},@@ -1691,7 +1692,7 @@ version = "0.12.1"description = "Composable style cycles"optional = falsepython-versions = ">=3.8"-groups = ["main", "evaluation"]+groups = ["evaluation"]files = [{file = "cycler-0.12.1-py3-none-any.whl", hash = "sha256:85cef7cff222d8644161529808465972e51340599459b8ac3ccbac5a854e0d30"},{file = "cycler-0.12.1.tar.gz", hash = "sha256:88bb128f02ba341da8ef447245a9e138fae777f6a23943da4540077d3601eb1c"},@@ -1723,7 +1724,7 @@ version = "3.0.1"description = "HuggingFace community-driven open-source library of datasets"optional = falsepython-versions = ">=3.8.0"-groups = ["main", "evaluation"]+groups = ["evaluation"]files = [{file = "datasets-3.0.1-py3-none-any.whl", hash = "sha256:db080aab41c8cc68645117a0f172e5c6789cbc672f066de0aa5a08fc3eebc686"},{file = "datasets-3.0.1.tar.gz", hash = "sha256:40d63b09e76a3066c32e746d6fdc36fd3f29ed2acd49bf5b1a2100da32936511"},@@ -1887,7 +1888,7 @@ version = "0.3.8"description = "serialize all of Python"optional = falsepython-versions = ">=3.8"-groups = ["main", "evaluation"]+groups = ["evaluation"]files = [{file = "dill-0.3.8-py3-none-any.whl", hash = "sha256:c36ca9ffb54365bdd2f8eb3eff7d2a21237f8452b57ace88b1ac615b7e815bd7"},{file = "dill-0.3.8.tar.gz", hash = "sha256:3ebe3c479ad625c4553aca177444d89b486b1d84982eeacded644afc0cf797ca"},@@ -2235,7 +2236,7 @@ version = "4.56.0"description = "Tools to manipulate font files"optional = falsepython-versions = ">=3.8"-groups = ["main", "evaluation"]+groups = ["evaluation"]files = [{file = "fonttools-4.56.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:331954d002dbf5e704c7f3756028e21db07097c19722569983ba4d74df014000"},{file = "fonttools-4.56.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:8d1613abd5af2f93c05867b3a3759a56e8bf97eb79b1da76b2bc10892f96ff16"},@@ -2513,7 +2514,7 @@ version = "24.11.1"description = "Coroutine-based network library"optional = falsepython-versions = ">=3.9"-groups = ["main"]+groups = ["test"]files = [{file = "gevent-24.11.1-cp310-cp310-macosx_11_0_universal2.whl", hash = "sha256:92fe5dfee4e671c74ffaa431fd7ffd0ebb4b339363d24d0d944de532409b935e"},{file = "gevent-24.11.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b7bfcfe08d038e1fa6de458891bca65c1ada6d145474274285822896a858c870"},@@ -2661,7 +2662,7 @@ grpcio = {version = ">=1.49.1,<2.0dev", optional = true, markers = "python_versigrpcio-status = {version = ">=1.49.1,<2.0.dev0", optional = true, markers = "python_version >= \"3.11\" and extra == \"grpc\""}proto-plus = [{version = ">=1.25.0,<2.0.0dev", markers = "python_version >= \"3.13\""},- {version = ">=1.22.3,<2.0.0dev", markers = "python_version < \"3.13\""},+ {version = ">=1.22.3,<2.0.0dev"},]protobuf = ">=3.19.5,<3.20.0 || >3.20.0,<3.20.1 || >3.20.1,<4.21.0 || >4.21.0,<4.21.1 || >4.21.1,<4.21.2 || >4.21.2,<4.21.3 || >4.21.3,<4.21.4 || >4.21.4,<4.21.5 || >4.21.5,<6.0.0.dev0"requests = ">=2.18.0,<3.0.0.dev0"@@ -2874,7 +2875,7 @@ google-auth = ">=2.14.1,<2.24.0 || >2.24.0,<2.25.0 || >2.25.0,<3.0.0dev"grpc-google-iam-v1 = ">=0.14.0,<1.0.0dev"proto-plus = [{version = ">=1.25.0,<2.0.0dev", markers = "python_version >= \"3.13\""},- {version = ">=1.22.3,<2.0.0dev"},+ {version = ">=1.22.3,<2.0.0dev", markers = "python_version < \"3.13\""},]protobuf = ">=3.20.2,<4.21.0 || >4.21.0,<4.21.1 || >4.21.1,<4.21.2 || >4.21.2,<4.21.3 || >4.21.3,<4.21.4 || >4.21.4,<4.21.5 || >4.21.5,<6.0.0dev"@@ -3010,7 +3011,7 @@ version = "3.1.1"description = "Lightweight in-process concurrent programming"optional = falsepython-versions = ">=3.7"-groups = ["main", "evaluation"]+groups = ["main", "evaluation", "test"]files = [{file = "greenlet-3.1.1-cp310-cp310-macosx_11_0_universal2.whl", hash = "sha256:0bbae94a29c9e5c7e4a2b7f0aae5c17e8e90acbfd3bf6270eeba60c39fce3563"},{file = "greenlet-3.1.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0fde093fb93f35ca72a556cf72c92ea3ebfda3d79fc35bb19fbe685853869a83"},@@ -3086,6 +3087,7 @@ files = [{file = "greenlet-3.1.1-cp39-cp39-win_amd64.whl", hash = "sha256:3319aa75e0e0639bc15ff54ca327e8dc7a6fe404003496e3c6925cd3142e0e22"},{file = "greenlet-3.1.1.tar.gz", hash = "sha256:4ce3ac6cdb6adf7946475d7ef31777c26d94bccc377e070a7986bd2d5c515467"},]+markers = {test = "platform_python_implementation == \"CPython\""}[package.extras]docs = ["Sphinx", "furo"]@@ -4133,7 +4135,7 @@ version = "1.4.8"description = "A fast implementation of the Cassowary constraint solver"optional = falsepython-versions = ">=3.10"-groups = ["main", "evaluation"]+groups = ["evaluation"]files = [{file = "kiwisolver-1.4.8-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:88c6f252f6816a73b1f8c904f7bbe02fd67c09a69f7cb8a0eecdbf5ce78e63db"},{file = "kiwisolver-1.4.8-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:c72941acb7b67138f35b879bbe85be0f6c6a70cab78fe3ef6db9c024d9223e5b"},@@ -4717,7 +4719,7 @@ version = "3.10.1"description = "Python plotting package"optional = falsepython-versions = ">=3.10"-groups = ["main", "evaluation"]+groups = ["evaluation"]files = [{file = "matplotlib-3.10.1-cp310-cp310-macosx_10_12_x86_64.whl", hash = "sha256:ff2ae14910be903f4a24afdbb6d7d3a6c44da210fc7d42790b87aeac92238a16"},{file = "matplotlib-3.10.1-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0721a3fd3d5756ed593220a8b86808a36c5031fce489adb5b31ee6dbb47dd5b2"},@@ -5008,7 +5010,7 @@ version = "0.70.16"description = "better multiprocessing and multithreading in Python"optional = falsepython-versions = ">=3.8"-groups = ["main", "evaluation"]+groups = ["evaluation"]files = [{file = "multiprocess-0.70.16-pp310-pypy310_pp73-macosx_10_13_x86_64.whl", hash = "sha256:476887be10e2f59ff183c006af746cb6f1fd0eadcfd4ef49e605cbe2659920ee"},{file = "multiprocess-0.70.16-pp310-pypy310_pp73-manylinux_2_28_x86_64.whl", hash = "sha256:d951bed82c8f73929ac82c61f01a7b5ce8f3e5ef40f5b52553b4f547ce2b08ec"},@@ -6325,7 +6327,7 @@ version = "19.0.1"description = "Python library for Apache Arrow"optional = falsepython-versions = ">=3.9"-groups = ["main", "evaluation"]+groups = ["evaluation"]files = [{file = "pyarrow-19.0.1-cp310-cp310-macosx_12_0_arm64.whl", hash = "sha256:fc28912a2dc924dddc2087679cc8b7263accc71b9ff025a1362b004711661a69"},{file = "pyarrow-19.0.1-cp310-cp310-macosx_12_0_x86_64.whl", hash = "sha256:fca15aabbe9b8355800d923cc2e82c8ef514af321e18b437c3d782aa884eaeec"},@@ -6434,11 +6436,12 @@ version = "2.22"description = "C parser in Python"optional = falsepython-versions = ">=3.8"-groups = ["main", "runtime"]+groups = ["main", "runtime", "test"]files = [{file = "pycparser-2.22-py3-none-any.whl", hash = "sha256:c3702b6d3dd8c7abc1afa565d7e63d53a1d0bd86cdc24edd75470f4de499cfcc"},{file = "pycparser-2.22.tar.gz", hash = "sha256:491c8be9c040f5390f5bf44a5b07752bd07f56edf992381b05c701439eec10f6"},]+markers = {test = "platform_python_implementation == \"CPython\" and sys_platform == \"win32\""}[[package]]name = "pycryptodome"@@ -8166,7 +8169,7 @@ version = "0.13.2"description = "Statistical data visualization"optional = falsepython-versions = ">=3.8"-groups = ["main", "evaluation"]+groups = ["evaluation"]files = [{file = "seaborn-0.13.2-py3-none-any.whl", hash = "sha256:636f8336facf092165e27924f223d3c62ca560b1f2bb5dff7ab7fad265361987"},{file = "seaborn-0.13.2.tar.gz", hash = "sha256:93e60a40988f4d65e9f4885df477e2fdaff6b73a9ded434c1ab356dd57eefff7"},@@ -8205,7 +8208,7 @@ version = "75.8.2"description = "Easily download, build, install, upgrade, and uninstall Python packages"optional = falsepython-versions = ">=3.9"-groups = ["main", "evaluation", "runtime"]+groups = ["main", "evaluation", "runtime", "test"]files = [{file = "setuptools-75.8.2-py3-none-any.whl", hash = "sha256:558e47c15f1811c1fa7adbd0096669bf76c1d3f433f58324df69f3f5ecac4e8f"},{file = "setuptools-75.8.2.tar.gz", hash = "sha256:4880473a969e5f23f2a2be3646b2dfd84af9028716d398e46192f84bc36900d2"},@@ -9872,7 +9875,7 @@ version = "3.5.0"description = "Python binding for xxHash"optional = falsepython-versions = ">=3.7"-groups = ["main", "evaluation"]+groups = ["evaluation"]files = [{file = "xxhash-3.5.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:ece616532c499ee9afbb83078b1b952beffef121d989841f7f4b3dc5ac0fd212"},{file = "xxhash-3.5.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:3171f693dbc2cef6477054a665dc255d996646b4023fe56cb4db80e26f4cc520"},@@ -10122,7 +10125,7 @@ version = "5.0"description = "Very basic event publishing system"optional = falsepython-versions = ">=3.7"-groups = ["main"]+groups = ["test"]files = [{file = "zope.event-5.0-py3-none-any.whl", hash = "sha256:2832e95014f4db26c47a13fdaef84cef2f4df37e66b59d8f1f4a8f319a632c26"},{file = "zope.event-5.0.tar.gz", hash = "sha256:bac440d8d9891b4068e2b5a2c5e2c9765a9df762944bda6955f96bb9b91e67cd"},@@ -10141,7 +10144,7 @@ version = "7.2"description = "Interfaces for Python"optional = falsepython-versions = ">=3.8"-groups = ["main"]+groups = ["main", "test"]files = [{file = "zope.interface-7.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:ce290e62229964715f1011c3dbeab7a4a1e4971fd6f31324c4519464473ef9f2"},{file = "zope.interface-7.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:05b910a5afe03256b58ab2ba6288960a2892dfeef01336dc4be6f1b9ed02ab0a"},@@ -10193,4 +10196,4 @@ testing = ["coverage[toml]", "zope.event", "zope.testing"][metadata]lock-version = "2.1"python-versions = "^3.12"-content-hash = "bd1e164559f6395718bc76482493aa71327e7aee9ebe6131facba65661d9abec"+content-hash = "4081b88d1b970aa56603359e41430d4465486b3866bfd50371d5c4f77fb58fb4"diff --git a/pyproject.toml b/pyproject.tomlindex e7427c8ec9..a06a2e191f 100644--- a/pyproject.toml+++ b/pyproject.toml@@ -14,8 +14,6 @@ packages = [[tool.poetry.dependencies]python = "^3.12"-datasets = "*"-pandas = "*"litellm = "^1.60.0"aiohttp = ">=3.9.0,!=3.11.13" # Pin to avoid yanked version 3.11.13google-generativeai = "*" # To use litellm with Gemini Pro API@@ -23,7 +21,6 @@ google-api-python-client = "^2.164.0" # For Google Sheets APIgoogle-auth-httplib2 = "*" # For Google Sheets authenticationgoogle-auth-oauthlib = "*" # For Google Sheets OAuthtermcolor = "*"-seaborn = "*"docker = "*"fastapi = "*"toml = "*"@@ -39,8 +36,6 @@ jinja2 = "^3.1.3"python-multipart = "*"boto3 = "*"minio = "^7.2.8"-gevent = "^24.2.1"-pyarrow = "19.0.1" # transitive dependency, pinned here to avoid conflictstenacity = ">=8.5,<10.0"zope-interface = "7.2"pathspec = "^0.12.1"@@ -96,6 +91,7 @@ pytest-xdist = "*"openai = "*"pandas = "*"reportlab = "*"+gevent = "^24.2.1"[tool.coverage.run]concurrency = ["gevent"]@@ -149,6 +145,8 @@ browsergym-webarena = "0.13.3"browsergym-miniwob = "0.13.3"browsergym-visualwebarena = "0.13.3"boto3-stubs = {extras = ["s3"], version = "^1.37.19"}+pyarrow = "19.0.1" # transitive dependency, pinned here to avoid conflicts+datasets = "*"[tool.poetry-dynamic-versioning]enable = true