mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-23 05:10:22 -07:00
Fix to bytes surrogate and nonencodable chars (#21180)
* Add a surrogate_then_replace error strategy to keep to_bytes from tracebacking by default * Port all code that explicitly used surrogate_or_replace to surrogate_then_replace
This commit is contained in:
parent
149dd9ca86
commit
98541b7c8b
5 changed files with 94 additions and 39 deletions
|
@ -818,7 +818,7 @@ class ActionBase(with_metaclass(ABCMeta, object)):
|
|||
data['rc'] = res['rc']
|
||||
return data
|
||||
|
||||
def _low_level_execute_command(self, cmd, sudoable=True, in_data=None, executable=None, encoding_errors='surrogate_or_replace'):
|
||||
def _low_level_execute_command(self, cmd, sudoable=True, in_data=None, executable=None, encoding_errors='surrogate_then_replace'):
|
||||
'''
|
||||
This is the function which executes the low level shell command, which
|
||||
may be commands to create/remove directories for temporary files, or to
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue