Navigation

    Logo
    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unread
    • Categories
    • Unreplied
    • Popular
    • GitHub
    • Docu
    • Hilfe
    1. Home
    2. Русский
    3. ioBroker
    4. ioBroker драйвера
    5. Драйвер Telegram Adapter

    NEWS

    • Neuer Blog: Fotos und Eindrücke aus Solingen

    • ioBroker@Smart Living Forum Solingen, 14.06. - Agenda added

    • ioBroker goes Matter ... Matter Adapter in Stable

    Драйвер Telegram Adapter

    This topic has been deleted. Only users with topic management privileges can see it.
    • T
      tinick last edited by

      @Haba:

      Пример скрипта для inline кнопок

      ! ````
      on({id: "telegram.0.communicate.request", ack: false, change: 'any'}, function (obj) {
      //log(obj.state.val);
      command = obj.state.val.substring(obj.state.val.indexOf(']')+1);
      user = obj.state.val.substring(obj.state.val.indexOf('[')+1,obj.state.val.indexOf(']'));

      if (command ==="меню") { // ждем сообщение от пользователя "меню"
          sendTo('telegram', {
              user: user,
              text:   'Выберите кнопку',
              reply_markup: {
                  inline_keyboard: [
                      [{ text: '\u{2714} Button 1_1', callback_data: '1_1' }, { text: '\u{2705} Button 1_2', callback_data: '1_2' }],
                      [{ text: 'Button 1_3', callback_data: '1_3' }],
                  ],
              }
          }); 
      }
      if (command ==="1_1") { // нажата кнопка Button 1_1
          log("message_id = " + getState("telegram.0.communicate.requestMessageId").val);
          sendTo('telegram', {
              user: user,
              text:   'Замена кнопок',
              editMessageReplyMarkup: {
                  options: {
                      chat_id: getState("telegram.0.communicate.requestChatId").val, 
                      message_id: getState("telegram.0.communicate.requestMessageId").val
                  },
                  reply_markup: {
                      inline_keyboard: [
                          [{ text: 'button 1', callback_data: '2_1' }],
                          [{ text: 'button 2', callback_data: '2_2' }]
                      ],
                  }
              }
          });
      }
      if (command ==="1_2") { // нажата кнопка Button 1_2
          log("message_id = " + getState("telegram.0.communicate.requestMessageId").val);
          sendTo('telegram', {
              user: user,
              text:   'Кнопка 1_2 нажата',
              answerCallbackQuery: {
                  text: "Есть нажатие!",
                  showAlert: false
              }
          });
      }
      if (command ==="2_1") { // нажата кнопка Button 2_1
          log("message_id = " + getState("telegram.0.communicate.requestMessageId").val);
          sendTo('telegram', {
      

      // user: user,
      text: 'Назад',
      editMessageReplyMarkup: {
      options: {
      chat_id: getState("telegram.0.communicate.requestChatId").val,
      message_id: getState("telegram.0.communicate.requestMessageId").val
      },
      reply_markup: {
      inline_keyboard: [
      [{ text: '\u{2714} Button 1_1', callback_data: '1_1' }, { text: '\u{2705} Button 1_2', callback_data: '1_2' }],
      [{ text: 'Button 1_3', callback_data: '1_3' }],
      ],
      resize_keyboard: true,
      one_time_keyboard: true
      }
      }
      });
      }
      if (command ==="1_3") { // нажата кнопка Button 1_3
      sendTo('telegram', {
      user: user,
      text: 'Конец',
      editMessageText: {
      options: {
      chat_id: getState("telegram.0.communicate.requestChatId").val,
      message_id: getState("telegram.0.communicate.requestMessageId").val,
      }
      }
      });
      }
      });
      ```` `

      Попробовал у себя данный скрипт, но почему у меня не получается вылавливать нажатие inline кнопок…

      1 Reply Last reply Reply Quote 0
      • H
        Haba last edited by

        tinick код скрипта напиши сюда

        1 Reply Last reply Reply Quote 0
        • T
          tinick last edited by

          @Haba:

          tinick код скрипта напиши сюда `

          ! on({id: "telegram.0.communicate.request", ack: false, change: 'any'}, function (obj) {
          ! //log(obj.state.val);
          ! command = obj.state.val.substring(obj.state.val.indexOf(']')+1);
          ! user = obj.state.val.substring(obj.state.val.indexOf('[')+1,obj.state.val.indexOf(']'));
          ! if (command ==="меню") { // ждем сообщение от пользователя "меню"
          ! sendTo('telegram', {
          ! user: user,
          ! text: 'Выберите кнопку',
          ! reply_markup: {
          ! inline_keyboard: [
          ! [{ text: 'Кнопка', callback_data: 'OK' }],
          ! ],
          ! }
          ! });
          ! }
          ! if (command ==="OK") { // нажата кнопка
          ! sendTo('telegram', {
          ! user: user,
          ! text: 'Конец',
          ! editMessageText: {
          ! options: {
          ! chat_id: getState("telegram.0.communicate.requestChatId").val,
          ! message_id: getState("telegram.0.communicate.requestMessageId").val,
          ! }
          ! }
          ! });
          ! }
          ! });
          При нажатии на кнопку высвечиваются часы, но дальнейшая команда не проходит. В телеграмме висит команда "меню"
          1226_______1.png
          1226_______2.png

          1 Reply Last reply Reply Quote 0
          • H
            Haba last edited by

            Драйвер какой версии стоит? Должен быть 1.0.6, сужу по тому, что у тебя в объектах телеграмма нет telegram.0.communicate.requestMessageId.

            Если версия 1.0.6, то надо удалить установленный драйвер и еще раз его поставить, чтобы появился выше указанный объект. Без него inline не будет работать.

            Ты в коде как раз пытаешься считать несуществующий объект

            message_id: getState("telegram.0.communicate.requestMessageId").val,

            1 Reply Last reply Reply Quote 0
            • D
              dimon last edited by

              @Haba:

              Пример №2 Структура меню и действия

              ! ```
              `var button = [{name: 'меню',button: ['Комната 1','Комната 2','Закрыть','меню']},
              {name: 'Комната 1',button: ['Сценарии','Ручное управление','Назад','Закрыть','меню']},
              {name: 'Сценарии', button: ['Сцена 1','Сцена 2','Назад','Закрыть','Комната 1']},
              {name: 'Ручное управление', button: ['Действие 3','Действие 4','Назад','Закрыть','Комната 1']},
              {name: 'Комната 2', button: ['Действие 1','Действие 2','Назад','Закрыть','меню']}
              ];
              ! var menuUp = 'меню';
              var first_tap = false;
              ! on({id: "telegram.0.communicate.request", ack: false, change: 'any'}, function (obj) {
              command = obj.state.val.substring(obj.state.val.indexOf(']')+1);
              user = obj.state.val.substring(obj.state.val.indexOf('[')+1,obj.state.val.indexOf(']'));
              //************************************
              // меню
              //************************************
              var menu = {
              reply_markup: {
              inline_keyboard: [[],[]],
              }
              };

              log("message_id = " + getState("telegram.0.communicate.requestMessageId").val);
              log("menuUp = " + menuUp);
              if (command === 'меню') first_tap = true;
              if (command === 'Назад') command = menuUp;
              var but1 = getButtonArray(button, 'name', command).toString();
              
              if (but1.length > 0) {          // проверяем, что строка не пустая
                  var but2 = but1.split(','); //преобразуем в массив
                  menuUp = but2.pop();        //вырезаем последний элемент
                  log ("but2 = " + JSON.stringify(but2));
                  if (but2.length > 0) {      // проверяем что массив не пуст
                      var index = 0;
                      for (var i=0, len=but2.length; i <len; i++)/{/if/((i="">1)&&(index < 1)) index = ++index;
                          menu.reply_markup.inline_keyboard[index].push({ text: but2[i], callback_data: but2[i]});
                      }
                      log(JSON.stringify(menu.reply_markup.inline_keyboard));
                      if (first_tap) {
                          sendTo('telegram.0', {user: user, text: 'Меню ' + command, reply_markup: menu.reply_markup});
                          first_tap = false;
                      } else sendTo('telegram', { 
                              user: user, 
                              text: 'Меню ' + command, 
                              editMessageText: { 
                                  options: { 
                                      chat_id: getState("telegram.0.communicate.requestChatId").val, 
                                      message_id: getState("telegram.0.communicate.requestMessageId").val, 
                                      reply_markup: menu.reply_markup
                                  }    
                              } 
                          });
                  }
              } else log("but1 пуст");
              

              //************************************
              // Команды
              //************************************
              // ищем в тексте команды
              if (command ==="Действие 1") {
              //тут код что надо сделать
              CommandDone();
              }

              ! if (command ==="Закрыть") {
              sendTo('telegram', {
              user: user,
              text: 'Конец',
              editMessageText: {
              options: {
              chat_id: getState("telegram.0.communicate.requestChatId").val,
              message_id: getState("telegram.0.communicate.requestMessageId").val,
              }
              }
              });
              }
              });
              ! function CommandDone(){
              sendTo('telegram', {
              user: user,
              text: 'Выполняю...',
              editMessageText: {
              options: {
              chat_id: getState("telegram.0.communicate.requestChatId").val,
              message_id: getState("telegram.0.communicate.requestMessageId").val,
              }
              }
              });
              }
              ! function getButtonArray(obj, keyName, Name) {
              var result = [];
              for (var attr in obj) {
              if (obj[attr] && typeof obj[attr] === 'object') {
              result = result.concat(getButtonArray(obj[attr], keyName, Name));
              }
              if (attr === keyName && obj[attr] === Name) {
              result.push(obj.button);
              }
              }
              return result;
              }</len;> ! ЗЫ. Код до конца не оптимизирован, есть еще куда стремиться ;) ! Использую твое меню с небольшими доработками. Прошу помочь с редактированием сообщений. Такой код:~~[code]~~if (command ==="Действие 1") {
              sendTo('telegram', {
              user: user,
              text: 'Что-нибудь написано',
              editMessageText: {
              options: {
              chat_id: getState("telegram.0.communicate.requestChatId").val,
              message_id: getState("telegram.0.communicate.requestMessageId").val,
              }
              }
              });
              }[/code]! меняет сообщение на "Что-нибудь написано" и затирает клавиатуру. ! А хотелось бы, чтобы клавиатура оставалась на месте, а вывод был в сообщение над клавиатурой. Вот так: ! ![](http://pics.4minipc.ru/images/2018/03/28/2018-03-28_00-19-56.png)~~[img]~~[http://pics.4minipc.ru/images/2018/03/2 ... -19-56.png](http://pics.4minipc.ru/images/2018/03/28/2018-03-28_00-19-56.png)[/img] ! Буду благодарен за подсказку.[/i][/i] ```

              1 Reply Last reply Reply Quote 0
              • H
                Haba last edited by

                актуально еще?

                тебе надо в options добавить клавиатуру с этими кнопками reply_markup : … описание кнопок.

                Т.к. ты этого не делаешь, драйвер предыдущие затирает

                1 Reply Last reply Reply Quote 0
                • S
                  smoker_vvo last edited by

                  Вашу м…ть...... Обновил Драйвер и получил вот это

                  telegram.0 2018-04-16 21:42:30.175 error polling_error:EFATAL, EFATAL: Error: read ECONNRESET

                  как с этим бороться.

                  1 Reply Last reply Reply Quote 0
                  • S
                    smoker_vvo last edited by

                    Или это последствия Суда…...

                    1 Reply Last reply Reply Quote 0
                    • S
                      spectrekr last edited by

                      Или … 🙂

                      1 Reply Last reply Reply Quote 0
                      • H
                        hubbatov last edited by

                        Никто не занимался установкой прокси для драйвера по аналогии с десктопным приложением?

                        1 Reply Last reply Reply Quote 0
                        • I
                          instalator last edited by

                          https://github.com/Haba1234/ioBroker.telegram ставь эту, в настройках настройки прокси, это ещё тестовая версия

                          1 Reply Last reply Reply Quote 0
                          • P
                            Pooh last edited by

                            Новая версия (1.2.1) через SOCKS в режиме пинг работает, в режиме сервер не работает 😞

                            Куда копать?

                            1 Reply Last reply Reply Quote 0
                            • goofyk
                              goofyk last edited by

                              копать сюда https://github.com/kirovilya/ioBroker.telegram

                              сделал PR в основной репозиторий, ждем обновления драйвера

                              1 Reply Last reply Reply Quote 0
                              • S
                                smoker_vvo last edited by

                                Обновил драйвер, да же настроил прокси…...

                                Но вы итоге......

                                ! host.GoldFish2 2018-05-01 19:57:28.888 info instance system.adapter.telegram.0 started with pid 7164
                                ! host.GoldFish2 2018-05-01 19:57:27.868 info Restart adapter system.adapter.telegram.0 because enabled
                                ! host.GoldFish2 2018-05-01 19:57:27.868 error instance system.adapter.telegram.0 terminated with code 0 (OK)
                                ! host.GoldFish2 2018-05-01 19:57:27.868 error Caught by controller[1]: port: 443 }
                                ! host.GoldFish2 2018-05-01 19:57:27.868 error Caught by controller[1]: address: '88.212.233.100',
                                ! host.GoldFish2 2018-05-01 19:57:27.868 error Caught by controller[1]: syscall: 'connect',
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: errno: 'ETIMEDOUT',
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: code: 'ETIMEDOUT',
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1087:14)
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: at exports._exceptionWithHostPort (util.js:1045:20)
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: at Object.exports._errnoException (util.js:1022:11)
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: { Error: connect ETIMEDOUT 88.212.233.100:443
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: port: 443 }
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: address: '88.212.233.100',
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: syscall: 'connect',
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: errno: 'ETIMEDOUT',
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: code: 'ETIMEDOUT',
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1087:14)
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: at exports._exceptionWithHostPort (util.js:1045:20)
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: at Object.exports._errnoException (util.js:1022:11)
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: { Error: connect ETIMEDOUT 88.212.233.100:443
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: port: 443 }
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: address: '88.212.233.100',
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: syscall: 'connect',
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: errno: 'ETIMEDOUT',
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: code: 'ETIMEDOUT',
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1087:14)
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: at exports._exceptionWithHostPort (util.js:1045:20)
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: at Object.exports._errnoException (util.js:1022:11)
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[1]: { Error: connect ETIMEDOUT 88.212.233.100:443
                                ! host.GoldFish2 2018-05-01 19:57:27.867 error Caught by controller[0]: See https://github.com/yagop/node-telegram- … issues/319. at module.js:570:32
                                ! host.GoldFish2 2018-05-01 19:57:27.866 error Caught by controller[0]: In the future, you will have to enable it yourself.
                                ! host.GoldFish2 2018-05-01 19:57:27.866 error Caught by controller[0]: Tue, 01 May 2018 09:57:05 GMT node-telegram-bot-api deprecated Automatic enabling of cancellation of promises is deprecated.
                                ! telegram.0 2018-05-01 19:57:27.354 error Error: connect ETIMEDOUT 88.212.233.100:443 at Object.exports._errnoException (util.js:1022:11) at exports._exceptionWithHostPort (util.js:1045:20) at TCPConnectWrap.afterConnect [as oncom
                                ! telegram.0 2018-05-01 19:57:27.354 error uncaught exception: connect ETIMEDOUT 88.212.233.100:443
                                ! telegram.0 2018-05-01 19:57:27.354 error Error: connect ETIMEDOUT 88.212.233.100:443 at Object.exports._errnoException (util.js:1022:11) at exports._exceptionWithHostPort (util.js:1045:20) at TCPConnectWrap.afterConnect [as oncom
                                ! telegram.0 2018-05-01 19:57:27.354 error uncaught exception: connect ETIMEDOUT 88.212.233.100:443
                                ! telegram.0 2018-05-01 19:57:27.354 error Error: connect ETIMEDOUT 88.212.233.100:443 at Object.exports._errnoException (util.js:1022:11) at exports._exceptionWithHostPort (util.js:1045:20) at TCPConnectWrap.afterConnect [as oncom
                                ! telegram.0 2018-05-01 19:57:27.353 error uncaught exception: connect ETIMEDOUT 88.212.233.100:443
                                ! telegram.0 2018-05-01 19:57:06.323 info starting. Version 1.2.3 in C:/ioBroker/node_modules/iobroker.telegram, node: v6.9.5
                                ! host.GoldFish2 2018-05-01 19:56:56.386 info instance system.adapter.telegram.0 started with pid 7240
                                ! host.GoldFish2 2018-05-01 19:56:55.357 info Restart adapter system.adapter.telegram.0 because enabled

                                Куда рыть дальше??? Или какой прокси использовать??

                                1 Reply Last reply Reply Quote 0
                                • ViR
                                  ViR last edited by

                                  Добрый день тоже сыпятся ошибки при настройки прокси:

                                  ! host.orangepipcplus 2018-05-09 12:22:13.425 error instance system.adapter.telegram.0 terminated with code 0 (OK)
                                  ! Caught 2018-05-09 12:22:13.425 error by controller[3]: at TCP.onread (net.js:607:20) code: 'EAUTHNOTSUPPORT' }
                                  ! Caught 2018-05-09 12:22:13.425 error by controller[3]: at Socket.Readable.push (_stream_readable.js:208:10)
                                  ! Caught 2018-05-09 12:22:13.425 error by controller[3]: at readableAddChunk (_stream_readable.js:250:11)
                                  ! Caught 2018-05-09 12:22:13.424 error by controller[3]: at addChunk (_stream_readable.js:263:12)
                                  ! Caught 2018-05-09 12:22:13.424 error by controller[3]: at Socket.emit (events.js:211:7)
                                  ! Caught 2018-05-09 12:22:13.424 error by controller[3]: at emitOne (events.js:116:13)
                                  ! Caught 2018-05-09 12:22:13.424 error by controller[3]: at Socket.Parser.__onData (/opt/iobroker/node_modules/iobroker.telegram/node_modules/socksv5/lib/client.parser.js:33:10)
                                  ! Caught 2018-05-09 12:22:13.423 error by controller[3]: at Parser._onData (/opt/iobroker/node_modules/iobroker.telegram/node_modules/socksv5/lib/client.parser.js:85:14)
                                  ! Caught 2018-05-09 12:22:13.423 error by controller[3]: at Parser.emit (events.js:211:7)
                                  ! Caught 2018-05-09 12:22:13.423 error by controller[3]: at emitOne (events.js:116:13)
                                  ! Caught 2018-05-09 12:22:13.423 error by controller[3]: at Parser. <anonymous>(/opt/iobroker/node_modules/iobroker.telegram/node_modules/socksv5/lib/client.js:102:15)
                                  ! Caught 2018-05-09 12:22:13.422 error by controller[3]: { Error: Authentication method mismatch
                                  ! Caught 2018-05-09 12:22:13.422 error by controller[2]: at TCP.onread (net.js:607:20) code: 'EAUTHNOTSUPPORT' }
                                  ! Caught 2018-05-09 12:22:13.422 error by controller[2]: at Socket.Readable.push (_stream_readable.js:208:10)
                                  ! Caught 2018-05-09 12:22:13.422 error by controller[2]: at readableAddChunk (_stream_readable.js:250:11)
                                  ! Caught 2018-05-09 12:22:13.421 error by controller[2]: at addChunk (_stream_readable.js:263:12)
                                  ! Caught 2018-05-09 12:22:13.421 error by controller[2]: at Socket.emit (events.js:211:7)
                                  ! Caught 2018-05-09 12:22:13.421 error by controller[2]: at emitOne (events.js:116:13)
                                  ! Caught 2018-05-09 12:22:13.421 error by controller[2]: at Socket.Parser.__onData (/opt/iobroker/node_modules/iobroker.telegram/node_modules/socksv5/lib/client.parser.js:33:10)
                                  ! Caught 2018-05-09 12:22:13.420 error by controller[2]: at Parser._onData (/opt/iobroker/node_modules/iobroker.telegram/node_modules/socksv5/lib/client.parser.js:85:14)
                                  ! Caught 2018-05-09 12:22:13.420 error by controller[2]: at Parser.emit (events.js:211:7)
                                  ! Caught 2018-05-09 12:22:13.420 error by controller[2]: at emitOne (events.js:116:13)
                                  ! Caught 2018-05-09 12:22:13.420 error by controller[2]: at Parser. <anonymous>(/opt/iobroker/node_modules/iobroker.telegram/node_modules/socksv5/lib/client.js:102:15)
                                  ! Caught 2018-05-09 12:22:13.420 error by controller[2]: { Error: Authentication method mismatch
                                  ! Caught 2018-05-09 12:22:13.419 error by controller[1]: at TCP.onread (net.js:607:20) code: 'EAUTHNOTSUPPORT' }
                                  ! Caught 2018-05-09 12:22:13.419 error by controller[1]: at Socket.Readable.push (_stream_readable.js:208:10)
                                  ! Caught 2018-05-09 12:22:13.419 error by controller[1]: at readableAddChunk (_stream_readable.js:250:11)
                                  ! Caught 2018-05-09 12:22:13.419 error by controller[1]: at addChunk (_stream_readable.js:263:12)
                                  ! Caught 2018-05-09 12:22:13.418 error by controller[1]: at Socket.emit (events.js:211:7)
                                  ! Caught 2018-05-09 12:22:13.418 error by controller[1]: at emitOne (events.js:116:13)
                                  ! Caught 2018-05-09 12:22:13.418 error by controller[1]: at Socket.Parser.__onData (/opt/iobroker/node_modules/iobroker.telegram/node_modules/socksv5/lib/client.parser.js:33:10)
                                  ! Caught 2018-05-09 12:22:13.418 error by controller[1]: at Parser._onData (/opt/iobroker/node_modules/iobroker.telegram/node_modules/socksv5/lib/client.parser.js:85:14)
                                  ! Caught 2018-05-09 12:22:13.417 error by controller[1]: at Parser.emit (events.js:211:7)
                                  ! Caught 2018-05-09 12:22:13.417 error by controller[1]: at emitOne (events.js:116:13)
                                  ! Caught 2018-05-09 12:22:13.417 error by controller[1]: at Parser. <anonymous>(/opt/iobroker/node_modules/iobroker.telegram/node_modules/socksv5/lib/client.js:102:15)
                                  ! Caught 2018-05-09 12:22:13.417 error by controller[1]: { Error: Authentication method mismatch
                                  ! Caught 2018-05-09 12:22:13.416 error by controller[0]: See https://github.com/yagop/node-telegram- … issues/319. at module.js:652:30
                                  ! Caught 2018-05-09 12:22:13.416 error by controller[0]: In the future, you will have to enable it yourself.
                                  ! Caught 2018-05-09 12:22:13.415 error by controller[0]: Wed, 09 May 2018 02:22:11 GMT node-telegram-bot-api deprecated Automatic enabling of cancellation of promises is deprecated.
                                  ! telegram.0 2018-05-09 12:22:13.324 info terminating
                                  ! telegram.0 2018-05-09 12:22:12.816 error at TCP.onread (net.js:607:20)
                                  ! telegram.0 2018-05-09 12:22:12.816 error at Socket.Readable.push (_stream_readable.js:208:10)
                                  ! telegram.0 2018-05-09 12:22:12.816 error at readableAddChunk (_stream_readable.js:250:11)
                                  ! telegram.0 2018-05-09 12:22:12.816 error at addChunk (_stream_readable.js:263:12)
                                  ! telegram.0 2018-05-09 12:22:12.816 error at Socket.emit (events.js:211:7)
                                  ! telegram.0 2018-05-09 12:22:12.816 error at emitOne (events.js:116:13)
                                  ! telegram.0 2018-05-09 12:22:12.816 error at Socket.Parser.__onData (/opt/iobroker/node_modules/iobroker.telegram/node_modules/socksv5/lib/client.parser.js:33:10)
                                  ! telegram.0 2018-05-09 12:22:12.816 error at Parser._onData (/opt/iobroker/node_modules/iobroker.telegram/node_modules/socksv5/lib/client.parser.js:85:14)
                                  ! telegram.0 2018-05-09 12:22:12.816 error at Parser.emit (events.js:211:7)
                                  ! telegram.0 2018-05-09 12:22:12.816 error at emitOne (events.js:116:13)
                                  ! telegram.0 2018-05-09 12:22:12.816 error at Parser. <anonymous>(/opt/iobroker/node_modules/iobroker.telegram/node_modules/socksv5/lib/client.js:102:15)
                                  ! telegram.0 2018-05-09 12:22:12.816 error Error: Authentication method mismatch
                                  ! telegram.0 2018-05-09 12:22:12.815 error uncaught exception: Authentication method mismatch
                                  ! telegram.0 2018-05-09 12:22:12.809 error at TCP.onread (net.js:607:20)
                                  ! telegram.0 2018-05-09 12:22:12.809 error at Socket.Readable.push (_stream_readable.js:208:10)
                                  ! telegram.0 2018-05-09 12:22:12.809 error at readableAddChunk (_stream_readable.js:250:11)
                                  ! telegram.0 2018-05-09 12:22:12.809 error at addChunk (_stream_readable.js:263:12)
                                  ! telegram.0 2018-05-09 12:22:12.809 error at Socket.emit (events.js:211:7)
                                  ! telegram.0 2018-05-09 12:22:12.809 error at emitOne (events.js:116:13)
                                  ! telegram.0 2018-05-09 12:22:12.809 error at Socket.Parser.__onData (/opt/iobroker/node_modules/iobroker.telegram/node_modules/socksv5/lib/client.parser.js:33:10)
                                  ! telegram.0 2018-05-09 12:22:12.809 error at Parser._onData (/opt/iobroker/node_modules/iobroker.telegram/node_modules/socksv5/lib/client.parser.js:85:14)
                                  ! telegram.0 2018-05-09 12:22:12.809 error at Parser.emit (events.js:211:7)
                                  ! telegram.0 2018-05-09 12:22:12.809 error at emitOne (events.js:116:13)
                                  ! telegram.0 2018-05-09 12:22:12.809 error at Parser. <anonymous>(/opt/iobroker/node_modules/iobroker.telegram/node_modules/socksv5/lib/client.js:102:15)
                                  ! telegram.0 2018-05-09 12:22:12.809 error Error: Authentication method mismatch
                                  ! telegram.0 2018-05-09 12:22:12.808 error uncaught exception: Authentication method mismatch
                                  ! telegram.0 2018-05-09 12:22:12.798 error at TCP.onread (net.js:607:20)
                                  ! telegram.0 2018-05-09 12:22:12.798 error at Socket.Readable.push (_stream_readable.js:208:10)
                                  ! telegram.0 2018-05-09 12:22:12.798 error at readableAddChunk (_stream_readable.js:250:11)
                                  ! telegram.0 2018-05-09 12:22:12.798 error at addChunk (_stream_readable.js:263:12)
                                  ! telegram.0 2018-05-09 12:22:12.798 error at Socket.emit (events.js:211:7)
                                  ! telegram.0 2018-05-09 12:22:12.798 error at emitOne (events.js:116:13)
                                  ! telegram.0 2018-05-09 12:22:12.798 error at Socket.Parser.__onData (/opt/iobroker/node_modules/iobroker.telegram/node_modules/socksv5/lib/client.parser.js:33:10)
                                  ! telegram.0 2018-05-09 12:22:12.798 error at Parser._onData (/opt/iobroker/node_modules/iobroker.telegram/node_modules/socksv5/lib/client.parser.js:85:14)
                                  ! telegram.0 2018-05-09 12:22:12.798 error at Parser.emit (events.js:211:7)
                                  ! telegram.0 2018-05-09 12:22:12.798 error at emitOne (events.js:116:13)
                                  ! telegram.0 2018-05-09 12:22:12.798 error at Parser. <anonymous>(/opt/iobroker/node_modules/iobroker.telegram/node_modules/socksv5/lib/client.js:102:15)
                                  ! telegram.0 2018-05-09 12:22:12.798 error Error: Authentication method mismatch
                                  ! telegram.0 2018-05-09 12:22:12.796 error uncaught exception: Authentication method mismatch</anonymous></anonymous></anonymous></anonymous></anonymous></anonymous>
                                  Кто подскажет где копать?

                                  1 Reply Last reply Reply Quote 0
                                  • goofyk
                                    goofyk last edited by

                                    Похоже, что-то не так с прокси.

                                    Попробуй такой прокси:

                                    Server: socks.kuzmitch.ru

                                    Port: 1080

                                    User: socksuser

                                    Pass: heropass2

                                    1 Reply Last reply Reply Quote 0
                                    • ViR
                                      ViR last edited by

                                      @goofyk:

                                      Похоже, что-то не так с прокси.

                                      Попробуй такой прокси:

                                      Server: socks.kuzmitch.ru

                                      Port: 1080

                                      User: socksuser

                                      Pass: heropass2 `
                                      И с этим не хотит но ошибка уже другая, такая же как и без прокси

                                      ! telegram.0 2018-05-11 04:33:59.911 error polling_error:EFATAL, EFATAL: Error: self signed certificate
                                      ! telegram.0 2018-05-11 04:33:58.560 info starting. Version 1.2.3 in /opt/iobroker/node_modules/iobroker.telegram, node: v8.11.1
                                      причем когда останавливаешь бота Telegramm сыпятся ошибки

                                      ! host.orangepipcplus 2018-05-11 04:54:45.766 info instance system.adapter.telegram.0 terminated with code 0 (OK)
                                      ! Caught 2018-05-11 04:54:45.766 error by controller[1]: at process._tickCallback (internal/process/next_tick.js:180:9)
                                      ! Caught 2018-05-11 04:54:45.765 error by controller[1]: at _combinedTickCallback (internal/process/next_tick.js:138:11)
                                      ! Caught 2018-05-11 04:54:45.765 error by controller[1]: at emitErrorNT (internal/streams/destroy.js:64:8)
                                      ! Caught 2018-05-11 04:54:45.765 error by controller[1]: at TLSSocket.emit (events.js:211:7)
                                      ! Caught 2018-05-11 04:54:45.765 error by controller[1]: at emitOne (events.js:116:13)
                                      ! Caught 2018-05-11 04:54:45.764 error by controller[1]: at TLSSocket.socketErrorListener (_http_client.js:387:9)
                                      ! Caught 2018-05-11 04:54:45.764 error by controller[1]: at ClientRequest.emit (events.js:211:7)
                                      ! Caught 2018-05-11 04:54:45.764 error by controller[1]: at emitOne (events.js:116:13)
                                      ! Caught 2018-05-11 04:54:45.764 error by controller[1]: at Request.onRequestError (/opt/iobroker/node_modules/iobroker.telegram/node_modules/node-telegram-bot-api/node_modules/request/request.js:878:8)
                                      ! Caught 2018-05-11 04:54:45.763 error by controller[1]: at Request.emit (events.js:211:7)
                                      ! Caught 2018-05-11 04:54:45.763 error by controller[1]: at emitOne (events.js:116:13)
                                      ! Caught 2018-05-11 04:54:45.763 error by controller[1]: at self.callback (/opt/iobroker/node_modules/iobroker.telegram/node_modules/node-telegram-bot-api/node_modules/request/request.js:186:22)
                                      ! Caught 2018-05-11 04:54:45.763 error by controller[1]: at Request.RP$callback [as _callback] (/opt/iobroker/node_modules/iobroker.telegram/node_modules/node-telegram-bot-api/node_modules/request-promise/node_modules/request-promise-
                                      ! Caught 2018-05-11 04:54:45.763 error by controller[1]: at Request.plumbing.callback (/opt/iobroker/node_modules/iobroker.telegram/node_modules/node-telegram-bot-api/node_modules/request-promise/node_modules/request-promise-core/lib/
                                      ! Caught 2018-05-11 04:54:45.762 error by controller[1]: at new RequestError (/opt/iobroker/node_modules/iobroker.telegram/node_modules/node-telegram-bot-api/node_modules/request-promise/node_modules/request-promise-core/lib/errors.js
                                      ! Caught 2018-05-11 04:54:45.762 error by controller[1]: Unhandled rejection RequestError: Error: self signed certificate
                                      ! Caught 2018-05-11 04:54:45.762 error by controller[1]: at process._tickCallback (internal/process/next_tick.js:180:9)
                                      ! Caught 2018-05-11 04:54:45.762 error by controller[1]: at _combinedTickCallback (internal/process/next_tick.js:138:11)
                                      ! Caught 2018-05-11 04:54:45.761 error by controller[1]: at emitErrorNT (internal/streams/destroy.js:64:8)
                                      ! Caught 2018-05-11 04:54:45.761 error by controller[1]: at TLSSocket.emit (events.js:211:7)
                                      ! Caught 2018-05-11 04:54:45.761 error by controller[1]: at emitOne (events.js:116:13)
                                      ! Caught 2018-05-11 04:54:45.760 error by controller[1]: at TLSSocket.socketErrorListener (_http_client.js:387:9)
                                      ! Caught 2018-05-11 04:54:45.760 error by controller[1]: at ClientRequest.emit (events.js:211:7)
                                      ! Caught 2018-05-11 04:54:45.760 error by controller[1]: at emitOne (events.js:116:13)
                                      ! Caught 2018-05-11 04:54:45.759 error by controller[1]: at Request.onRequestError (/opt/iobroker/node_modules/iobroker.telegram/node_modules/node-telegram-bot-api/node_modules/request/request.js:878:8)
                                      ! Caught 2018-05-11 04:54:45.759 error by controller[1]: at Request.emit (events.js:211:7)
                                      ! Caught 2018-05-11 04:54:45.759 error by controller[1]: at emitOne (events.js:116:13)
                                      ! Caught 2018-05-11 04:54:45.759 error by controller[1]: at self.callback (/opt/iobroker/node_modules/iobroker.telegram/node_modules/node-telegram-bot-api/node_modules/request/request.js:186:22)
                                      ! Caught 2018-05-11 04:54:45.758 error by controller[1]: at Request.RP$callback [as _callback] (/opt/iobroker/node_modules/iobroker.telegram/node_modules/node-telegram-bot-api/node_modules/request-promise/node_modules/request-promise-
                                      ! Caught 2018-05-11 04:54:45.758 error by controller[1]: at Request.plumbing.callback (/opt/iobroker/node_modules/iobroker.telegram/node_modules/node-telegram-bot-api/node_modules/request-promise/node_modules/request-promise-core/lib/
                                      ! Caught 2018-05-11 04:54:45.758 error by controller[1]: at new RequestError (/opt/iobroker/node_modules/iobroker.telegram/node_modules/node-telegram-bot-api/node_modules/request-promise/node_modules/request-promise-core/lib/errors.js
                                      ! Caught 2018-05-11 04:54:45.758 error by controller[1]: Unhandled rejection RequestError: Error: self signed certificate
                                      ! Caught 2018-05-11 04:54:45.757 error by controller[0]: See https://github.com/yagop/node-telegram- … issues/319. at module.js:652:30
                                      ! Caught 2018-05-11 04:54:45.757 error by controller[0]: In the future, you will have to enable it yourself.
                                      ! Caught 2018-05-11 04:54:45.756 error by controller[0]: Thu, 10 May 2018 18:54:28 GMT node-telegram-bot-api deprecated Automatic enabling of cancellation of promises is deprecated.

                                      1 Reply Last reply Reply Quote 0
                                      • goofyk
                                        goofyk last edited by

                                        как будто кто-то сертификат подменяет… уж не провайдер ли...

                                        даже не знаю почему так.

                                        1 Reply Last reply Reply Quote 0
                                        • aurodionov
                                          aurodionov last edited by

                                          у меня драйвер даже через впн не пошел, горит жёлтый и нихрена не работает

                                          1 Reply Last reply Reply Quote 0
                                          • goofyk
                                            goofyk last edited by

                                            видать провайдер-провайдеру рознь.

                                            у меня на Мегафоне и РТ через прокси нормально работают боты

                                            1 Reply Last reply Reply Quote 0
                                            • First post
                                              Last post

                                            Support us

                                            ioBroker
                                            Community Adapters
                                            Donate

                                            921
                                            Online

                                            31.9k
                                            Users

                                            80.1k
                                            Topics

                                            1.3m
                                            Posts

                                            20
                                            55
                                            17684
                                            Loading More Posts
                                            • Oldest to Newest
                                            • Newest to Oldest
                                            • Most Votes
                                            Reply
                                            • Reply as topic
                                            Log in to reply
                                            Community
                                            Impressum | Datenschutz-Bestimmungen | Nutzungsbedingungen
                                            The ioBroker Community 2014-2023
                                            logo