If the issue is in a (system supplied) pathlib module provided by Azure, just make sure you use your own Python and libs installation. This should be fairly straightforward when building and deploying a docker container.