date-extractor
date-extractor copied to clipboard
UnicodeDecodeError: 'charmap' codec can't decode byte 0x81 in position 125: character maps to <undefined>
Running python 3.7.6 in jupyter notebook, occurred when trying to import using "from date_extractor import extract_dates".
Hi, @varunkuntal . I'm sorry for the late reply. Life stuff had got me busy, but should have some more availability in the coming weeks. Is this something that you would be interested in submitting a Pull Request? If not, I can take a look at it (but will probably be at least a week before fixing). Thank you!
Hi @varunkuntal, I'm getting the same problem with the latest version, I tried the date_extractor==5.0.0 version, it's running now. , are u tried that?
Hi. I'm really sorry about this issue. Would you be able to share what code you used to get Jupyter running? Do you know what version of Jupyter? What type of operating system are you using? Windows, MacOS, Ubuntu, etc.? Thank you!
@santhu2210 If you replace in the file "date_extractor\enumerations\ __ init_.py"_ line number 26 with "with open (join (datadir, f"months_verbose/{language}.txt"), encoding ="utf8") as f:" and line 91 with "with open (join(datadir, f"months_verbose/{language}.txt"), encoding = "utf8") as f:" you should be able to import everything without problems.
@ricky1192 , great fix! Would you like to submit a PR? Thank you!
Thank you for the PR @ricky1192 . I merged it in and published a new version, so this problem should be fixed now. @varunkuntal and @santhu2210 , did this fix your issues?