Allow for use of the tarfile Python module in the archive state.
Pylint fix
Cleaner tar extraction by using the extractall method
Using a closing context with the with block
Merge pull request #9704 from bruce-one/use-tarfile-module

Allow for use of the tarfile Python module in the archive state.