diff --git a/flatland/core/env.py b/flatland/core/env.py
index d1f814f35159b70d93e5b7109bc5119a4264da29..1bc5b6f3eba4ee4713bd3c8d6b88440006c215a5 100644
--- a/flatland/core/env.py
+++ b/flatland/core/env.py
@@ -84,7 +84,6 @@ class Environment:
         """
         raise NotImplementedError()
 
-
     def get_agent_handles(self):
         """
         Returns a list of agents' handles to be used as keys in the step()
diff --git a/flatland/envs/observations.py b/flatland/envs/observations.py
index 3100e8b72277de54bcf10a8a899dd18517fcbb81..541f8ad592d1481afb8eb6da2eb7b887aacae419 100644
--- a/flatland/envs/observations.py
+++ b/flatland/envs/observations.py
@@ -295,7 +295,6 @@ class TreeObsForRailEnv(ObservationBuilder):
         other_target_encountered = np.inf
         other_agent_same_direction = 0
         other_agent_opposite_direction = 0
-        possible_conflict = 0
 
         num_steps = 1
         while exploring:
diff --git a/tests/test_env_prediction_builder.py b/tests/test_env_prediction_builder.py
index be065d3d10a4bf99804ab1556dba563d9ef27406..a1c951d31f7121a8445f4309c31ce58653c7e463 100644
--- a/tests/test_env_prediction_builder.py
+++ b/tests/test_env_prediction_builder.py
@@ -64,7 +64,7 @@ def test_predictions():
                   height=rail_map.shape[0],
                   rail_generator=rail_from_GridTransitionMap_generator(rail),
                   number_of_agents=1,
-                  obs_builder_object=TreeObsForRailEnv(max_depth=20, predictor=DummyPredictorForRailEnv(max_depth=20)),
+                  obs_builder_object=TreeObsForRailEnv(max_depth=2, predictor=DummyPredictorForRailEnv(max_depth=20)),
                   )
 
     env.reset()