Files
plugins/packages/autoclaw/package.json
T
yetone 57fc069410 autoclaw 0.2.3: usage-path signing remembers each sign-in, not the provider (#254)
With signinOnUsage on, maybeSignin remembered a day's success under the
provider id, so after the first AutoClaw account signed in, every other
account of that provider was skipped until the next day. #254's reporter
has four sign-ins under two default display names and saw exactly one
extra account signed this way. The key is now the sign-in's uid, or a
hash of its refresh token for an old account that has none, for both the
refresh and the usage path.

magpie's own daily check-in (the native checkin hook) skipping same-name
accounts is the main part of #254 and is fixed in magpie itself.

Run:
- bun test packages/autoclaw: 26 pass, 0 fail. The new test drives usage()
  for four accounts sharing one display name (two with uid, two without);
  on the old index.mjs it fails at the second account ("今日未签(+400)").
- HOME=$(mktemp -d) bun test (whole repo): 1865 pass, 1 fail + errors in
  packages/devin's CLI tests (30s timeouts) and a trae stream connection
  reset, at load average ~168; neither package is touched here. Rerun of
  devin+trae alone: 252 pass, 1 devin timeout.
- bun scripts/check.mjs: all packages ok.
2026-10-20 16:26:17 +08:00

35 lines
1.0 KiB
JSON

{
"name": "@magpie-community/opencode-autoclaw-auth",
"version": "0.2.3",
"description": "OpenCode provider plugin for AutoClaw (Zhipu OpenClaw): oversea web sign-in (Google/z.ai) and CN phone SMS, multi-account pool, credit balance and daily check-in",
"type": "module",
"main": "./index.mjs",
"exports": "./index.mjs",
"files": [
"index.mjs",
"README.md"
],
"keywords": [
"opencode",
"opencode-plugin",
"magpie",
"autoclaw",
"zhipu",
"glm"
],
"license": "MIT",
"repository": {
"type": "git",
"url": "git+https://github.com/magpie-community/plugins.git",
"directory": "packages/autoclaw"
},
"magpie": {
"icon": "data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 64'%3E%3Ccircle cx='32' cy='32' r='30' fill='%234f6ef7'/%3E%3Ctext x='32' y='42' font-size='28' text-anchor='middle' fill='white' font-family='sans-serif'%3E%E8%9F%B9%3C/text%3E%3C/svg%3E",
"options": {
"signin": true,
"signinHour": null,
"signinOnUsage": false
}
}
}