diff --git a/flatland/envs/rail_env.py b/flatland/envs/rail_env.py index 3412ff6e416d2dee7f5475eff5a844b8acaf0184..91ab1a002285c7bfef62536ea82f83b3d9c83248 100644 --- a/flatland/envs/rail_env.py +++ b/flatland/envs/rail_env.py @@ -36,7 +36,7 @@ from flatland.envs import agent_chains as ac from flatland.envs.observations import GlobalObsForRailEnv -import debugpy +# import debugpy import pickle @@ -844,7 +844,7 @@ class RailEnv(Environment): trans_block = sbTrans[agent.direction*4 : agent.direction * 4 + 4] if (trans_block == "0000"): print (i_agent, agent.position, agent.direction, sbTrans, trans_block) - debugpy.breakpoint() + # debugpy.breakpoint() # if agent cannot enter env, then we should have move=False @@ -861,22 +861,20 @@ class RailEnv(Environment): if not all([transition_valid, new_cell_valid]): print(f"ERRROR: step_agent2 invalid transition ag {i_agent} dir {new_direction} pos {agent.position} next {rc_next}") - debugpy.breakpoint() + # debugpy.breakpoint() if new_position != rc_next: print(f"ERROR: agent {i_agent} new_pos {new_position} != rc_next {rc_next} " + f"pos {agent.position} dir {agent.direction} new_dir {new_direction}" + f"stored action: {agent.speed_data['transition_action_on_cellexit']}") - debugpy.breakpoint() + # debugpy.breakpoint() sbTrans = format(self.rail.grid[agent.position], "016b") trans_block = sbTrans[agent.direction*4 : agent.direction * 4 + 4] if (trans_block == "0000"): - print (i_agent, agent.position, agent.direction, sbTrans, trans_block) - debugpy.breakpoint() - - + print ("ERROR: ", i_agent, agent.position, agent.direction, sbTrans, trans_block) + # debugpy.breakpoint() agent.position = rc_next agent.direction = new_direction diff --git a/requirements_continuous_integration.txt b/requirements_continuous_integration.txt index 21a58438209f4e3da065de0a642a83ec950bff23..0dbd5923329624c72f11a2dc5dc3899cc1276f52 100644 --- a/requirements_continuous_integration.txt +++ b/requirements_continuous_integration.txt @@ -15,6 +15,7 @@ twine>=1.12.1 pydeps>=1.7.2 jupyter>=1.0.0 jupyter-core>=4.5.0 +jupyter-contrib-nbextensions notebook>=5.7.8 PyVirtualDisplay==0.2.5 pytest-xvfb>=1.2.0