bisguzar / twitter-scraper

Scrape the Twitter Frontend API without authentication.
MIT License
3.88k stars 600 forks source link

Issue with release 0.4.3 (Poetry) #157

Closed mat-h7 closed 4 years ago

mat-h7 commented 4 years ago

Hi,

I am currently working on a project and we are using poetry for dependency management. We were using your package and it was working fine until the new release (0.4.3), it seems to be that when updating the package a rouge breakpoint is generated in the profile module within the virtual environment managed by poetry (see screenshot below). This causes any execution to "fall into" the python debugger whenever it calls twitter_scraper.Profile. I realize that this is most probably a poetry-related issue, but I thought I'd raise it here in case anyone has any thoughts.

As a temporary solution I have just ensured that version 0.4.2 is used. screenshot_99

SaudTauqeer commented 4 years ago

i'm facing the same issue, however i'm trying to run the package in nodejs via python-shell. I tried it in cmd and it fails like this: https://jmp.sh/GTyN07Z

SaudTauqeer commented 4 years ago

i'm facing the same issue, however i'm trying to run the package in nodejs via python-shell. I tried it in cmd and it fails like this: https://jmp.sh/GTyN07Z I used the 0.4.2 version but now I'm facing this error. This works perfectly fine in the cmd but fails with python-shell npm package.


C:\development\ProductHuntBotDetector\ph-bot-detector\core\pip.js:9
if (err) throw err;
^

Error: UnicodeEncodeError: 'charmap' codec can't encode characters in position 15-16: character maps to at PythonShell.parseError (C:\development\ProductHuntBotDetector\ph-bot-detector\node_modules\python-shell\index.js:258:21) at terminateIfNeeded (C:\development\ProductHuntBotDetector\ph-bot-detector\node_modules\python-shell\index.js:141:32) at ChildProcess. (C:\development\ProductHuntBotDetector\ph-bot-detector\node_modules\python-shell\index.js:133:13) at ChildProcess.emit (events.js:198:13) at Process.ChildProcess._handle.onexit (internal/child_process.js:248:12) ----- Python Traceback ----- File "twitter_scraper\scrape.py", line 5, in print(profile.to_dict()) File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.8_3.8.1264.0_x64__qbz5n2kfra8p0\lib\encodings\cp1252.py", line 19, in encode return codecs.charmap_encode(input,self.errors,encoding_table)[0]

bisguzar commented 4 years ago

Oh guys, my bad. Please upgrade the package to 0.4.4.

bisguzar commented 4 years ago

@SaudTauqeer its not understandable, I'm sorry but I'm not able to help you.