compare how the behavior changes with open my $fh, '<:encoding(UTF-8)', '../data/publicextract.charity.json' or die "Unable to read Charity JSON File"; compared to the open line you currently use.
I neglected to mention that I had previously read the file as UTF-8 in the way you suggest. But then decode_json complains about "wide characters" which I don't understand.
have your regex instead either search for the three bytes in octal with s/^\357\273\277//
That's the bit I needed!
I was getting thrown by the 0x1c56920 in 0x1c56920 "\357\273\277
That makes perfect sense except I don't understand what 0x1c56920 means in the output from the Devel::Peek Dump function.
In reply to Re^8: Rogue character(s) at start of JSON file (BOM; dumping references)
by Bod
in thread Rogue character(s) at start of JSON file
by Bod
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |