ruby/rubygems · error · Gem::Exception
Error reading files from gem
Error message
Error reading files from gem
What it means
Error "Error reading files from gem" thrown in ruby/rubygems.
Source
Thrown at lib/rubygems/package/old.rb:60
read_until_dashes io # spec
header = file_list io
@contents = header.map {|file| file["path"] }
end
end
##
# Extracts the files in this package into +destination_dir+
def extract_files(destination_dir)
verify
errstr = "Error reading files from gem"
@gem.with_read_io do |io|
read_until_dashes io # spec
header = file_list io
raise Gem::Exception, errstr unless header
# install_location expects an already-resolved destination dir
destination_dir = File.realpath(destination_dir)
header.each do |entry|
full_name = entry["path"]
destination = install_location full_name, destination_dir
file_data = String.new
read_until_dashes io do |line|
file_data << line
end
file_data = file_data.strip.unpack1("m")
file_data = Zlib::Inflate.inflate file_data
View on GitHub (pinned to 86cbb817a3)
Solutions
- Re-download the gem; its file table could not be read
- Rebuild the gem if you created it
When it happens
Trigger: Thrown at lib/rubygems/package/old.rb:60 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of ruby/rubygems@86cbb817a3 (2026-08-23).
Data as JSON: /api/errors/971b7e1807ac1428.
Report an issue: GitHub.