CamTosh / instagram-bot-dm

Instagram bot to send direct messages
GNU General Public License v3.0
326 stars 66 forks source link

Crash on send in multiple line. #34

Open rsa408 opened 2 years ago

rsa408 commented 2 years ago

I try to send :

insta.sendMessage(user='my_ID', message='Hello\n my\n name \n is \n RSA')

Error:

[12364:9996:0201/183830.300:ERROR:ssl_client_socket_impl.cc(996)] handshake failed; returned -1, SSL error code 1, net_error -101
ERROR:root:Message: element click intercepted: Element <button class="sqdOP yWX7d    y3zKF     " type="button">...</button> is not clickable at point (433, 529). Other element would receive the click: <span class="_7UhW9    vy6Bb     MMzan       gtFbE      se6yk        ">...</span>
  (Session info: chrome=97.0.4692.99)
rsa408 commented 2 years ago

I have commented line 44: ```

mobile_emulation = { "userAgent": 'Mozilla/5.0 (Linux; Android 4.0.3; HTC One X Build/IML74K) AppleWebKit/535.19 (KHTML, like Gecko) Chrome/18.0.1025.133 Mobile Safari/535.19' }

    options.add_experimental_option("mobileEmulation", mobile_emulation)
and :
line 46, 47: ```
#self.driver.set_window_position(0, 0)
        #self.driver.set_window_size(414, 736)

Now it works and without crashing but for every newline '\n' expression send a message. For this message: Hello\n my\n name, \n is \n RSA instead of 1 message with 4 lines, will send 4 messages.