Prevent reference_implementation to be copied to Runner

This commit is contained in:
Sebastian Serth
2022-11-04 17:30:30 +01:00
parent de024d9360
commit cf957eb715

View File

@ -205,6 +205,7 @@ class Submission < ApplicationRecord
begin
runner = Runner.for(user, exercise.execution_environment)
files = collect_files
files.reject!(&:reference_implementation?)
files.reject!(&:teacher_defined_assessment?) if cause == 'run'
Rails.logger.debug { "#{Time.zone.now.getutc.inspect}: Copying files to Runner #{runner.id} for #{user_type} #{user_id} and Submission #{id}." }
runner.copy_files(files)