diff options
author | Shinya Maeda <shinya@gitlab.com> | 2018-05-23 10:42:24 +0300 |
---|---|---|
committer | Shinya Maeda <shinya@gitlab.com> | 2018-05-28 08:17:38 +0300 |
commit | ffacc06efb0f71d8aed18c6517fc18d168873cf2 (patch) | |
tree | ef1c12aafcad5e068dcc2743b545638fee119a0f | |
parent | 014f5f6a69f63ee42bd94454108268f189b62b18 (diff) |
Ignore writing traces if it's already been archived
-rw-r--r-- | lib/gitlab/ci/trace.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/gitlab/ci/trace.rb b/lib/gitlab/ci/trace.rb index fe15fabc2e8..58a0ec6dea4 100644 --- a/lib/gitlab/ci/trace.rb +++ b/lib/gitlab/ci/trace.rb @@ -77,7 +77,9 @@ module Gitlab def write(mode) stream = Gitlab::Ci::Trace::Stream.new do - if current_path + if trace_artifact + # no op. It's already archived. + elsif current_path File.open(current_path, mode) elsif Feature.enabled?('ci_enable_live_trace') Gitlab::Ci::Trace::ChunkedIO.new(job) |