Summary
skillserver versions <name> for a skill that isn't on the server crashes with an unhandled exception (Aborted (core dumped), exit code 134) instead of printing a clean "not found" and exiting 1. The server returns 404, and VersionsCommand doesn't handle it.
Sibling read commands (verify, download-subagent) already catch the 404 and exit 1 gracefully — versions is the outlier.
Repro
Against any running skill server, query a skill that doesn't exist:
skillserver versions no-such-skill
echo "exit=$?"
Observed
Unhandled exception. System.Net.Http.HttpRequestException: Response status code does not indicate success: 404 (Not Found).
at System.Net.Http.HttpResponseMessage.EnsureSuccessStatusCode()
at System.Net.Http.Json.HttpClientJsonExtensions.<FromJsonAsyncCore>...
at Netclaw.SkillClient.SkillServerClient.GetSkillVersionsAsync(String name, CancellationToken ct) in src/Netclaw.SkillClient/SkillServerClient.cs:line 87
at Netclaw.SkillServer.Cli.Commands.VersionsCommand.ExecuteAsync(ParsedArgs args, SkillServerClient client) in src/Netclaw.SkillServer.Cli/Commands/VersionsCommand.cs:line 25
at Program.<<Main>$>g__DispatchAsync|0_0(...) in src/Netclaw.SkillServer.Cli/Program.cs:line 87
exit=134 (SIGABRT).
Root cause
VersionsCommand.ExecuteAsync (src/Netclaw.SkillServer.Cli/Commands/VersionsCommand.cs:25) calls client.GetSkillVersionsAsync(name), which uses GetFromJsonAsync (src/Netclaw.SkillClient/SkillServerClient.cs:87). GetFromJsonAsync throws HttpRequestException on a 404, and nothing catches it, so the process aborts.
By contrast, VerifyCommand and DownloadSubAgentCommand catch the same 404 and print Error: ... + exit 1.
Expected
A missing skill should print a clean message and exit 1, consistent with the other read commands — e.g.:
Skill 'no-such-skill' not found.
(An explicit "not found" message reads better than the raw Response status code does not indicate success: 404 text those other commands currently surface, so consider that phrasing for the fix.)
Scope
Confirmed on an empty 0.4.0 server:
| Command (missing resource) |
Result |
versions <missing> |
crash, exit 134 |
verify <not-on-server> |
graceful, exit 1 |
download-subagent <missing> <ver> |
graceful, exit 1 |
list / list-subagents (empty) |
exit 0 |
Only versions is affected. Fix can live in VersionsCommand (catch the 404) or in the client (map 404 → empty list / typed not-found); either is fine as long as versions <missing> exits 1 with a readable message and no stack trace.
Environment
- Image:
ghcr.io/netclaw-dev/skillserver:0.4.0
- CLI:
skillserver 0.4.0
Summary
skillserver versions <name>for a skill that isn't on the server crashes with an unhandled exception (Aborted (core dumped), exit code134) instead of printing a clean "not found" and exiting1. The server returns404, andVersionsCommanddoesn't handle it.Sibling read commands (
verify,download-subagent) already catch the 404 and exit1gracefully —versionsis the outlier.Repro
Against any running skill server, query a skill that doesn't exist:
Observed
exit=134(SIGABRT).Root cause
VersionsCommand.ExecuteAsync(src/Netclaw.SkillServer.Cli/Commands/VersionsCommand.cs:25) callsclient.GetSkillVersionsAsync(name), which usesGetFromJsonAsync(src/Netclaw.SkillClient/SkillServerClient.cs:87).GetFromJsonAsyncthrowsHttpRequestExceptionon a 404, and nothing catches it, so the process aborts.By contrast,
VerifyCommandandDownloadSubAgentCommandcatch the same 404 and printError: ...+ exit1.Expected
A missing skill should print a clean message and exit
1, consistent with the other read commands — e.g.:(An explicit "not found" message reads better than the raw
Response status code does not indicate success: 404text those other commands currently surface, so consider that phrasing for the fix.)Scope
Confirmed on an empty 0.4.0 server:
versions <missing>verify <not-on-server>download-subagent <missing> <ver>list/list-subagents(empty)Only
versionsis affected. Fix can live inVersionsCommand(catch the 404) or in the client (map 404 → empty list / typed not-found); either is fine as long asversions <missing>exits1with a readable message and no stack trace.Environment
ghcr.io/netclaw-dev/skillserver:0.4.0skillserver 0.4.0