Closed bukanvalen closed 3 years ago
Thank you for raising this issue.
Earlier this used to work. ( the code that you have written is perfectly correct and used to create a line break )
But today I checked, it is working no more. I don't know why.
In WhatsApp Web SHIFT + ENTER goes to new line. I know this and had implemented in my code.
(wappdriver presses SHIFT + ENTER whenever there is \n
)
See this.
It is working while done manually, but inside the script, it seems not to work.
I am trying to solve the issue.
Actually, I had made a small mistake. I am solving this now.
@bukanvalen I fixed this issue just now.
pip install --upgrade wappdriver
You don't have to do anything to your code. πβΊοΈππ. Just update the package, and everything will work fine.
Thanks a lot for reporting this. There was a small mistake in my code, which is now fixed.
@bukanvalen Please update the package, test it once and say me if it is working as expected.
Thank you so much! Now it works perfectly. Do you mind telling me what did you change and how it fixes the issue? I'm still learning Python, so if you could explain it, I would really appreciate it. Thanks in advance!
you can understand simply by seeing my commit e9b44d921f9444fd1422fad51179433daf0c6ed6
i just removed a tab :smile: it was a silly mistake from my part
One more thing, thank you so much for creating this. I was having trouble understanding Selenium and then I found your article on DEV. I was really in a pinch to message a bunch of people with custom messages that are tailored based on their name and gender. Now I can just open up Python and run your script, rather than messaging them one by one with some little editing in between.
That was the main purpose of creating this package. To let people not worry about selenium, chrome driver, selectors, etc, and allow people to easily send messages.
In the future, I will build a command-line version, where you can easily send messages, without even writing any python code.
If you are interested in Python and automation, you may see my Telegram Channel, where I post interesting stuff.
I'll be waiting for it, thanks for the information!
I use it like this
But then the messages were split into 2 separate messages. I know that the Enter key is the send key in WhatsApp Web. That's why I ask here, how to insert a line break? Thank you