fabiospampinato / cliflix

Watch anything instantaneously, just write its name.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

There may be a bug in latest version

Gastonm123 opened this issue · comments

Hello!! I've just downloaded and installed cliflix following the guide in the readme file and when I wanted to start watching a movie I got stopped by a bug.

The debug info says that in the file and line
/usr/local/lib/node_modules/cliflix/node_modules/webtorrent/lib/server.js:81
const pathname = new URL(req.url, 'http://example.com').pathname

There's a ReferenceError because URL is undefined.

Thank you in advance..

Can you paste the actual stack trace?

This is what appears in my console when VLC launches

UNEXPECTED ERROR: If this is a bug in WebTorrent, report it!
OPEN AN ISSUE: https://github.com/webtorrent/webtorrent-cli/issues

DEBUG INFO: webtorrent-cli 1.12.3, webtorrent 0.107.6, node v8.10.0, linux x64, exit 1
/usr/local/lib/node_modules/cliflix/node_modules/webtorrent/lib/server.js:81
const pathname = new URL(req.url, 'http://example.com').pathname
^

TypeError: URL is not a constructor
at Server.onRequest (/usr/local/lib/node_modules/cliflix/node_modules/webtorrent/lib/server.js:81:22)
at emitTwo (events.js:126:13)
at Server.emit (events.js:214:7)
at parserOnIncoming (_http_server.js:619:12)
at HTTPParser.parserOnHeadersComplete (_http_common.js:115:23)
(node:12552) UnhandledPromiseRejectionWarning: Error: null
at Function.module.exports.sync (/usr/local/lib/node_modules/cliflix/node_modules/execa/index.js:303:26)
at Object. (/usr/local/lib/node_modules/cliflix/dist/index.js:258:23)
at step (/usr/local/lib/node_modules/cliflix/dist/index.js:33:23)
at Object.next (/usr/local/lib/node_modules/cliflix/dist/index.js:14:53)
at /usr/local/lib/node_modules/cliflix/dist/index.js:8:71
at new Promise ()
at __awaiter (/usr/local/lib/node_modules/cliflix/dist/index.js:4:12)
at Object.stream (/usr/local/lib/node_modules/cliflix/dist/index.js:250:16)
at Object. (/usr/local/lib/node_modules/cliflix/dist/index.js:101:33)
at step (/usr/local/lib/node_modules/cliflix/dist/index.js:33:23)
at Object.next (/usr/local/lib/node_modules/cliflix/dist/index.js:14:53)
at fulfilled (/usr/local/lib/node_modules/cliflix/dist/index.js:5:58)
at
(node:12552) 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(). (rejection id: 2)
(node:12552) [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.

It may be an error caused by a dependency error. I've been struggling with these kinds of errors a lot these last weeks.

Update node and this error should go away.