I found the source of the problem. It turns out I also had Python installed in vcpkg, which was causing the build issues.