ansible-collections / dellemc.os10

GNU General Public License v3.0
37 stars 49 forks source link

Module os10_command - incorrect stdout content in case of "| grep" inside the command #50

Open igloo777 opened 3 years ago

igloo777 commented 3 years ago
SUMMARY

Hello. I see the incorrect stdout content in case when I use "| grep" inside the command. Without "| grep" module works correctly.

ISSUE TYPE
COMPONENT NAME

Module os10_command, collection dellemc.os10 ver. 1.0.1 (from galaxy).

ANSIBLE VERSION
ansible 2.10.2
  python version = 3.8.5 (default, Jul 28 2020, 12:59:40) [GCC 9.3.0]
OS / ENVIRONMENT

Dell EMC Networking OS10 Enterprise Copyright (c) 1999-2020 by Dell Inc. All Rights Reserved. OS Version: 10.5.1.4 Build Version: 10.5.1.4.249 Build Time: 2020-07-22T21:29:21+0000 System Type: S4112F-ON Architecture: x86_64

STEPS TO REPRODUCE
      - name: "Check SNMP acl"
        dellemc.os10.os10_command:
          commands: show running-configuration access-list | grep ACL_SNMP_ACCESS
          wait_for: result[0] contains SNMP
EXPECTED RESULTS

If ACL exist on device, I expect to see in stdout only output of command (as in CLI of device).

ip access-list ACL_SNMP_ACCESS

or "" if ACL doesn't exitt.

ACTUAL RESULTS

Attached below image

gunasekaran-t commented 3 years ago

@igloo777 Could you please update if the issue consistency occurs. I could not recreate the issue with different approaches. If possible could you please try recreating the playbook and try running it. If the issue still occurs please attach the playbook file.