Ruby 3.4 emits Warnings for this gem as it modifies strings, which may be frozen in the future. This line: https://github.com/paolochiodi/htmlcompressor/blob/4c8849418ed51f390a509cc93a7fd1631c42ed82/lib/htmlcompressor/rack.rb#L42 More info: https://www.prateekcodes.dev/ruby-34-frozen-string-literals-rails-upgrade-guide/ Hope that makes sense!