UAT: SkillService.get_dependents() always returns empty actors list — spec requires actor dependency check before skill removal #3724

Closed
opened 2026-04-05 22:18:40 +00:00 by freemo · 2 comments
Owner

Metadata

  • Branch: fix/v3.6.0/skill-service-get-dependents-actors
  • Commit Message: fix(skill-service): implement actor dependency lookup in get_dependents()
  • Milestone: v3.6.0
  • Parent Epic: #3374

What Was Tested

Code-level analysis of src/cleveragents/application/services/skill_service.py and docs/specification.md.

Expected Behavior (from spec)

Per docs/specification.md, the agents skill remove command must display a "Dependency Check" panel showing:

╭─ Dependency Check ─────────────────────────────────╮
│ Warning: 1 skill includes this skill:              │
│ - local/full-stack-dev (will lose devops tools)    │
│ Warning: 2 actors reference this skill:            │
│ - local/code-assistant                             │
│ - local/full-stack-assistant                       │
╰────────────────────────────────────────────────────╯

Actual Behavior

SkillService.get_dependents() always returns {"skills": [...], "actors": []} with an empty actors list:

def get_dependents(self, name: str) -> dict[str, list[str]]:
    """Find skills and actors that reference a given skill."""
    dependent_skills: list[str] = []
    for sname, skill in self._skills.items():
        if sname == name:
            continue
        for inc in skill.includes:
            if inc.name == name:
                dependent_skills.append(sname)
                break
    return {"skills": dependent_skills, "actors": []}  # ← actors always empty!

The actor lookup is completely unimplemented. The CLI's agents skill remove command uses this method to display the dependency warning, so actors that reference the skill are never shown.

Impact

  • Users removing a skill are not warned about actors that depend on it
  • Actors lose access to their tools without warning
  • The spec-required "Dependency Check" panel is incomplete

Steps to Reproduce

  1. Register a skill local/devops-toolkit
  2. Create an actor that references local/devops-toolkit
  3. Run agents skill remove local/devops-toolkit
  4. Observe: no actor warning is shown in the Dependency Check panel

Code Location

src/cleveragents/application/services/skill_service.pyget_dependents() method

Subtasks

  • Implement actor dependency lookup in get_dependents() by querying the actor registry/service
  • Add Behave tests verifying actor dependents are returned
  • Verify agents skill remove CLI shows actor warnings

Definition of Done

  • get_dependents() returns actors that reference the skill
  • Unit tests verify actor dependency detection
  • agents skill remove CLI shows actor warnings per spec
  • nox -e unit_tests passes
  • All nox stages pass
  • Coverage >= 97%

Automated by CleverAgents Bot
Supervisor: UAT Testing | Agent: ca-new-issue-creator

## Metadata - **Branch**: `fix/v3.6.0/skill-service-get-dependents-actors` - **Commit Message**: `fix(skill-service): implement actor dependency lookup in get_dependents()` - **Milestone**: v3.6.0 - **Parent Epic**: #3374 ## What Was Tested Code-level analysis of `src/cleveragents/application/services/skill_service.py` and `docs/specification.md`. ## Expected Behavior (from spec) Per `docs/specification.md`, the `agents skill remove` command must display a "Dependency Check" panel showing: ``` ╭─ Dependency Check ─────────────────────────────────╮ │ Warning: 1 skill includes this skill: │ │ - local/full-stack-dev (will lose devops tools) │ │ Warning: 2 actors reference this skill: │ │ - local/code-assistant │ │ - local/full-stack-assistant │ ╰────────────────────────────────────────────────────╯ ``` ## Actual Behavior `SkillService.get_dependents()` always returns `{"skills": [...], "actors": []}` with an empty actors list: ```python def get_dependents(self, name: str) -> dict[str, list[str]]: """Find skills and actors that reference a given skill.""" dependent_skills: list[str] = [] for sname, skill in self._skills.items(): if sname == name: continue for inc in skill.includes: if inc.name == name: dependent_skills.append(sname) break return {"skills": dependent_skills, "actors": []} # ← actors always empty! ``` The actor lookup is completely unimplemented. The CLI's `agents skill remove` command uses this method to display the dependency warning, so actors that reference the skill are never shown. ## Impact - Users removing a skill are not warned about actors that depend on it - Actors lose access to their tools without warning - The spec-required "Dependency Check" panel is incomplete ## Steps to Reproduce 1. Register a skill `local/devops-toolkit` 2. Create an actor that references `local/devops-toolkit` 3. Run `agents skill remove local/devops-toolkit` 4. Observe: no actor warning is shown in the Dependency Check panel ## Code Location `src/cleveragents/application/services/skill_service.py` — `get_dependents()` method ## Subtasks - [ ] Implement actor dependency lookup in `get_dependents()` by querying the actor registry/service - [ ] Add Behave tests verifying actor dependents are returned - [ ] Verify `agents skill remove` CLI shows actor warnings ## Definition of Done - [ ] `get_dependents()` returns actors that reference the skill - [ ] Unit tests verify actor dependency detection - [ ] `agents skill remove` CLI shows actor warnings per spec - [ ] `nox -e unit_tests` passes - All nox stages pass - Coverage >= 97% --- **Automated by CleverAgents Bot** Supervisor: UAT Testing | Agent: ca-new-issue-creator
freemo added this to the v3.6.0 milestone 2026-04-05 22:18:58 +00:00
Author
Owner

Label compliance fix applied:

  • Removed: State/In Progress, Type/Automation (conflicting/incorrect labels)
  • Kept: Priority/Medium, Type/Bug
  • Added: State/Unverified
  • Reason: Issue had two State labels (State/In Progress + State/Unverified) and two Type labels (Type/Automation + Type/Bug). Per CONTRIBUTING.md, exactly one of each is required. This is a UAT bug report, so Type/Bug is correct. State/Unverified is the appropriate starting state for a new issue.

Automated by CleverAgents Bot
Supervisor: Backlog Grooming | Agent: ca-backlog-groomer

Label compliance fix applied: - **Removed**: `State/In Progress`, `Type/Automation` (conflicting/incorrect labels) - **Kept**: `Priority/Medium`, `Type/Bug` - **Added**: `State/Unverified` - Reason: Issue had two State labels (`State/In Progress` + `State/Unverified`) and two Type labels (`Type/Automation` + `Type/Bug`). Per CONTRIBUTING.md, exactly one of each is required. This is a UAT bug report, so `Type/Bug` is correct. `State/Unverified` is the appropriate starting state for a new issue. --- **Automated by CleverAgents Bot** Supervisor: Backlog Grooming | Agent: ca-backlog-groomer
Author
Owner

Closing as duplicate of #2824.

This issue describes the exact same bug as #2824 ("UAT: SkillService.get_dependents() always returns empty actors list — spec requires actor dependency tracking"):

  • Same code location: src/cleveragents/application/services/skill_service.py, get_dependents() method
  • Same root cause: actors list always returns empty
  • Same expected behavior: actor registry should be queried

Issue #2824 was created on 2026-04-04 and is already State/In Progress. All work should be tracked under #2824.


Automated by CleverAgents Bot
Supervisor: Backlog Grooming | Agent: ca-backlog-groomer

Closing as duplicate of #2824. This issue describes the exact same bug as #2824 ("UAT: SkillService.get_dependents() always returns empty actors list — spec requires actor dependency tracking"): - Same code location: `src/cleveragents/application/services/skill_service.py`, `get_dependents()` method - Same root cause: `actors` list always returns empty - Same expected behavior: actor registry should be queried Issue #2824 was created on 2026-04-04 and is already `State/In Progress`. All work should be tracked under #2824. --- **Automated by CleverAgents Bot** Supervisor: Backlog Grooming | Agent: ca-backlog-groomer
freemo removed this from the v3.6.0 milestone 2026-04-06 21:07:04 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
cleveragents/cleveragents-core#3724
No description provided.