Skip to content

Commit 18d9523

Browse files
committed
fix: lint errors in CLI files
1 parent e3809f0 commit 18d9523

3 files changed

Lines changed: 6 additions & 14 deletions

File tree

src/swe_forge/cli/benchmark.py

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727

2828
from swe_forge.export.jsonl import export_jsonl
2929
from swe_forge.swe.github_api import GitHubClient
30-
from swe_forge.swe.harness import HarnessConfig, HarnessRunner, HarnessStatus
30+
from swe_forge.swe.harness import HarnessConfig, HarnessStatus
3131
from swe_forge.swe.models import SweTask
3232
from swe_forge.swe.pipeline import SwePipeline, SwePipelineConfig
3333

@@ -139,9 +139,7 @@ def benchmark(
139139
)
140140

141141
if difficulty and not validate_difficulty(difficulty):
142-
console.print(
143-
f"[red]Error: Difficulty must be one of: easy, medium, hard[/red]"
144-
)
142+
console.print("[red]Error: Difficulty must be one of: easy, medium, hard[/red]")
145143
raise typer.Exit(code=1)
146144

147145
if not model.strip():
@@ -276,10 +274,7 @@ async def _mine_tasks(
276274
task_id = progress.add_task("Mining tasks...", total=num_tasks)
277275

278276
async with SwePipeline(gh_client, config=config) as pipeline:
279-
from swe_forge.swe.pipeline import (
280-
SwePipelineEvent,
281-
SwePipelineEventType,
282-
)
277+
from swe_forge.swe.pipeline import SwePipelineEventType
283278

284279
async for event in pipeline.run_with_progress():
285280
if event.event_type == SwePipelineEventType.TASK_EXTRACTED:
@@ -468,7 +463,6 @@ def _print_summary(results: list[dict]) -> None:
468463

469464
for status, count in sorted(status_counts.items()):
470465
pct = (count / total_count * 100) if total_count > 0 else 0
471-
style = "green" if status == HarnessStatus.RESOLVED.value else "red"
472466
table.add_row(status, str(count), f"{pct:.1f}%")
473467

474468
console.print(table)

src/swe_forge/cli/harness.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,6 @@ def _print_summary(results: list[dict]) -> None:
213213

214214
for status, count in sorted(status_counts.items()):
215215
pct = (count / total_count * 100) if total_count > 0 else 0
216-
style = "green" if status == HarnessStatus.RESOLVED.value else "red"
217216
table.add_row(status, str(count), f"{pct:.1f}%")
218217

219218
console.print(table)

src/swe_forge/cli/mine.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@
3232
DifficultyTargets,
3333
SwePipeline,
3434
SwePipelineConfig,
35-
SwePipelineEvent,
3635
SwePipelineEventType,
3736
)
3837
from swe_forge.swe.concurrency import set_docker_containers_limit
@@ -295,7 +294,7 @@ async def _run_pipeline(
295294
config: SwePipelineConfig,
296295
repo_filter: Optional[str],
297296
verbose: bool,
298-
) -> "PipelineResult":
297+
):
299298
"""Run the SWE pipeline with progress tracking."""
300299
from dataclasses import dataclass, field
301300

@@ -408,7 +407,7 @@ def mine_complete(
408407

409408
openrouter_key = os.environ.get("OPENROUTER_API_KEY", "")
410409

411-
console.print(f"[bold blue]Complete Mining Pipeline[/bold blue]")
410+
console.print("[bold blue]Complete Mining Pipeline[/bold blue]")
412411
console.print(f" Repository: {repo}")
413412
console.print(f" PR: #{pr}")
414413
console.print(f" Model: {llm_model}")
@@ -450,7 +449,7 @@ async def _run_complete_mining(
450449
model: str,
451450
github_token: str,
452451
openrouter_key: str,
453-
) -> "ValidatedTask | None":
452+
):
454453
"""Run the complete mining pipeline."""
455454
from swe_forge.pipeline import CompleteMiningPipeline
456455
from swe_forge.llm.openrouter import OpenRouterClient

0 commit comments

Comments
 (0)