Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

possible fix for #56716 #58199

Open
wants to merge 1 commit into
base: devel
from

Conversation

Projects
None yet
3 participants
@philfry
Copy link

commented Jun 21, 2019

SUMMARY

Fixes #56716

Removes unnecessary check_mode checks from the copy action/module. The subsequent modules have their own check_mode checks and still return valuable data.

This PR is not perfect but it's far better having a reasonable subset of return values than nothing.
It works for me but please test it before merging.

ISSUE TYPE
  • Bugfix Pull Request
COMPONENT NAME

modules/files/copy.py
plugins/action/copy.py

ADDITIONAL INFORMATION

run the following playbook with -vvv and watch the resultset

- hosts: localhost
  gather_facts: no
  tasks:
    - copy: content="." dest="/tmp/ansible-copy-test"
      check_mode: yes
    - copy: content="." dest="/tmp/ansible-copy-test"
      check_mode: no
@ansibot

This comment has been minimized.

Copy link
Contributor

commented Jun 21, 2019

@ansibot

This comment has been minimized.

Copy link
Contributor

commented Jun 21, 2019

The test ansible-test sanity --test pylint [explain] failed with 1 error:

lib/ansible/modules/files/copy.py:777:31: multiple-statements More than one statement on a single line

The test ansible-test sanity --test pep8 [explain] failed with 1 error:

lib/ansible/modules/files/copy.py:777:30: E701 multiple statements on one line (colon)

click here for bot help

@ansibot ansibot added needs_revision and removed core_review labels Jun 21, 2019

{modules/files,plugins/action}/copy.py: check_mode check is not neede…
…d here. The subsequent modules have check_mode checks, too

@philfry philfry force-pushed the philfry:fix_56716 branch from 9c4cec6 to b34a8e8 Jun 21, 2019

@ansibot ansibot removed the small_patch label Jun 21, 2019

@ansibot ansibot removed the needs_triage label Jun 21, 2019

@ansibot ansibot added the stale_ci label Jun 29, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.