Contribute/capability check#114
Merged
dgarson merged 1 commit intodgarson:dgarson/forkfrom Mar 3, 2026
Merged
Conversation
dgarson
reviewed
Feb 24, 2026
Owner
dgarson
left a comment
There was a problem hiding this comment.
✅ Overall assessment: Looks good / low-risk
Summary
This PR tightens the agents_list capability-check behavior and improves test coverage for model-handling edge cases:
- Adds coverage that
capableForRequestedModelis omitted when nomodelarg is passed. - Adds coverage that malformed model input (e.g. empty string) does not emit misleading capability metadata.
- Clarifies tool description to document optional model-based capability routing.
What I checked
- Diff scope is small and focused (
agents-list-tool+ e2e tests). - Behavioral intent in tests matches expected contract semantics.
- No obvious security/performance concerns in runtime path from this change.
Concerns / issues found
- No blocking issues found.
Suggestions
- Optional: add one assertion for
modelin provider-only format (if supported contractually) to make parse behavior explicit in tests.
Blocking issues before merge
- None.
…mitted/invalid model
d80fca6 to
620a249
Compare
Author
|
Can this be merged now? @dgarson |
Owner
|
Retriggering CI checks |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
modelfillscapableForRequestedModel; edge cases (no model, bad model) had no tests.agents_listdescription to mention the optionalmodelparam andcapableForRequestedModel; added two e2e tests (nomodel→ all capabilities undefined; unparseablemodel→requestedModeland capabilities undefined).Change Type (select all)
Scope (select all touched areas)
Linked Issue/PR
User-visible / Behavior Changes
None. Description text and tests only.
Security Impact (required)
Repro + Verification
Environment: macOS, Node 22, pnpm
Steps:
pnpm vitest --config vitest.e2e.config.ts src/agents/openclaw-tools.agents.e2e.test.ts --runExpected: 8 tests pass (6 existing + 2 new).
Actual: 8 passed.
Evidence
openclaw-tools.agents.e2e.test.tspassHuman Verification (required)
Compatibility / Migration
Failure Recovery (if this breaks)
Revert the commit or restore
agents-list-tool.tsandopenclaw-tools.agents.e2e.test.tsfrom the PR base. No config or feature flags.Risks and Mitigations
None.