Closed andrewspode closed 5 years ago
@unclespode Have you found someone who can fix the regex, maybe? We're looking at including a fix into the next release, so …
@jublo unfortunately, I am otherwise disposed. My current code base is using my "fix" above and I've yet to encounter a problem.
@jublo @unclespode this happened due to licensing issue with json, more here https://bugs.php.net/bug.php?id=63520 .
Only possible solution without affecting code is to upgrade to php 7 because jsond merged in that version, see here https://wiki.php.net/rfc/jsond
@unclespode Since Codebird 4.0.0 will require PHP 7.1.0, we’re safe to implement your quick fix for now and watch this.
Occasionally, responses from Twitter are being mangled, and you will get no results even though it's fetched some.
Tracing this back has found it to be in the _json_decode function.
Not all PHP installs have support for JSON_BIGINT_AS_STRING, so this is checking and if not - running it through a regex.
The bug is in this regex and doesn't always manifest itself, but has been happening more often for me recently.
https://stackoverflow.com/questions/19520487/json-bigint-as-string-removed-in-php-5-5
This is the thread I believe the offending Regex is from.
Solutions:
Upgrade the PECL module. If anyone has advice on this please post - it wasn't clear which module needs updating and how.
Fix the RegEx. I'm going to post on the other thread to see if anyone can fix it, it's not my strong area.
Edit the code. I'm using this workaround which so far hasn't caused me any problems, so it's at least better than the current code.
If anyone else has insight, it would be to get a fix for this as I'm sure I'm not the only one having erratic behaviour.