End of Life Ruby 3.0 has reached end of life and gets no more fixes. Switch to Ruby 4.0 →
class · Ruby 3.0
Encoding::InvalidByteSequenceError
< EncodingError
7 instance methods
Raised by Encoding and String methods when the string being transcoded contains a byte invalid for the either the source or target encoding.