Fix dependency cycle check for 2.6.x