Question: I am automating whatsapp messages and would like to send them out through a tkinter window. In this tkinter window I have created a message box with the help of .label() and I am able to connect to whatsapp web through selenium. 

Currently, I am able to send out messages already, but without emojis. When I include emojis, I get this error "Chromedriver only supports characters in the BMP". How can I include emojis?

Answer: 
This error message...

```
selenium.common.exceptions.WebDriverException: Message: unknown error: ChromeDriver only supports characters in the BMP

```

...implies that the **ChromeDriver** was unable to send the **emoji** signal through `send_keys()` method.

[ChromeDriver only supports characters in the BMP](https://bugs.chromium.org/p/chromedriver/issues/detail?id=2269) is a known issue with *Chromium* team as *ChromeDriver* still doesn't support characters with a Unicode after `FFFF`. Hence it is impossible to send any character beyond `FFFF` via ChromeDriver. As a result any attempt to send **SMP** characters (e.g. *CJK*, *Emojis*, *Symbols*, etc) raises the error.

---

Alternative
-----------

A potential alternative would be to use *GeckoDriver* / *Firefox*.

* Code Block:

```
  from selenium import webdriver
  from selenium.webdriver.support.ui import WebDriverWait
  from selenium.webdriver.common.by import By
  from selenium.webdriver.support import expected_conditions as EC

  driver = webdriver.Firefox(executable_path=r'C:\Utility\BrowserDrivers\geckodriver.exe')
  driver.get('https://www.google.com/')
  # Chineese Character
  WebDriverWait(driver, 20).until(EC.element_to_be_clickable((By.NAME, "q"))).send_keys("")
  # Emoji Character
  WebDriverWait(driver, 20).until(EC.element_to_be_clickable((By.NAME, "q"))).send_keys("")

```
* Browser Snapshot:

[![Emoji](https://i.stack.imgur.com/6Sih9.png)](https://i.stack.imgur.com/6Sih9.png)

You can find a relevant discussion in [OpenQA.Selenium.WebDriverException: 'unknown error: ChromeDriver only supports characters in the BMP while sending an emoji through C# Selenium](https://stackoverflow.com/questions/50439197/openqa-selenium-webdriverexception-unknown-error-chromedriver-only-supports-c)

---

Outro
-----

A few links:

* [Full Emoji List](https://unicode.org/emoji/charts/full-emoji-list.html)
* [Unicode character inspector](https://apps.timwhitlock.info/unicode/inspect?s=%F0%9F%92%A9)
there was an open bug on chrome driver website, the bug as been fixed this month (14.11.21)

<https://bugs.chromium.org/p/chromedriver/issues/detail?id=2269>

this is the bug report.

**how to use new chrome driver:**

first go to:
<https://commondatastorage.googleapis.com/chromium-browser-snapshots/index.html?prefix=Win/942085/>

download the chrome driver from there.(the first mark as showen in image).

then you will need to install the new chrome v98 using the mini\_installer.exe

**(pay attantion its all expermintal)**,

without this you could not use the new driver due to version compitity.

next i needed to delete the current chrome version to make this work good.
[![enter image description here](https://i.stack.imgur.com/GmNty.png)](https://i.stack.imgur.com/GmNty.png)

your are all welcome to ask me question about it, i mange to make it work with the versions i add here on whatsapp using selenium chrome driver.

**EDIT:**
[![enter image description here](https://i.stack.imgur.com/fHZm8.png)](https://i.stack.imgur.com/fHZm8.png)
chrome versions 98 stable will come out in 30 days, so you could try to install the beta version and not the chromium version and see if it's working.

you don't have to delete the old chrome version, I know this thread is about python but in java (i guess python support it too) you could do this:

```
options.setBinary(System.getProperty("user.home") + "\\AppData\\Local\\Chromium\\Application\\chrome.exe");

```

and it will set the path to the chromium version.