fix grains filter_by function when using salt-ssh

very similar to #18238 and 7975b0a11
Merge branch 'salt-ssh-grains-fix' of https://github.com/slafs/salt into slafs-salt-ssh-grains-fix

Conflicts:
	salt/client/ssh/wrapper/grains.py
Add missign exception import
Fix docker state documentation typo
fix output of subsequent calls for ``environ.setenv`` state

Previously ``setenv`` function (from ``modules.environ``) was
called even if the environment was already in a proper state.
This caused ``highstate`` to always report changes to be applied
even if they were not required.
remove the leftovers from the previous file
Use proper query method from CloudClient
mapper.opts, not self.opts
Cleaup pprint
Merge pull request #18259 from thatch45/slafs-salt-ssh-grains-fix

Merge #18249 with fixes
Merge pull request #18287 from klyr/fix_docker_doc_typo

Fix docker state documentation typo
Fix missing cls variable and add some docstring info
Merge pull request #18293 from slafs/env-change-fix

fix output of subsequent calls for ``environ.setenv`` state
Merge pull request #18326 from rallytime/pylinting

Fix missing cls variable and add some docstring info
Merge pull request #18323 from techhat/cloudclient

Use proper query method from CloudClient
Use the `skip_if_binaries_missing_helper`
Make salt.fileclient Python3 compatible
Use `urlparse` from six
Use `urlparse` from six
Use `urljoin` from six