Skip to content

SWE-agent takes a GitHub issue and tries to automatically fix it, using your LM of choice. It can also be employed for offensive cybersecurity or competitive coding challenges. [NeurIPS 2024]

Remove __future__ imports from commands (#687)

Kilian Lieretd5663e4144ca
diff --git a/config/commands/_split_string.py b/config/commands/_split_string.py
index b21e04d1..900fa4e8 100644
--- a/config/commands/_split_string.py
+++ b/config/commands/_split_string.py
@@ -16,8 +16,6 @@ Where:
# ruff: noqa: UP007 UP006 UP035
-from __future__ import annotations
-
import sys
from dataclasses import dataclass
from typing import List, Optional, Tuple
diff --git a/config/commands/filemap.py b/config/commands/filemap.py
index 425efc42..5b0960b1 100644
--- a/config/commands/filemap.py
+++ b/config/commands/filemap.py
@@ -9,8 +9,6 @@
# description: The path to the file to be read
# required: true
-from __future__ import annotations
-
import argparse
import warnings
diff --git a/pyproject.toml b/pyproject.toml
index 759b326f..4c004406 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -104,7 +104,10 @@ exclude = [
"node_modules",
"site-packages",
"venv",
+ # ---- project specific ----
"tests/test_data",
+ # Exclude commands so they don't get the __future__ imports
+ "config/commands",
]
line-length = 120