Revert "construct environment"

This reverts commit 6e56a6eb49c6a11a35d5f95acd721b2d84edc870.