Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 598472 - =sys-block/targetcli-fb-2.1.44 requires >=dev-python/rtslib-fb-2.1.61
Summary: =sys-block/targetcli-fb-2.1.44 requires >=dev-python/rtslib-fb-2.1.61
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Diogo Pereira
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 590984
  Show dependency tree
 
Reported: 2016-10-29 19:31 UTC by David Klaftenegger
Modified: 2016-11-04 21:45 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description David Klaftenegger 2016-10-29 19:31:07 UTC
The targetcli application from =sys-block/targetcli-fb-2.1.44 is currently broken, as it uses a feature not yet present in dev-python/rtslib-fb-2.1.58.
I am not sure whether this bug belongs to targetcli-fb or =dev-python/configshell-fb-1.1.21, but the effect is the same.

To reproduce:

# targetcli 
targetcli shell version 2.1.fb44
Copyright 2011-2013 by Datera, Inc and others.
For help on commands, type 'help'.

/iscsi/iqn.31...12ab6541/tpg1> ls
Traceback (most recent call last):
  File "/usr/lib/python-exec/python3.4/targetcli", line 121, in <module>
    main()
  File "/usr/lib/python-exec/python3.4/targetcli", line 111, in main
    shell.run_interactive()
  File "/usr/lib64/python3.4/site-packages/configshell_fb/shell.py", line 894, in run_interactive
    self._cli_loop()
  File "/usr/lib64/python3.4/site-packages/configshell_fb/shell.py", line 723, in _cli_loop
    self.run_cmdline(cmdline)
  File "/usr/lib64/python3.4/site-packages/configshell_fb/shell.py", line 837, in run_cmdline
    self._execute_command(path, command, pparams, kparams)
  File "/usr/lib64/python3.4/site-packages/configshell_fb/shell.py", line 812, in _execute_command
    result = target.execute_command(command, pparams, kparams)
  File "/usr/lib64/python3.4/site-packages/configshell_fb/node.py", line 1406, in execute_command
    return method(*pparams, **kparams)
  File "/usr/lib64/python3.4/site-packages/configshell_fb/node.py", line 710, in ui_command_ls
    tree = self._render_tree(target, depth=depth)
  File "/usr/lib64/python3.4/site-packages/configshell_fb/node.py", line 861, in _render_tree
    + self._render_tree(children[i], margin, depth)
  File "/usr/lib64/python3.4/site-packages/configshell_fb/node.py", line 861, in _render_tree
    + self._render_tree(children[i], margin, depth)
  File "/usr/lib64/python3.4/site-packages/configshell_fb/node.py", line 765, in _render_tree
    (description, is_healthy) = root.summary()
  File "/usr/lib64/python3.4/site-packages/targetcli/ui_target.py", line 1440, in summary
    elif self.rtsnode.offload:
AttributeError: 'NetworkPortal' object has no attribute 'offload'


Accoding to the git history available at

https://github.com/open-iscsi/rtslib-fb/commits/master

the offload code was added in version 2.1.fb61.
Comment 1 David Klaftenegger 2016-10-29 19:44:50 UTC
When downgrading to =sys-block/targetcli-fb-2.1.43 using a local overlay (as that version is not in the tree), the bug disappears.
Comment 2 NoNo 2016-10-31 22:59:02 UTC
I sadly confirm this bug...

* Applications installed on my gentoo system:
dev-python/configshell-fb-1.1.21
dev-python/rtslib-fb-2.1.58
sys-block/targetcli-fb-2.1.44

* Python's flags in make.conf:
PYTHON_TARGETS="python2_7 python3_4"
PYTHON_SINGLE_TARGET="python2_7"
USE_PYTHON='2.7'

To prevent this error to occur, I Commented line 1440 and 1441 in this script:
/usr/lib64/python2.7/site-packages/targetcli/ui_target.py

#        elif self.rtsnode.offload:
#            return('offload', True)
Comment 3 Coacher 2016-11-01 15:28:17 UTC
targetcli touches 'offload' property: https://github.com/open-iscsi/targetcli-fb/blob/v2.1.fb44/targetcli/ui_target.py#L1440
rstlib-fb commit, which introduced 'offload' property: https://github.com/open-iscsi/rtslib-fb/commit/e04d87b5f8e5c2252e18dab7a8778ee03a1bf171
Comment 4 Patrice Clement gentoo-dev 2016-11-04 21:45:47 UTC
commit 6d5c5658729d3f0fc3cf783b416545b8b313a7ec (HEAD -> master, origin/master, origin/HEAD)
Author:     Diogo Pereira <sir.suriv@gmail.com>
AuthorDate: Wed Nov 2 21:12:53 2016 +0000
Commit:     Patrice Clement <monsieurp@gentoo.org>
CommitDate: Fri Nov 4 22:45:16 2016 +0100

sys-block/targetcli-fb: update dependencies.

Gentoo-Bug: https://bugs.gentoo.org/598472
Reported-by: David Klaftenegger <davidweb@klaftenegger.de>
Closes: https://github.com/gentoo/gentoo/pull/2725

Signed-off-by: Patrice Clement <monsieurp@gentoo.org>

.../targetcli-fb/targetcli-fb-2.1.44-r1.ebuild     | 36 ++++++++++++++++++++++
sys-block/targetcli-fb/targetcli-fb-2.1.44.ebuild  | 36 ----------------------
2 files changed, 36 insertions(+), 36 deletions(-)
create mode 100644 sys-block/targetcli-fb/targetcli-fb-2.1.44-r1.ebuild
delete mode 100644 sys-block/targetcli-fb/targetcli-fb-2.1.44.ebuild

Merged! Thanks.