Fixes #6903
Closes #6906
Closes #6907
This combines #6906 and #6907, so that there are no failed CI jobs when merging into master separately.
Summary:
- Add macos-latest runners for each version of Python
- Update the temp dependencies script with newly built wheels
- Add
is_linuxcheck in the compat module (to be able to exclude the BSDs) - Add test markers for linux/darwin in addition to the POSIX marker
- Fix
HTTPSession.set_interface()on macOS when using an interface name - Override urllib3's
util.connection._set_socket_options()to be able to filter out options on macOS which can't be set depending on the socket's address family (when the connection is made/attempted)
As said in #6907, choosing an incorrect name only logs an error message and then continues using the default interface.
The macOS CI test runners could be ignored if we'd monkeypatch/mock the respective socket APIs and the is_darwin check, but I don't really like this idea. Should the CI test runners become too annoying due to being unable to spawn all of them at the same time, then I will maybe change this though.