Clean up state handling in setup_vcs