Exception: DurableHuggingfaceHub::FileMetadataError

Inherits:
DurableHuggingfaceHubError show all
Defined in:
lib/durable_huggingface_hub/errors.rb

Overview

Error raised when file metadata cannot be retrieved or is invalid.

Examples:

raise FileMetadataError.new("config.json", "Missing ETag header")

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(path, message) ⇒ FileMetadataError

Creates a new file metadata error.

Parameters:

  • path (String)

    File path

  • message (String)

    Error message



280
281
282
283
# File 'lib/durable_huggingface_hub/errors.rb', line 280

def initialize(path, message)
  @path = path
  super("File metadata error for '#{path}': #{message}")
end

Instance Attribute Details

#pathString (readonly)

Returns The file path.

Returns:

  • (String)

    The file path



274
275
276
# File 'lib/durable_huggingface_hub/errors.rb', line 274

def path
  @path
end