This is a note for anyone who might happen to bump into this issue when adding Windows to their CI setups.
When attempting to, for example, open a socket, you might see an error message like the following:
socket: The requested service provider could not be loaded or initialized
This typically happens where you are attempting to perform this socket open (or similar) in a restricted environment where the
SYSTEMROOT environment variable is not set.
On Windows, the
SYSTEMROOT environment variable must be preserved for DLLs to correctly load.