HouCoder / tele-aria2

A Telegram bot for controlling your aria2 server.
MIT License
266 stars 83 forks source link

[Help] Not sure how to get started. #6

Closed prasanaramanaa closed 4 years ago

prasanaramanaa commented 4 years ago

Hi, I installed tele-aria2 using npm install tele-aria2 -g and got help by tele-aria2 --help without any issue. But when I try to configure it using the given commands, the below error pops up. Please Help me out!

I tried to configure using both:

  1. Terminal by adding tele-aria2 -b 12345:xxxxx -s http://192.168.1.250:6800 -u 123455
  2. Creating Config file and adding by tele-aria2 --config /home/pi/Tele-aria2/tele.conf

But Both the methods shows the same error below.

/usr/local/lib/node_modules/tele-aria2/dist/Aria2.js:62
        this.logger.warn(error.message);
                    ^

TypeError: Cannot read property 'warn' of undefined
    at WebSocket.Aria2.onWsError (/usr/local/lib/node_modules/tele-aria2/dist/Aria2.js:62:21)
    at WebSocket.emit (events.js:198:13)
    at abortHandshake (/usr/local/lib/node_modules/tele-aria2/node_modules/ws/lib/websocket.js:697:15)
    at ClientRequest.req.on (/usr/local/lib/node_modules/tele-aria2/node_modules/ws/lib/websocket.js:579:7)
    at ClientRequest.emit (events.js:198:13)
    at HTTPParser.parserOnIncomingClient [as onIncoming] (_http_client.js:565:21)
    at HTTPParser.parserOnHeadersComplete (_http_common.js:111:17)
    at Socket.socketOnData (_http_client.js:451:20)
    at Socket.emit (events.js:198:13)
    at addChunk (_stream_readable.js:288:12)

As i'm new to this, I am not sure how to get started. I have both telegram bot token and the unique user ID. It would be great if I receive instruction on how to configure tele-aria2 and how to run it as well.

Thank you.

HouCoder commented 4 years ago

This is a bug, but you can avoid this bug by changing server address to http://192.168.1.250:6800/jsonrpc, I'll address this error in the next release.

HouCoder commented 4 years ago

Fixed in the latest beta release, please have a try npm install tele-aria2@0.2.0-beta.13 -g

prasanaramanaa commented 4 years ago

It is working now! Thanks.

Is there anyway I could start this automatically after bootup?

HouCoder commented 4 years ago

not yet, you have to configure it on your own, I'm currently working on the docker image support, you can use docker to manage this tool once the image is ready.

prasanaramanaa commented 4 years ago

Okay! Keep up the great work!