The latest released stable version of Arduino-ESP32, that PlatformIO uses, is 1.0.4.
The problem is that
you’re taking the master-version of the library which might be written against not yet released release-candidates. However sadly this library also has no tags / versioning, so you would have to go back in the commit history to get a version that works against 1.0.4, which might be cumbersome.
The other option is to just upgrade the Arduino-ESP32 core to bleeding-edge master. That can be done as seen in Arduino Espressif ESP32 - #2 by maxgerhardt.