Reputation: 439
I was trying to use the "cleantext" by importing clean text and ran into the following issue.
import cleantext
>>> ImportError: cannot import name 'UNICODE_EMOJI' from 'emoji' (/local_disk0/.ephemeral_nfs/envs/pythonEnv-16240e6c-0380-48a7-9d9f-b7de9d6fb078/lib/python3.7/site-packages/emoji/__init__.py)
After doing some digging I noticed the recent changed in emoji library (https://github.com/carpedm20/emoji) and the issue being reported in cleantext github (https://github.com/jfilter/clean-text/issues/24). I am not sure when this will be fixed and was wondering if there is any work around to get cleantext work.
Upvotes: 1
Views: 1351
Reputation: 1087
You can either install an older version of the emoji module (before version 2.0.0)
Or there is also an open pull request that fixes the problem for emoji version 2.0.0. You can find it at https://github.com/calebchiam/clean-text/tree/fix-emoji-dependency
Upvotes: 1