Barcode handling using unicode rather than str, because python2's default choices are silly