artefactory / NLPretext

All the goto functions you need to handle NLP use-cases, integrated in NLPretext
https://artefactory.github.io/NLPretext/
Apache License 2.0
138 stars 13 forks source link

AttributeError 'module emoji has no attribute 'get_emoje_regexp'' is raised when calling function 'Preprocessor' #225

Closed cheerchung closed 1 year ago

cheerchung commented 1 year ago

🐛 Bug Report

AttributeError is raised when calling the function Preprocessor. Description of error: module 'emoji' has no attribute 'get_emoji_regexp'

🔬 How To Reproduce

Steps to reproduce the behavior:

Just use the code example in the part of 'Usage --> default pipeline' by following 'README' doc.

Code sample

from nlpretext import Preprocessor
text = "I just got the best dinner in my life @latourdargent !!! I  recommend 😀 #food #paris \n"
preprocessor = Preprocessor()
text = preprocessor.run(text)
print(text)

Environment

Screenshots

image

📈 Expected behavior

This text should be preprocessed with default pipeline.

📎 Additional context

github-actions[bot] commented 1 year ago

Hello @cheerchung, thank you for your interest in our work!

If this is a bug report, please provide screenshots and minimum viable code to reproduce your issue, otherwise we can not help you.

cvzi commented 1 year ago

The function get_emoji_regexp was removed from the emoji module in version 2.0.0 https://github.com/artefactory/NLPretext/blob/fa44f0ef825351b9710852f596c64935dd4455d8/nlpretext/_config/constants.py#L218

The last version to contain this function was emoji==1.7.0