Exception: Api2Convert::ConversionTimeoutError
- Defined in:
- lib/api2convert/errors.rb
Overview
A job did not reach a terminal status within the configured poll timeout.
The job is still running server-side — re-fetch it later with
client.jobs.get(job.id). (Maps to the PHP SDK's TimeoutException; named to
avoid shadowing Ruby's Timeout::Error.)
Instance Attribute Summary collapse
-
#job ⇒ Model::Job
readonly
The job that was still running when the wait timed out.
Instance Method Summary collapse
-
#initialize(job, timeout_seconds) ⇒ ConversionTimeoutError
constructor
A new instance of ConversionTimeoutError.
Constructor Details
#initialize(job, timeout_seconds) ⇒ ConversionTimeoutError
Returns a new instance of ConversionTimeoutError.
108 109 110 111 112 113 114 |
# File 'lib/api2convert/errors.rb', line 108 def initialize(job, timeout_seconds) @job = job super( "Timed out after #{timeout_seconds}s waiting for job #{job.id} to finish " \ "(last status: #{job.status.code})." ) end |
Instance Attribute Details
#job ⇒ Model::Job (readonly)
Returns the job that was still running when the wait timed out.
106 107 108 |
# File 'lib/api2convert/errors.rb', line 106 def job @job end |