You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 6545692
Browse filesBrowse the repository at this point in the historyBrowse files
zhansheng.lzs
committed
acli: sync 0.6.7 — skills, search_files, platform line, Windows decoding
Vendors agenticCLI 4876f43 plus the 0.6.7 bump. All seven files are
byte-identical to the upstream sources modulo the dashscope. import prefix.
render_skill no longer runs str.format() over a skill body. A body is Markdown
full of literal braces from the JSON and Python it documents, so
text-generation.md — which shows messages=[{"role": "user", ...}] and declares
no arguments at all — raised KeyError('"role"'), and the old `except KeyError`
reported that as "missing args" for a skill that takes none. 6 of the 13
bundled skills were unusable through use_skill while /skill and the catalog
kept advertising them. Substitution is now a plain replace of the declared
arguments only; use_skill and the scheduler branch on `is None` rather than
falsiness, so the missing-args hint can no longer render empty.
search_files matches the pattern against paths relative to the search root as
well as the basename, and skips dot-directories only unless the pattern names
one, so .acli/skills/*.md is reachable without walking every .git in the tree.
Its description now says that * crosses separators, which it does under fnmatch
and did not under the old basename-only match, and the no-match message states
what was actually searched instead of implying the file is absent.
EnvironmentSection states the platform and how run_command executes, through a
new shell_label() that lives next to _spawn so the prompt cannot drift from
what the tool really runs. Nothing used to say which shell this is: on Windows
the model wrote `2>/dev/null || find /` and spent a turn on a PowerShell
ParserError.
Child-process output decoding tries UTF-8 strictly first, then the Windows OEM
code page from GetOEMCP() and the stdio/locale encodings. A piped child writes
in its console's code page, which need not equal sys.stdout.encoding, and cp936
accepts nearly any byte sequence so it would silently mangle UTF-8 rather than
fail. A UnicodeDecodeError in the last four bytes is the byte-budget truncation
splitting a character, not evidence of another encoding, so it is repaired
instead of re-decoding the whole buffer under a DBCS page.
Adds tests/unit/test_acli_skill_render.py: the 13 bundled skill files ship only
in this wheel, so they are the real corpus that broke and the one piece of
coverage with dashscope-only value. Verified by restoring the pre-fix
render_skill — exactly those 6 skills fail, 19 tests — then restoring the fix.
The upstream coverage for the other three fixes stays in agenticCLI, which is
where those test modules live.
dashscope unit: 1011 passed, 7 skipped. pre-commit --all-files green, mypy
included. dashscope/acli/examples/ is untouched by the sync.
0 commit comments