Skip to content

Commit 795f1e7

Browse files
Copilotmnriem
andauthored
fix: add explanatory comments to all empty except clauses (code quality)
Co-authored-by: mnriem <15701806+mnriem@users.noreply.github.com> Agent-Logs-Url: https://github.com/github/spec-kit/sessions/bb495c08-5d15-410f-9ba9-89d3fc413904
1 parent 55bcbd3 commit 795f1e7

2 files changed

Lines changed: 5 additions & 5 deletions

File tree

src/specify_cli/agent_pack.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -336,7 +336,7 @@ def finalize_setup(
336336
p.resolve().relative_to(agent_root_resolved)
337337
all_agent.append(p)
338338
except ValueError:
339-
pass
339+
pass # Path is outside the agent root — skip it
340340

341341
# Scan the agent's directory tree for files created by later
342342
# init pipeline steps (skills, presets, extensions) that
@@ -665,7 +665,7 @@ def resolve_agent_pack(
665665
emb = AgentManifest.from_yaml(emb_file)
666666
overrides = f"embedded v{emb.version}"
667667
except AgentPackError:
668-
pass
668+
pass # Embedded manifest unreadable — skip override info
669669

670670
return ResolvedPack(
671671
manifest=manifest,

tests/test_agent_pack.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -967,7 +967,7 @@ def _mock_download(
967967
tracker.start(key)
968968
tracker.complete(key, "mocked")
969969
except Exception:
970-
pass
970+
pass # Tracker key may not exist — safe to ignore in mock
971971

972972
flag = "--agent" if use_agent_flag else "--ai"
973973
args = [
@@ -983,7 +983,7 @@ def _mock_download(
983983
if agent in AGENT_SKILLS_MIGRATIONS:
984984
args.append("--ai-skills")
985985
except (ImportError, AttributeError):
986-
pass
986+
pass # AGENT_SKILLS_MIGRATIONS may not exist — proceed without --ai-skills
987987

988988
with _patch(
989989
"specify_cli.download_and_extract_template", _mock_download,
@@ -1151,7 +1151,7 @@ def test_setup_creates_commands_dir(self, agent, agent_projects):
11511151
f"(skills migration removes commands)")
11521152
return
11531153
except (ImportError, AttributeError):
1154-
pass
1154+
pass # AGENT_SKILLS_MIGRATIONS unavailable — fall through to failure
11551155

11561156
pytest.fail(
11571157
f"Agent '{agent}': commands_dir "

0 commit comments

Comments
 (0)