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.