Bug 186397 - sysutils/py-salt patch breaks salt
Summary: sysutils/py-salt patch breaks salt
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-python (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-02-03 01:40 UTC by mike
Modified: 2014-04-18 05:07 UTC (History)
0 users

See Also:


Attachments
file.diff (702 bytes, patch)
2014-02-03 01:40 UTC, mike
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description mike 2014-02-03 01:40:00 UTC
the patch file in sysutils/py-salt/files/patch-salt__modules__reebsdpkg.py
breaks pkg support on FreeBSD 10

FreeBSD 10 does not have /usr/local/etc/pkg.conf, but the original
freebsdpkg.py checks for /var/db/pkg/local.sqlite, which seems to be
accurate across 9.x and 10.0 systems

How-To-Repeat: Install Salt:

pkg install -y py27-salt

Accept that systems key, and use the pkg.list_pkgs module:


root@fbsd-qa:/usr/ports/sysutils/py-salt # salt-call pkg.list_pkgs
[INFO    ] Executing command '/sbin/zfs help || :' in directory '/root'
[INFO    ] Executing command 'None' in directory '/root'
[ERROR   ] An un-handled exception was caught by salt's global exception handler:
ValueError: need more than 1 value to unpack
Traceback (most recent call last):
  File "/usr/local/bin/salt-call", line 9, in <module>
    load_entry_point('salt==0.17.4', 'console_scripts', 'salt-call')()
  File "/usr/local/lib/python2.7/site-packages/salt/scripts.py", line 77, in salt_call
    client.run()
  File "/usr/local/lib/python2.7/site-packages/salt/cli/__init__.py", line 303, in run
    caller.run()
  File "/usr/local/lib/python2.7/site-packages/salt/cli/caller.py", line 135, in run
    ret = self.call()
  File "/usr/local/lib/python2.7/site-packages/salt/cli/caller.py", line 78, in call
    ret['return'] = func(*args, **kwargs)
  File "/usr/local/lib/python2.7/site-packages/salt/modules/freebsdpkg.py", line 187, in list_pkgs
    pkg, ver = line.split(' ')[0].rsplit('-', 1)
ValueError: need more than 1 value to unpack
Traceback (most recent call last):
  File "/usr/local/bin/salt-call", line 9, in <module>
    load_entry_point('salt==0.17.4', 'console_scripts', 'salt-call')()
  File "/usr/local/lib/python2.7/site-packages/salt/scripts.py", line 77, in salt_call
    client.run()
  File "/usr/local/lib/python2.7/site-packages/salt/cli/__init__.py", line 303, in run
    caller.run()
  File "/usr/local/lib/python2.7/site-packages/salt/cli/caller.py", line 135, in run
    ret = self.call()
  File "/usr/local/lib/python2.7/site-packages/salt/cli/caller.py", line 78, in call
    ret['return'] = func(*args, **kwargs)
  File "/usr/local/lib/python2.7/site-packages/salt/modules/freebsdpkg.py", line 187, in list_pkgs
    pkg, ver = line.split(' ')[0].rsplit('-', 1)
ValueError: need more than 1 value to unpack
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2014-02-03 10:40:13 UTC
Responsible Changed
From-To: freebsd-ports-bugs->freebsd-python

freebsd-python@ wants this port PRs (via the GNATS Auto Assign Tool)
Comment 2 Edwin Groothuis freebsd_committer freebsd_triage 2014-02-03 10:40:14 UTC
Maintainer of sysutils/py-salt,

Please note that PR ports/186397 has just been submitted.

If it contains a patch for an upgrade, an enhancement or a bug fix
you agree on, reply to this email stating that you approve the patch
and a committer will take care of it.

The full text of the PR can be found at:
    http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/186397

-- 
Edwin Groothuis via the GNATS Auto Assign Tool
edwin@FreeBSD.org
Comment 3 Edwin Groothuis freebsd_committer freebsd_triage 2014-02-03 10:40:15 UTC
State Changed
From-To: open->feedback

Awaiting maintainers feedback (via the GNATS Auto Assign Tool)
Comment 4 Johannes Jost Meixner freebsd_committer freebsd_triage 2014-04-18 05:07:52 UTC
State Changed
From-To: feedback->closed

Patch included in revision 348607