webtorrent / parse-torrent

Parse a torrent identifier (magnet uri, .torrent file, info hash)
https://webtorrent.io
MIT License
441 stars 82 forks source link

v10.0.0 — TypeError: parseTorrent.remote is not a function #121

Closed JayBrown closed 1 year ago

JayBrown commented 1 year ago

What version of this package are you using? 10.0.0

What operating system, Node.js, and npm version? macOS 12.3.1 / Node.js 19.1.0 / npm 9.1.2

What happened? error message when running the command-line program:

parse-torrent </path/to/torrent>
file:///usr/local/lib/node_modules/parse-torrent/bin/cmd.js:31
  parseTorrent.remote(torrentId, function (err, parsedTorrent) {
               ^

TypeError: parseTorrent.remote is not a function
    at onTorrentId (file:///usr/local/lib/node_modules/parse-torrent/bin/cmd.js:31:16)
    at file:///usr/local/lib/node_modules/parse-torrent/bin/cmd.js:28:6
    at ModuleJob.run (node:internal/modules/esm/module_job:194:25)

What did you expect to happen? error-free output & correct parsing

Are you willing to submit a pull request to fix this bug? no

ThaUnknown commented 1 year ago
import { remote } from 'parse-torrent'
JayBrown commented 1 year ago

Has no effect on the command-line program, which is what I was using. (Will make it clearer in the bug report.)

ThaUnknown commented 1 year ago

shiiiiiiiiiet