refactor deps for issue #3710