No, format() only works on string (= unicode), not on bytes array. That's why I had to change.