mirror of
https://github.com/misenhower/splatoon3.ink.git
synced 2026-11-18 16:58:18 -06:00
Replace the remaining Node-only dependencies so the updaters and social posters bundle and run in workerd, while the Node runner keeps working: - Replace nxapi with app/splatnet/coral.mjs (fetch + WebCrypto), aligned with nxapi 1.6.1-next.257: znca compatibility 3.5.0, the current client version, and the slimmer Login parameter. Use one znca-api client per Nintendo account, since its token binds to the first account it serves. Cache the remote config in private storage instead of restarting daily. Sessions cached by the nxapi package trigger a fresh login. - Convert images through #image-converter: sharp in Node, the Images binding in Workers. Read Bluesky aspect ratios from the PNG header. - Replace twitter-api-v2 with OAuth 1.0a signed fetch; TwitterClient now only updates the seasonal X profile (posts go through Buffer). - Load avatars through #avatars (bundled as Data modules in Workers) and keep the local Chrome driver out of Worker bundles via #local-screenshot-driver. - prefixedConsole forwards to the global console; shared code reports to Sentry through @sentry/core. Verified live: full credential refresh for all four regions in Node, and the complete Coral → bullet token → GraphQL chain for EU inside workerd. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
10 lines
384 B
JavaScript
10 lines
384 B
JavaScript
// Workers stand-in for #local-screenshot-driver: the local driver needs Chrome, puppeteer and
|
|
// an HTTP server, so it is kept out of the Worker bundle. Workers use the Cloudflare driver.
|
|
export default class LocalScreenshotDriver {
|
|
async open() {
|
|
throw new Error('Local screenshots are not available in Workers; use SCREENSHOT_PROVIDER=cloudflare');
|
|
}
|
|
|
|
async close() {}
|
|
}
|