mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-08 14:22:46 +00:00
2
changelogs/fragments/clarify_error_message.yml
Normal file
2
changelogs/fragments/clarify_error_message.yml
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
bugfixes:
|
||||||
|
- Fix an atomic_move error that is 'true', but misleading. Now we show all 3 files involved and clarify what happened.
|
||||||
@@ -2618,7 +2618,8 @@ class AnsibleModule(object):
|
|||||||
if unsafe_writes and e.errno == errno.EBUSY:
|
if unsafe_writes and e.errno == errno.EBUSY:
|
||||||
self._unsafe_writes(b_tmp_dest_name, b_dest)
|
self._unsafe_writes(b_tmp_dest_name, b_dest)
|
||||||
else:
|
else:
|
||||||
self.fail_json(msg='Unable to rename file: %s to %s: %s' % (src, dest, to_native(e)),
|
self.fail_json(msg='Unable to make %s into to %s, failed final rename from %s: %s' %
|
||||||
|
(src, dest, b_tmp_dest_name, to_native(e)),
|
||||||
exception=traceback.format_exc())
|
exception=traceback.format_exc())
|
||||||
except (shutil.Error, OSError, IOError) as e:
|
except (shutil.Error, OSError, IOError) as e:
|
||||||
self.fail_json(msg='Failed to replace file: %s to %s: %s' % (src, dest, to_native(e)),
|
self.fail_json(msg='Failed to replace file: %s to %s: %s' % (src, dest, to_native(e)),
|
||||||
|
|||||||
Reference in New Issue
Block a user