debugger: assign Environment to DebugContext too

fix #7517