Revert "Allow ini plugin to load file using other encoding than utf8." (#27407)

* Revert "Update conventions in azure modules"

This reverts commit 30a688d8d3.

* Revert "Allow specific __future__ imports in modules"

This reverts commit 3a2670e0fd.

* Revert "Fix wildcard import in galaxy/token.py"

This reverts commit 6456891053.

* Revert "Fix one name in module error due to rewritten VariableManager"

This reverts commit 87a192fe66.

* Revert "Disable pylint check for names existing in modules for test data"

This reverts commit 6ac683ca19.

* Revert "Allow ini plugin to load file using other encoding than utf8."

This reverts commit 6a57ad34c0.
This commit is contained in:
Toshio Kuratomi 2017-07-27 17:08:31 -07:00 committed by GitHub
parent 30a688d8d3
commit 520696fb39
9 changed files with 35 additions and 78 deletions

View file

@ -179,7 +179,7 @@ class DataLoader:
except AttributeError:
pass # older versions of yaml don't have dispose function, ignore
def _get_file_contents(self, file_name, encoding='utf-8'):
def _get_file_contents(self, file_name):
'''
Reads the file contents from the given file name, and will decrypt them
if they are found to be vault-encrypted.
@ -194,7 +194,7 @@ class DataLoader:
show_content = True
try:
with open(b_file_name, 'rb') as f:
data = to_text(f.read(), encoding=encoding)
data = f.read()
if is_encrypted(data):
data = self._vault.decrypt(data, filename=b_file_name)
show_content = False