ItzBlitz98/torrentflix

tpb search isn't working

oblitum opened this issue · 2 comments

All TPB search gives:

undefined:1
<!DOCTYPE html>
^

SyntaxError: Unexpected token < in JSON at position 0
    at JSON.parse (<anonymous>)
    at Request._callback (/home/username/.config/yarn/global/node_modules/torrentflix/lib/thepiratebay.js:23:21)
    at Request.self.callback (/home/username/.config/yarn/global/node_modules/request/request.js:185:22)
    at Request.emit (events.js:315:20)
    at Request.<anonymous> (/home/username/.config/yarn/global/node_modules/request/request.js:1154:10)
    at Request.emit (events.js:315:20)
    at IncomingMessage.<anonymous> (/home/username/.config/yarn/global/node_modules/request/request.js:1076:12)
    at Object.onceWrapper (events.js:421:28)
    at IncomingMessage.emit (events.js:327:22)
    at endReadableNT (_stream_readable.js:1224:12)

Its working fine for me, In you config file you might need to change thepiratebay.org url to apibay.org, I updated how thepiratebay is scraped recently.

@ItzBlitz98 thx for info, indeed. I had never setup a configuration file, so I didn't even know where it was stored, I executed torrentflix --config nvim to know where it was and simply removed it, when starting again, it created a new one and there was no issue, so it was a default conf upgrade issue.

Fyi, torrentflix --config="nano", etc doesn't work to open configuration (error: unknown option '--config=nano'), I had to use the torrentflix --config nvim syntax.

Another issue is that on every yarn global upgrade I have to vim ~/.config/yarn/global/node_modules/torrentflix/bin/torrentflix and :set ff=unix to avoid #97.

Thanks.