princeton-nlp / SWE-bench

[ICLR 2024] SWE-Bench: Can Language Models Resolve Real-world Github Issues?
https://www.swebench.com
MIT License
1.8k stars 312 forks source link

Which Python version to use? #156

Closed anupamme closed 2 months ago

anupamme commented 3 months ago

Describe the issue

I tried installing SWE-bench with various python version: 3.8, 3.9, 3.10, 3.11 and 3.12.

The requirements.txt lists this package: config

If you goto the package url you will see it is only supported till python 3.7.

The package config uses a package pysqlite which is not supported in python 3 instead there is an inbuilt package called sqlite3.

So my question is which python version are we supposed to use?

Is it possible to not use the package config as it is not supported in later versions of python?

The error stack I get when I pip install is this:

Collecting pysqlite (from config->sweagent==0.6.1) Using cached https://pypi.uberinternal.com/packages/packages/42/02/981b6703e3c83c5b25a829c6e77aad059f9481b0bbacb47e6e8ca12bd731/pysqlite-2.8.3.tar.gz (80 kB) Installing build dependencies ... done Getting requirements to build wheel ... error error: subprocess-exited-with-error

× Getting requirements to build wheel did not run successfully. │ exit code: 1 ╰─> [1 lines of output] pysqlite is not supported on Python 3. When using Python 3, use the sqlite3 module from the standard library. [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip. error: subprocess-exited-with-error

× Getting requirements to build wheel did not run successfully. │ exit code: 1 ╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.

Suggest an improvement to documentation

Mention which python version is supported.

john-b-yang commented 3 months ago

Hi @anupamme, which script are you trying to run?

The python version we use for the conda environment of SWE-bench can be found here.

Although, as mentioned here, the setup should no longer require the environment.yml, as discussed in the Set Up section.

Are you getting this error from pip install -e .?

john-b-yang commented 3 months ago

Ok I just removed the environment.yml file, as it is no longer necessary, but it should work for any of the python versions you've mentioned. We use 3.9, 3.10, or 3.11.

Also, we don't use the config library in swebench/ anymore. What code are you referring to? If you're on the latest version of SWE-bench, the config dep shouldn't be needed.

john-b-yang commented 2 months ago

Actually, it looks like this is a SWE-agent bug you're referring to. If this is still a problem, please post an issue in princeton-nlp/SWE-agent instead.