Skip to content
Snippets Groups Projects
Commit b1af1f26 authored by Shinya Maeda's avatar Shinya Maeda
Browse files

Fix enum wording

parent dcf09d11
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -43,7 +43,7 @@ class CommitStatus < ActiveRecord::Base
failed_by_script: 1, # TODO: Not used. Should we expand pipeline as well?
failed_by_missing_dependency: 2, # This will be done in the next MR.
failed_by_system: 3, # TODO: Not used. What's this state?
failed_by_failed_job_state: 4,
failed_by_job_state: 4,
failed_by_out_of_quota: 5, # TODO: Only EE. How can we detect?
failed_by_stuck_and_timeout: 6,
failed_by_no_runner: 7, # TODO: Not used. How can we detect?
Loading
Loading
Loading
Loading
@@ -53,7 +53,7 @@ module Projects
log_error("Projects::UpdatePagesService: #{message}")
@status.allow_failure = !latest?
@status.description = message
@status.drop(:page)
@status.drop(:failed_by_page)
super
end
 
Loading
Loading
Loading
Loading
@@ -53,7 +53,7 @@ class StuckCiJobsWorker
def drop_build(type, build, status, timeout)
Rails.logger.info "#{self.class}: Dropping #{type} build #{build.id} for runner #{build.runner_id} (status: #{status}, timeout: #{timeout})"
Gitlab::OptimisticLocking.retry_lock(build, 3) do |b|
b.drop(:stuck_and_timeout)
b.drop(:failed_by_stuck_and_timeout)
end
end
end
Loading
Loading
@@ -103,7 +103,7 @@ module API
when 'success'
status.success!
when 'failed'
status.drop!(:api)
status.drop!(:failed_by_api)
when 'canceled'
status.cancel!
else
Loading
Loading
Loading
Loading
@@ -634,7 +634,7 @@ describe API::Runner do
update_job(state: 'failed')
 
expect(job.reload.status).to eq 'failed'
expect(job).to be_failed_by_failed_job_state
expect(job).to be_failed_by_job_state
end
end
 
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment