class Dependabot::Uv::FileUpdater::CompileFileUpdater
def package_hashes_for(name:, version:, algorithm:)
def package_hashes_for(name:, version:, algorithm:) index_urls = @index_urls || [nil] hashes = [] index_urls.each do |index_url| args = [name, version, algorithm] args << index_url if index_url begin native_helper_hashes = T.cast( SharedHelpers.run_helper_subprocess( command: "pyenv exec python3 #{NativeHelpers.python_helper_path}", function: "get_dependency_hash", args: args ), T::Array[T::Hash[String, String]] ).map { |h| "--hash=#{algorithm}:#{h['hash']}" } hashes.concat(native_helper_hashes) rescue SharedHelpers::HelperSubprocessFailed => e raise unless e.error_class.include?("PackageNotFoundError") next end end hashes end