bensheldon/good_job · error · ActionController::BadRequest
Invalid type
Error message
Invalid type
What it means
Error "Invalid type" thrown in bensheldon/good_job.
Source
Thrown at app/controllers/good_job/pauses_controller.rb:31
GoodJob::Setting.pause(pause_type => pause_value)
redirect_to({ action: :index }, notice: "Successfully paused #{params[:type]} '#{params[:value]}'", status: :see_other)
end
def destroy
pause_type = params[:type].to_sym
pause_value = params[:value].to_s
GoodJob::Setting.unpause(pause_type => pause_value)
redirect_to({ action: :index }, notice: "Successfully unpaused #{params[:type]} '#{params[:value]}'", status: :see_other)
end
private
def validate_type
return if params[:type].in?(%w[queue job_class label]) && params[:value].to_s.present?
raise ActionController::BadRequest, "Invalid type"
end
end
end
View on GitHub (pinned to 5fcde48f87)
Solutions
- Pass a valid pause type (queue, job_class, or label) to the pauses controller.
- Set the type param to one of the types supported by GoodJob::PausesController.
Example fix
# Set type=queue (or job_class/label) in the pause request
When it happens
Trigger: Thrown at app/controllers/good_job/pauses_controller.rb:31 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of bensheldon/good_job@5fcde48f87 (2026-08-23).
Data as JSON: /api/errors/6f321de717180c8a.
Report an issue: GitHub.