michenriksen / birdwatcher

Data analysis and OSINT framework for Twitter
https://michenriksen.com/blog/birdwatcher-twitter-osint-framework/
MIT License
410 stars 65 forks source link

word_cloud crashes for me #12

Open IndivisibleCRM opened 7 years ago

IndivisibleCRM commented 7 years ago

This is on Ubuntu, had to do a little more than what the install instructions here say - ruby dev stuff, PG dev stuff.

I put in three users (realDonaldTrump, SeanSpicer, KellyannePolls) and they have 2,998 tweets. Creating a word_cloud fails in this fashion:

birdwatcher[test][statuses/word_cloud]> set dest cloud birdwatcher[test][statuses/word_cloud]> run

SEQUEL DEPRECATION WARNING: Calling a dataset filtering method with multiple arguments or an array where the first argument/element is a string is deprecated and will be removed in Sequel 5. Use Sequel.lit("DATE(posted_at) >= DATE(?) AND DATE(posted_at) <= DATE(?)", "2017-05-27", "2017-06-03") to create an SQL fragment expression and pass that to the dataset filtering method, or use the auto_literal_strings extension.

/var/lib/gems/2.3.0/gems/sequel-4.47.0/lib/sequel/dataset/query.rb:1293:in filter_expr' /var/lib/gems/2.3.0/gems/sequel-4.47.0/lib/sequel/dataset/query.rb:1249:inadd_filter' /var/lib/gems/2.3.0/gems/sequel-4.47.0/lib/sequel/dataset/query.rb:1034:in where' /var/lib/gems/2.3.0/gems/birdwatcher-0.4.0/lib/birdwatcher/modules/statuses/word_cloud.rb:129:inrun' /var/lib/gems/2.3.0/gems/birdwatcher-0.4.0/lib/birdwatcher/module.rb:159:in execute' /var/lib/gems/2.3.0/gems/birdwatcher-0.4.0/lib/birdwatcher/commands/run.rb:15:inrun' /var/lib/gems/2.3.0/gems/birdwatcher-0.4.0/lib/birdwatcher/command.rb:47:in execute' /var/lib/gems/2.3.0/gems/birdwatcher-0.4.0/lib/birdwatcher/console.rb:43:inblock in handle_input' /var/lib/gems/2.3.0/gems/birdwatcher-0.4.0/lib/birdwatcher/console.rb:41:in each' /var/lib/gems/2.3.0/gems/birdwatcher-0.4.0/lib/birdwatcher/console.rb:41:inhandle_input'

[+] Processing 82 statuses... done [+] Generating word cloud, patience please... failed [-] FloatDomainError: NaN [+] Word cloud written to cloud

And this does not produce a cloud.jpg or cloud.png