Class: Rubygems::Await::GemspecsAwaiter
- Defined in:
- lib/rubygems/await.rb
Instance Attribute Summary
Attributes inherited from Awaiter
#deadline, #gems, #name_indent, #source, #source_uri
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from Awaiter
call, #call, #collection, #compact_index_client, #downloader, #expired?, #format_element, #gem_remote_fetcher, #index_fetcher, #inherited, #initialize, #log, #log_error, #log_found, #process_collection, #safe_load_marshal, subclasses
Constructor Details
This class inherits a constructor from Rubygems::Await::Awaiter
Class Method Details
.awaiter_name ⇒ Object
306 307 308 |
# File 'lib/rubygems/await.rb', line 306 def self.awaiter_name "gemspecs" end |
Instance Method Details
#process_element(element) ⇒ Object
289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 |
# File 'lib/rubygems/await.rb', line 289 def process_element(element) spec = element.to_a - [nil, "ruby", ""] spec_file_name = "#{spec.join "-"}.gemspec" uri = source_uri + "#{Gem::MARSHAL_SPEC_DIR}#{spec_file_name}.rz" downloader.fetch(uri) true rescue (if defined?(::Bundler::Fetcher::AuthenticationForbiddenError) ::Bundler::Fetcher::AuthenticationForbiddenError else ::Bundler::Fetcher::AuthenticationRequiredError end) => e log_error(e) { "#{Bundler::URICredentialsFilter.credential_filtered_uri(uri)} not found" } false end |