fix: resolve all ruff check failures (F541 f-string placeholders, F401 unused imports, F841 unused variable)

Co-authored-by: mnriem <15701806+mnriem@users.noreply.github.com>
Agent-Logs-Url: https://github.com/github/spec-kit/sessions/e19bd25e-f084-4f38-85b6-8105cbb50494
This commit is contained in:
copilot-swe-agent[bot]
2026-03-23 13:36:36 +00:00
committed by GitHub
parent 978addc390
commit 55bcbd3977
3 changed files with 6 additions and 9 deletions

View File

@@ -2505,7 +2505,7 @@ def agent_info(
if resolved.source == "catalog": if resolved.source == "catalog":
source_display = f"catalog — {resolved.path}" source_display = f"catalog — {resolved.path}"
elif resolved.source == "embedded": elif resolved.source == "embedded":
source_display = f"embedded (bundled in specify-cli wheel)" source_display = "embedded (bundled in specify-cli wheel)"
info_table.add_row("Source", source_display) info_table.add_row("Source", source_display)
if resolved.overrides: if resolved.overrides:
@@ -2871,8 +2871,8 @@ def agent_add(
console.print(f"[green]✓[/green] Installed '{manifest.id}' ({manifest.name}) from {source}") console.print(f"[green]✓[/green] Installed '{manifest.id}' ({manifest.name}) from {source}")
else: else:
# Catalog fetch — placeholder for future catalog integration # Catalog fetch — placeholder for future catalog integration
console.print(f"[yellow]Catalog fetch not yet implemented.[/yellow]") console.print("[yellow]Catalog fetch not yet implemented.[/yellow]")
console.print(f"[dim]Use --from <path> to install from a local directory.[/dim]") console.print("[dim]Use --from <path> to install from a local directory.[/dim]")
raise typer.Exit(1) raise typer.Exit(1)

View File

@@ -563,7 +563,7 @@ def remove_tracked_files(
modified = check_modified_files(project_path, agent_id) modified = check_modified_files(project_path, agent_id)
if modified: if modified:
raise AgentFileModifiedError( raise AgentFileModifiedError(
f"The following agent files have been modified since installation:\n" "The following agent files have been modified since installation:\n"
+ "\n".join(f" {p}" for p in modified) + "\n".join(f" {p}" for p in modified)
+ "\nUse --force to remove them anyway." + "\nUse --force to remove them anyway."
) )

View File

@@ -5,7 +5,6 @@ CLI commands, and consistency with AGENT_CONFIG / CommandRegistrar.AGENT_CONFIGS
""" """
import json import json
import shutil
import textwrap import textwrap
from pathlib import Path from pathlib import Path
@@ -22,7 +21,6 @@ from specify_cli.agent_pack import (
AgentPackError, AgentPackError,
ManifestValidationError, ManifestValidationError,
PackResolutionError, PackResolutionError,
ResolvedPack,
_manifest_path, _manifest_path,
_sha256, _sha256,
check_modified_files, check_modified_files,
@@ -548,9 +546,8 @@ class TestEmbeddedPacksConsistency:
manifest_file = child / MANIFEST_FILENAME manifest_file = child / MANIFEST_FILENAME
if not manifest_file.is_file(): if not manifest_file.is_file():
continue continue
# Should not raise # Should not raise — warnings are acceptable; hard errors are not
warnings = validate_pack(child) validate_pack(child)
# Warnings are acceptable; hard errors are not
# =================================================================== # ===================================================================