This is probably a really simple question, but I just can't find any info on it.
I work with a system that aggregates a lot of data from various sources and then stores that data in a database. For the most part, the system works fine, but occasionally we get an issue where data can have awkward character encoding (for instance, when the data is in another language, like French) that our system doesn't like.
The data gets passed to our processing server (we use Gearman), and to ensure that all the info pertaining to source gets passed we json_encode an array with everything we need. My question to you is: if I wrap the json_encode in a try/catch block, will things that cause "PHP Warning: json_encode(): Invalid UTF-8 sequence in argument" messages trigger the catch block to activate?
Thanks!