carcabot / tiktok-signature

Generate tiktok signature token using node
752 stars 286 forks source link

[Question] I have a problem. how can i resolve this problem? #85

Closed bjrambo closed 4 years ago

bjrambo commented 4 years ago
/tiktok/tiktok-signature# node listen.js 
TikTok Signature server started
(node:22822) UnhandledPromiseRejectionWarning: Error: WebKit encountered an internal error
====================== page.goto logs ======================
[api] navigating to "https://www.tiktok.com/@rihanna?lang=en", waiting until "load"
============================================================
Note: use DEBUG=pw:api environment variable and rerun to capture Playwright logs.
    at FrameManager.requestFailed (/root/tiktok/node_modules/playwright-webkit/lib/frames.js:197:61)
    at WKPage._onLoadingFailed (/root/tiktok/node_modules/playwright-webkit/lib/webkit/wkPage.js:804:34)
    at WKSession.<anonymous> (/root/tiktok/node_modules/playwright-webkit/lib/webkit/wkPage.js:310:96)
    at WKSession.emit (events.js:315:20)
    at /root/tiktok/node_modules/playwright-webkit/lib/webkit/wkConnection.js:137:47
  -- ASYNC --
    at Frame.goto (/root/tiktok/node_modules/playwright-webkit/lib/helper.js:78:23)
    at /root/tiktok/node_modules/playwright-webkit/lib/page.js:203:61
    at Page._attributeToPage (/root/tiktok/node_modules/playwright-webkit/lib/page.js:356:20)
    at Page.goto (/root/tiktok/node_modules/playwright-webkit/lib/page.js:203:21)
    at Page.goto (/root/tiktok/node_modules/playwright-webkit/lib/helper.js:79:31)
    at Signer.init (/root/tiktok/tiktok-signature/index.js:58:21)
(node:22822) 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:22822) [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.

myserver info

Ubuntu 18.04.1 LTS nodejs v12.18.3 tiktok-signature version -> master branch

how can i fix it?

I searched all day, but I couldn't find any special information to fix the errors related to this.

Most of the libraries have been installed.

The question itself may be too short.

If you have any information you need, please leave a comment.

carcabot commented 4 years ago

Try to debug the error to find out what exactly was using command

DEBUG=pw:api node listen.js

Paste here the error, is most probably something missing.

bjrambo commented 4 years ago

@carcabot

/tiktok/tiktok-signature# DEBUG=pw:api node listen.js
TikTok Signature server started
  pw:api => page.goto started +0ms
  pw:api navigating to "https://www.tiktok.com/@rihanna?lang=en", waiting until "load" [] +1ms
  pw:api <= page.goto failed +642ms
(node:22981) UnhandledPromiseRejectionWarning: Error: WebKit encountered an internal error
====================== page.goto logs ======================
[api] navigating to "https://www.tiktok.com/@rihanna?lang=en", waiting until "load"
============================================================
Note: use DEBUG=pw:api environment variable and rerun to capture Playwright logs.
    at FrameManager.requestFailed (/root/tiktok/node_modules/playwright-webkit/lib/frames.js:197:61)
    at WKPage._onLoadingFailed (/root/tiktok/node_modules/playwright-webkit/lib/webkit/wkPage.js:804:34)
    at WKSession.<anonymous> (/root/tiktok/node_modules/playwright-webkit/lib/webkit/wkPage.js:310:96)
    at WKSession.emit (events.js:315:20)
    at /root/tiktok/node_modules/playwright-webkit/lib/webkit/wkConnection.js:137:47
    at runNextTicks (internal/process/task_queues.js:62:5)
    at processImmediate (internal/timers.js:429:9)
  -- ASYNC --
    at Frame.goto (/root/tiktok/node_modules/playwright-webkit/lib/helper.js:78:23)
    at /root/tiktok/node_modules/playwright-webkit/lib/page.js:203:61
    at Page._attributeToPage (/root/tiktok/node_modules/playwright-webkit/lib/page.js:356:20)
    at Page.goto (/root/tiktok/node_modules/playwright-webkit/lib/page.js:203:21)
    at Page.goto (/root/tiktok/node_modules/playwright-webkit/lib/helper.js:79:31)
    at Signer.init (/root/tiktok/tiktok-signature/index.js:58:21)
(node:22981) 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:22981) [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.

hm..?

carcabot commented 4 years ago

Try also using

DEBUG=* node browser.js ""

You can use Docker if you still can't find out what's the error.

bjrambo commented 4 years ago

i use to Docker, how can i start browser.js in docker?

bjrambo commented 4 years ago

oh i see.

thx! for you're support !

i resolve it!

if you want close issue, you can close it!

but i hope you find "WebKit encountered an internal error" error

thank you.

bjrambo commented 4 years ago

Oh!

i resolve it.

if you problem this issues same,

https://github.com/microsoft/playwright/issues/2447 <- see that.

DEBUG=pw:browser* node listen.js

Keep a close eye on the error. There's the answer.

In my case, I found some libraries that I didn't install.

Thank you.