From 46e0bb73a7e797f6c2299d93b24aeb220c03c13c Mon Sep 17 00:00:00 2001 From: Sebastian Serth Date: Wed, 10 Nov 2021 08:56:33 +0100 Subject: [PATCH] Fix initial sync with Poseidon --- lib/runner/strategy/poseidon.rb | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/lib/runner/strategy/poseidon.rb b/lib/runner/strategy/poseidon.rb index 195d32db..6625e6a1 100644 --- a/lib/runner/strategy/poseidon.rb +++ b/lib/runner/strategy/poseidon.rb @@ -28,7 +28,12 @@ class Runner::Strategy::Poseidon < Runner::Strategy when 200 response_body = parse response execution_environments = response_body[:executionEnvironments] - execution_environments.presence || raise(Runner::Error::UnexpectedResponse.new("Could not get the list of execution environments in Poseidon, got response: #{response.as_json}")) + + if execution_environments.nil? + raise(Runner::Error::UnexpectedResponse.new("Could not get the list of execution environments in Poseidon, got response: #{response.as_json}")) + else + execution_environments + end when 404 raise Runner::Error::EnvironmentNotFound.new else