Closed petdance closed 11 years ago
Would love to see the data coming out of the db that's causing the Invalid UTF-8 sequence error. Any way you could do a print_r on $result_set and $metadata?
Anything magic I need to do besides just kicking off a run from the command line rather than my normal cron job?
Nope, should be able to just do a run from the command line (and capture the output). Thanks for troubleshooting this Andy.
I'm getting the same problem, here is the output from my configuration:
$result_set: 2012-11-09 07:53:25 | 4.4MB | SUCCESS| DilbertDave | TwitterPlugin::crawl,106 | Starting to collect data for DilbertDave on Twitter. $metadata: 2012-11-09 07:53:25 | 4.8MB | INFO | DilbertDave | TwitterAPIAccessorOAuth::__construct,111 | Errors to tolerate: 5
Hope this is useful
Here's one example from DashboardModuleCacher.php
Array
(
[0] => Array
(
[c] => Array
(
[0] => Array
(
[v] => Ending the cults of personality in free software http://t.co/6pJGjFKt (The term I use is "hero worsh...
)
[1] => Array
(
[v] => 0
)
[2] => Array
(
[v] => 1
)
[3] => Array
(
[v] => 0
)
)
)
[1] => Array
(
[c] => Array
(
[0] => Array
(
[v] => Attention Fox News: You are the #1 news network. YOU ARE THE MAINSTREAM MEDIA. http://t.co/QACbd5K...
)
[1] => Array
(
[v] => 0
)
[2] => Array
(
[v] => 1
)
[3] => Array
(
[v] => 0
)
)
)
[2] => Array
(
[c] => Array
(
[0] => Array
(
[v] => The NYT interactive scenario chart is getting updated real-time. http://t.co/mcxT8vpV...
)
[1] => Array
(
[v] => 1
)
[2] => Array
(
[v] => 29
)
[3] => Array
(
[v] => 0
)
)
)
[3] => Array
(
[c] => Array
(
[0] => Array
(
[v] => Common resume mistakes to avoid, by technical hiring manager @vmbrasseur http://t.co/hwB1z0Q2...
)
[1] => Array
(
[v] => 0
)
[2] => Array
(
[v] => 1
)
[3] => Array
(
[v] => 0
)
)
)
[4] => Array
(
[c] => Array
(
[0] => Array
(
[v] => I'm going to start a new single-purpose site, like http://t.co/csuqTyTh, for all the "How do I write...
)
[1] => Array
(
[v] => 1
)
[2] => Array
(
[v] => 0
)
[3] => Array
(
[v] => 0
)
)
)
[5] => Array
(
[c] => Array
(
[0] => Array
(
[v] => "No matter how many mistakes you make or how slow you progress, you are still way ahead of everyone ...
)
[1] => Array
(
[v] => 0
)
[2] => Array
(
[v] => 2
)
[3] => Array
(
[v] => 0
)
)
)
[6] => Array
(
[c] => Array
(
[0] => Array
(
[v] => Tracing the history of the "'I know, I'll use regexes'. Now they have two problems" quote. http://t....
)
[1] => Array
(
[v] => 0
)
[2] => Array
(
[v] => 2
)
[3] => Array
(
[v] => 0
)
)
)
[7] => Array
(
[c] => Array
(
[0] => Array
(
[v] => Fascinating interactive chart of which states each candidate needs to win. http://t.co/e7Xzviek...
)
[1] => Array
(
[v] => 0
)
[2] => Array
(
[v] => 1
)
[3] => Array
(
[v] => 0
)
)
)
[8] => Array
(
[c] => Array
(
[0] => Array
(
[v] => I'm very glad to see that StackOverflow officially has banned "LMGTFY" links. http://t.co/9qPE8fck ‚...
)
[1] => Array
(
[v] => 0
)
[2] => Array
(
[v] => 2
)
[3] => Array
(
[v] => 0
)
)
)
[9] => Array
(
[c] => Array
(
[0] => Array
(
[v] => If the GOP won't believe scientists re: climate change, maybe they'll listen to corporate insurers? ...
)
[1] => Array
(
[v] => 0
)
[2] => Array
(
[v] => 1
)
[3] => Array
(
[v] => 0
)
)
)
)
Array
(
[0] => Array
(
[type] => string
[label] => Tweet
)
[1] => Array
(
[type] => number
[label] => Replies
)
[2] => Array
(
[type] => number
[label] => Retweets
)
[3] => Array
(
[type] => number
[label] => Favorites
)
)
PHP Warning: json_encode(): Invalid UTF-8 sequence in argument in /srv/thinkup/_lib/class.DashboardModuleCacher.php on line 227
Lol - looks nothing like what was sent to my log file, if you can post what you did to create that output (like I said above, I'm not a PHP dev) then I can try to provide some additional data.
@OnTheFenceDevelopement The dump is per Gina's request a few entries back. It's not in my log file.
Hmm ... I've added print_r($result_set) & print_r($metadata) statements just before the 'offending' line and run the thinkup script via the command line while redirecting the output to a file - that's what I get.
Oddly, my system has stopped complaining now and it ran to conclusion just now.
I have stopped receiving the Invalid UTF-8 sequence
errors in my cron runs, but the Undefined property: stdClass::$annotation
is still alive and kicking. I have updated no software.
The Undefined property error happens when you share a Google+ post without making a comment about it. (Your comment is "annotation", and the property doesn't exist if there is none.) I'm working on a fix now with tests. Thank you!
I now constantly get warnings from my cron job saying:
The line of code in DashboardModuleCacher.php is the
return
from getHotPostVisualizationData()The lines of code in GooglePlusCrawler.php are in fetchInstanceUserPosts() and look like:
Are the warnings related? I don't know.