小米快应用调试错误

cocos creator 2.4.11

os macOS m2

> xiaomi-adapter@1.0.0 debug /build/xiaomi
> quickgame debug


2023-03-06T10:10:43.021Z - normal: Debugger setup.

2023-03-06T10:10:43.100Z - normal: tcp:9676 localabstract:webview_devtools_remote_9676

2023-03-06T10:10:43.114Z - normal: Setup port forawrd.

2023-03-06T10:10:43.124Z - normal: Page: quickgame
    Debugger URL: https://devtools.inf.miui.com/inspector/71.0.3578.132/inspector.html?remoteFrontend=true&dockSide=undocked&ws=127.0.0.1:9676/devtools/page/191104FDF490876044070738A4152EB3

2023-03-06T10:10:43.206Z - error: (node:64006) UnhandledPromiseRejectionWarning: null

    at Socket.<anonymous> (/CocosDashboard/Creator/2.4.11/CocosCreator.app/Contents/Resources/app.asar/editor/builtin/xiaomi-runtime/panel/scanCode.ccc:1:1455)
    at Socket.emit (events.js:315:20)
    at addChunk (internal/streams/readable.js:309:12)
    at readableAddChunk (internal/streams/readable.js:284:9)
    at Socket.Readable.push (internal/streams/readable.js:223:10)
    at Pipe.onStreamRead (internal/stream_base_commons.js:188:23)
2023-03-06T10:10:43.206Z - error: (node:64006) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
(node:64006) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

    at Socket.<anonymous> (/CocosDashboard/Creator/2.4.11/CocosCreator.app/Contents/Resources/app.asar/editor/builtin/xiaomi-runtime/panel/scanCode.ccc:1:1455)
    at Socket.emit (events.js:315:20)
    at addChunk (internal/streams/readable.js:309:12)
    at readableAddChunk (internal/streams/readable.js:284:9)
    at Socket.Readable.push (internal/streams/readable.js:223:10)
    at Pipe.onStreamRead (internal/stream_base_commons.js:188:23)

应用启动白屏 终端一直打印 未登录

使用usb调试发现错误

./main.js:131981 Uncaught (in promise) TypeError: Illegal invocation
    at canUsePostMessage (/android_asset/game/main.js:131981)
    at eval (/android_asset/game/main.js:132055)
    at Object.eval (/android_asset/game/main.js:132074)
    at Object.54 (/android_asset/game/main.js:132076)
    at s (/android_asset/game/main.js:120518)
    at eval (/android_asset/game/main.js:120518)
    at Object.32../base64 (/android_asset/game/main.js:123551)
    at s (/android_asset/game/main.js:120518)
    at eval (/android_asset/game/main.js:120518)
    at Object.31../nodejsUtils (/android_asset/game/main.js:123270)

对应代码

                    function canUsePostMessage() {
                        // The test against `importScripts` prevents this implementation from being installed inside a web worker,
                        // where `global.postMessage` means something completely different and can't be used for this purpose.
                        if (global.postMessage && !global.importScripts) {
                            var postMessageIsAsynchronous = true;
                            var oldOnMessage = global.onmessage;
                            global.onmessage = function () {
                                postMessageIsAsynchronous = false;
                            };
                            global.postMessage("", "*");
                            global.onmessage = oldOnMessage;
                            return postMessageIsAsynchronous;
                        }
                    }

没有人遇到过吗?

这个是两个问题,一个是jszip莫名其妙的报错,还有一个是protobuf问题(相关)

jszip的那个问题,我也遇到了,问问老哥最后怎么解决的?
img_v3_026h_114ba6e1-02f0-4686-bfbd-1c9b957ef9dg