Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 1061157 - targetcli: Traceback when grep its output
Summary: targetcli: Traceback when grep its output
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: python-configshell
Version: 7.0
Hardware: Unspecified
OS: Unspecified
Target Milestone: rc
: ---
Assignee: Andy Grover
QA Contact: Bruno Goncalves
Depends On: 996012
TreeView+ depends on / blocked
Reported: 2014-02-04 13:07 UTC by Bruno Goncalves
Modified: 2015-03-05 13:31 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of: 996012
Last Closed: 2015-03-05 13:31:28 UTC
Target Upstream Version:

Attachments (Terms of Use)

System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2015:0580 normal SHIPPED_LIVE python-configshell bug fix and enhancement update 2015-03-05 17:01:12 UTC

Comment 1 Bruno Goncalves 2014-02-04 13:10:12 UTC
Reproducible on targetcli-2.1.fb31-2.el7.noarch

targetcli /tcm_fc/naa.2000001b21591238 ls | grep naa
Traceback (most recent call last):
  File "/usr/bin/targetcli", line 89, in <module>
  File "/usr/bin/targetcli", line 72, in main
    shell.run_cmdline(" ".join(sys.argv[1:]))
  File "/usr/lib/python2.7/site-packages/configshell/", line 891, in run_cmdline
    self._execute_command(path, command, pparams, kparams)
  File "/usr/lib/python2.7/site-packages/configshell/", line 856, in _execute_command
  File "/usr/lib/python2.7/site-packages/configshell/", line 159, in error
    self._log('error', msg)
  File "/usr/lib/python2.7/site-packages/configshell/", line 112, in _log
  File "/usr/lib/python2.7/site-packages/configshell/", line 151, in display
  File "/usr/lib/python2.7/site-packages/configshell/", line 139, in raw_write
TypeError: expected a character buffer object

If there is no grep to problem does no happen.

# targetcli /tcm_fc/naa.2000001b21591238 ls
No such path /tcm_fc/naa.2000001b21591238

Comment 4 Andy Grover 2014-11-10 22:05:39 UTC
configshell-1.1.fb14 which is already in rhel 7.1 fixes this for me. Please confirm and I can add this bz to the errata.

Comment 5 Bruno Goncalves 2014-11-11 07:57:50 UTC
Verified the problem has been fixed using:


# targetcli /tcm_f ls | grep "tcm"
No such path /tcm_f

Comment 8 errata-xmlrpc 2015-03-05 13:31:28 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

Note You need to log in before you can comment on or make changes to this bug.