Repository navigation
Support wechaty-puppet 2.0.0-alpha.21 and release 0.1.2 - #22
Merged
Merged
Conversation
wechaty@next now pulls wechaty-puppet 2.0.0-alpha.21, and main's clean-install package test failed against it on every platform. - alpha.21 declares every Puppet API method abstract. PuppetUnsupported implements the ones Neo doesn't support yet with the Puppet's own throwUnsupportedError, so calling one (for example messageSendFile from Wechaty's official Ding Dong example) rejects with the unsupported-API error instead of "is not a function". - Its gerror 2 no longer reads `data` from an error payload, so every Neo error reached listeners as "Unknown error (object)". Neo now emits Error objects, which keep their message. - The base Puppet now clears the logged-in user on a timer tick after logout, so the tests wait for that tick. - Under the new dependency tree TypeScript types only jsqr's `.default` as callable; Neo calls that, which is the same function at runtime. - The peer dependency and lockfile move to ^2.0.0-alpha.21. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Bumps the version to 0.1.2 (package.json, package-lock.json, PuppetNeo.VERSION and the README's release example). The publish step no longer passes NPM_TOKEN: npmjs.com now trusts ci.yml in the npm environment, so the v0.1.2 tag publishes with OIDC. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
wechaty@nextnow installswechaty-puppet2.0.0-alpha.21. After #20 merged, main's clean-install package test failed against it on every platform (run), and Neo no longer compiled against alpha.21's types. This PR supports alpha.21 and releases 0.1.2.Changes
Support alpha.21
PuppetUnsupportedbase class implements the APIs Neo doesn't support yet with wechaty-puppet's ownthrowUnsupportedError. Calling one, such asmessageSendFilefrom Wechaty's official Ding Dong example, now rejects with the unsupported-API error instead ofTypeError: puppet.messageSendFile is not a function.GError.from()no longer readsdatafrom an error payload, so every Neo error reachederrorlisteners asUnknown error (object). Neo now emitsErrorobjects, which keep their message.logout, not on the nextsetImmediate, so the two lifecycle tests wait for that tick.jsqr's.defaultas callable. Neo callsjsQR.default, which is the same function at runtime.^2.0.0-alpha.21, and the lockfile resolves 2.0.0-alpha.21 (npm 11.21.2).Release 0.1.2
package.json,package-lock.json,PuppetNeo.VERSIONand the README's release example.wechaty/puppet-neo, workflowci.yml, environmentnpm. The publish step no longer passesNPM_TOKEN, and the secret will be deleted before tagging, sov0.1.2publishes through OIDC.Testing
npm teston Node.js 26 (linux-x64, npm 11.21.2): build and typecheck pass, and 8 of 9 offline tests pass. The ninth loads the compiled addon, which wasn't built locally; CI builds it.ding-dong-bot.tswith Build on the Wechaty 2.0 Puppet #20's build logged in with the account nickname and replieddongto a directding. The example then crashed on its image reply (messageSendFile). This PR turns that into the unsupported-API error. The example still exits, because it has no error handling aroundmsg.say().🤖 Generated with Claude Code