ironic_python_agent.errors module

exception ironic_python_agent.errors.AgentIsBusy(command_name)[source]

Bases: CommandExecutionError

message = 'Agent is busy'
status_code = 409
exception ironic_python_agent.errors.BlockDeviceEraseError(details)[source]

Bases: RESTError

Error raised when an error occurs erasing a block device.

message = 'Error erasing block device'
exception ironic_python_agent.errors.BlockDeviceError(details)[source]

Bases: RESTError

Error raised when a block devices causes an unknown error.

message = 'Block device caused unknown error'
exception ironic_python_agent.errors.CleaningError(details=None)[source]

Bases: RESTError

Error raised when a cleaning step fails.

message = 'Clean step failed'
exception ironic_python_agent.errors.ClockSyncError(details=None, *args, **kwargs)[source]

Bases: RESTError

Error raised when attempting to sync the system clock.

message = 'Error syncing system clock'
exception ironic_python_agent.errors.CommandExecutionError(details)[source]

Bases: RESTError

Error raised when a command fails to execute.

message = 'Command execution failed'
exception ironic_python_agent.errors.DeploymentError(details=None)[source]

Bases: RESTError

Error raised when a deploy step fails.

message = 'Deploy step failed'
exception ironic_python_agent.errors.DeviceNotFound(details)[source]

Bases: NotFound

Error raised when the device to deploy the image onto is not found.

message = 'Error finding the disk or partition device to deploy the image onto'
exception ironic_python_agent.errors.ExtensionError(details=None, *args, **kwargs)[source]

Bases: RESTError

exception ironic_python_agent.errors.HardwareManagerMethodNotFound(method)[source]

Bases: RESTError

Error raised when all HardwareManagers fail to handle a method.

message = 'No HardwareManager found to handle method'
exception ironic_python_agent.errors.HardwareManagerNotFound(details=None)[source]

Bases: RESTError

Error raised when no valid HardwareManager can be found.

message = 'No valid HardwareManager found'
exception ironic_python_agent.errors.HeartbeatConflictError(details)[source]

Bases: IronicAPIError

ConflictError raised when a heartbeat to the agent API fails.

message = 'ConflictError heartbeating to agent API'
exception ironic_python_agent.errors.HeartbeatConnectionError(details)[source]

Bases: IronicAPIError

Transitory connection failure occurred attempting to contact the API.

message = 'Error attempting to heartbeat - Possible transitory network failure or blocking port may be present.'
exception ironic_python_agent.errors.HeartbeatError(details)[source]

Bases: IronicAPIError

Error raised when a heartbeat to the agent API fails.

message = 'Error heartbeating to agent API'
exception ironic_python_agent.errors.ImageChecksumError(image_id, image_location, checksum, calculated_checksum)[source]

Bases: RESTError

Error raised when an image fails to verify against its checksum.

details_str = 'Image failed to verify against checksum. location: {}; image ID: {}; image checksum: {}; verification checksum: {}'
message = 'Error verifying image checksum'
exception ironic_python_agent.errors.ImageDownloadError(image_id, msg)[source]

Bases: RESTError

Error raised when an image cannot be downloaded.

message = 'Error downloading image'
exception ironic_python_agent.errors.ImageWriteError(device, exit_code, stdout, stderr)[source]

Bases: RESTError

Error raised when an image cannot be written to a device.

message = 'Error writing image to device'
exception ironic_python_agent.errors.IncompatibleHardwareMethodError(details=None)[source]

Bases: RESTError

Error raised when HardwareManager method incompatible with hardware.

message = 'HardwareManager method is not compatible with hardware'
exception ironic_python_agent.errors.IncompatibleNumaFormatError(details=None, *args, **kwargs)[source]

Bases: RESTError

Error raised when unexpected format data in NUMA node.

message = 'Error in NUMA node data format'
exception ironic_python_agent.errors.InspectionError[source]

Bases: Exception

Failure during inspection.

exception ironic_python_agent.errors.InvalidCommandError(details)[source]

Bases: InvalidContentError

Error which is raised when an unknown command is issued.

message = 'Invalid command'
exception ironic_python_agent.errors.InvalidCommandParamsError(details)[source]

Bases: InvalidContentError

Error which is raised when command parameters are invalid.

message = 'Invalid command parameters'
exception ironic_python_agent.errors.InvalidContentError(details)[source]

Bases: RESTError

Error which occurs when a user supplies invalid content.

Either because that content cannot be parsed according to the advertised Content-Type, or due to a content validation error.

message = 'Invalid request body'
status_code = 400
exception ironic_python_agent.errors.InvalidImage(details=None)[source]

Bases: DeploymentError

Error raised when an image fails validation for any reason.

message = 'The provided image is not valid for use'
exception ironic_python_agent.errors.IronicAPIError(details)[source]

Bases: RESTError

Error raised when a call to the agent API fails.

message = 'Error in call to ironic-api'
exception ironic_python_agent.errors.LookupAgentIPError(details)[source]

Bases: IronicAPIError

Error raised when automatic IP lookup fails.

message = 'Error finding IP for Ironic Agent'
exception ironic_python_agent.errors.LookupNodeError(details)[source]

Bases: IronicAPIError

Error raised when the node lookup to the Ironic API fails.

message = 'Error getting configuration from Ironic'
exception ironic_python_agent.errors.NotFound(details=None, *args, **kwargs)[source]

Bases: RESTError

Error which occurs if a non-existent API endpoint is called.

details = 'The requested URL was not found.'
message = 'Not found'
status_code = 404
exception ironic_python_agent.errors.ProtectedDeviceError(device, what)[source]

Bases: CleaningError

Error raised when a cleaning is halted due to a protected device.

message = 'Protected device located, cleaning aborted.'
exception ironic_python_agent.errors.RESTError(details=None, *args, **kwargs)[source]

Bases: Exception, Serializable

Base class for errors generated in ironic-python-client.

details = 'An unexpected error occurred. Please try back later.'
message = 'An error occurred'
serializable_fields = ('type', 'code', 'message', 'details')
status_code = 500
exception ironic_python_agent.errors.RequestedObjectNotFoundError(type_descr, obj_id)[source]

Bases: NotFound

exception ironic_python_agent.errors.ServicingError(details=None)[source]

Bases: RESTError

Error raised when a service step fails.

message = 'Service step failed'
exception ironic_python_agent.errors.SoftwareRAIDError(details)[source]

Bases: RESTError

Error raised when a Software RAID causes an error.

message = 'Software RAID caused unknown error'
exception ironic_python_agent.errors.SystemRebootError(exit_code, stdout, stderr)[source]

Bases: RESTError

Error raised when a system cannot reboot.

message = 'Error rebooting system'
exception ironic_python_agent.errors.UnknownNodeError(details=None)[source]

Bases: RESTError

Error raised when the agent is not associated with an Ironic node.

message = 'Agent is not associated with an Ironic node'
exception ironic_python_agent.errors.VersionMismatch(agent_version, node_version)[source]

Bases: RESTError

Error raised when Ironic and the Agent have different versions.

If the agent version has changed since get_clean_steps or get_deploy_steps was called by the Ironic conductor, it indicates the agent has been updated (either on purpose, or a new agent was deployed and the node was rebooted). Since we cannot know if the upgraded IPA will work with cleaning/deploy as it stands (steps could have different priorities, either in IPA or in other Ironic interfaces), we should restart the process from the start.

message = 'Hardware managers version mismatch, reload agent with correct version'
exception ironic_python_agent.errors.VirtualMediaBootError(details)[source]

Bases: RESTError

Error raised when virtual media device cannot be found for config.

message = 'Configuring agent from virtual media failed'