Hello community,
here is the log from the commit of package python-configshell-fb for
openSUSE:Factory checked in at 2018-10-22 11:24:49
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-configshell-fb (Old)
and /work/SRC/openSUSE:Factory/.python-configshell-fb.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-configshell-fb"
Mon Oct 22 11:24:49 2018 rev:8 rq:643262 version:1.1.fb25
Changes:
--------
---
/work/SRC/openSUSE:Factory/python-configshell-fb/python-configshell-fb.changes
2018-02-27 16:58:14.343432439 +0100
+++
/work/SRC/openSUSE:Factory/.python-configshell-fb.new/python-configshell-fb.changes
2018-10-22 11:25:01.647055121 +0200
@@ -1,0 +2,21 @@
+Thu Oct 18 23:37:59 UTC 2018 - [email protected]
+
+- Update to version 1.1.fb23:
+ * version 1.1.25
+ * Fix failing to parse param like pool/rbd;id=user
+ * Acquire a lock to a preference file before working with it
+ * Fix failing to pasre param like "cfgstr,par=val"
+ * version 1.1.fb24
+ * Remove explicit dependency on /usr/bin/python
+ * make run_cmdline() log "Running command line" msg to new loglevel
+ * tweak ConfigShell.run_stdin() to strip whitespace/newline from cmds
+ * Fix failing to pasre par=val parameters
+ * Add missing dependency on pyparsing and six
+ * Fix path regex for [ and ]
+ * Handle if TERM is not set
+ Replacing configshell-fb-1.1.fb23.tar.xz with configshell-fb-1.1.fb25.tar.xz,
+ and updating the SPEC file. Also, two patches subsumed/removed:
+ * configshell-fb-example-should-not-specify-path.patch
+ * configshell-fb-Handle-if-TERM-is-not-set.patch
+
+-------------------------------------------------------------------
Old:
----
configshell-fb-1.1.fb23.tar.xz
configshell-fb-Handle-if-TERM-is-not-set.patch
configshell-fb-example-should-not-specify-path.patch
New:
----
configshell-fb-1.1.fb25.tar.xz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-configshell-fb.spec ++++++
--- /var/tmp/diff_new_pack.yis1MT/_old 2018-10-22 11:25:02.195054579 +0200
+++ /var/tmp/diff_new_pack.yis1MT/_new 2018-10-22 11:25:02.199054575 +0200
@@ -17,18 +17,16 @@
%define oname configshell-fb
-%define realver 1.1.fb23
+%define realver 1.1.fb25
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
Name: python-%{oname}
-Version: 1.1.fb23
+Version: 1.1.fb25
Release: 0%{?dist}
Summary: A Python library for building configuration shells
License: Apache-2.0
Group: Development/Libraries/Python
Url: http://github.com/open-iscsi/configshell-fb
Source: %{oname}-%{realver}.tar.xz
-Patch1: %{oname}-example-should-not-specify-path.patch
-Patch2: %{oname}-Handle-if-TERM-is-not-set.patch
BuildRequires: %{python_module devel}
BuildRequires: %{python_module pyparsing}
BuildRequires: %{python_module setuptools}
@@ -70,8 +68,6 @@
%prep
%setup -q -n %{oname}-%{realver}
-%patch1 -p1
-%patch2 -p1
%build
%python_build
++++++ _service ++++++
--- /var/tmp/diff_new_pack.yis1MT/_old 2018-10-22 11:25:02.235054539 +0200
+++ /var/tmp/diff_new_pack.yis1MT/_new 2018-10-22 11:25:02.235054539 +0200
@@ -4,8 +4,8 @@
<param name="url">https://github.com/open-iscsi/configshell-fb.git</param>
<param name="subdir"></param>
<param name="filename">configshell-fb</param>
- <param name="versionformat">1.1.fb23</param>
- <param name="revision">v1.1.fb23</param>
+ <param name="versionformat">1.1.fb25</param>
+ <param name="revision">v1.1.fb25</param>
<param name="changesgenerate">enable</param>
</service>
<service name="recompress" mode="disabled">
++++++ _servicedata ++++++
--- /var/tmp/diff_new_pack.yis1MT/_old 2018-10-22 11:25:02.247054528 +0200
+++ /var/tmp/diff_new_pack.yis1MT/_new 2018-10-22 11:25:02.251054523 +0200
@@ -1,4 +1,4 @@
<servicedata>
<service name="tar_scm">
<param
name="url">https://github.com/open-iscsi/configshell-fb.git</param>
- <param
name="changesrevision">1299055734eeaf849cc7d3227731626bcf127e02</param></service></servicedata>
\ No newline at end of file
+ <param
name="changesrevision">166ba97e36d7b53e7fa53d7853a8b9f5a509503c</param></service></servicedata>
\ No newline at end of file
++++++ configshell-fb-1.1.fb23.tar.xz -> configshell-fb-1.1.fb25.tar.xz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/configshell-fb-1.1.fb23/configshell/log.py
new/configshell-fb-1.1.fb25/configshell/log.py
--- old/configshell-fb-1.1.fb23/configshell/log.py 2017-03-02
00:21:57.000000000 +0100
+++ new/configshell-fb-1.1.fb25/configshell/log.py 2018-08-31
13:02:32.000000000 +0200
@@ -28,6 +28,7 @@
Implements a file and console logger using python's logging facility.
Log levels are, in raising criticality:
- debug
+ - verbose
- info
- warning
- error
@@ -36,9 +37,9 @@
who can then be read/changed by other objects using Prefs()
'''
__borg_state = {}
- levels = ['critical', 'error', 'warning', 'info', 'debug']
+ levels = ['critical', 'error', 'warning', 'info', 'verbose', 'debug']
colors = {'critical': 'red', 'error': 'red', 'warning': 'yellow',
- 'info': 'green', 'debug': 'blue'}
+ 'info': 'green', 'verbose': 'blue', 'debug': 'blue'}
def __init__(self, console_level=None,
logfile=None, file_level=None):
@@ -138,6 +139,14 @@
trace += '\n%s' % msg
self._log('error', trace)
+ def verbose(self, msg):
+ '''
+ Logs a verbose message.
+ @param msg: The message to log.
+ @type msg: str
+ '''
+ self._log('verbose', msg)
+
def info(self, msg):
'''
Logs an info message.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/configshell-fb-1.1.fb23/configshell/prefs.py
new/configshell-fb-1.1.fb25/configshell/prefs.py
--- old/configshell-fb-1.1.fb23/configshell/prefs.py 2017-03-02
00:21:57.000000000 +0100
+++ new/configshell-fb-1.1.fb25/configshell/prefs.py 2018-08-31
13:02:32.000000000 +0200
@@ -16,6 +16,7 @@
'''
import six
+import fcntl
class Prefs(object):
'''
@@ -128,6 +129,7 @@
if filename is not None:
fsock = open(filename, 'wb')
+ fcntl.lockf(fsock, fcntl.LOCK_UN)
try:
six.moves.cPickle.dump(self._prefs, fsock, 2)
finally:
@@ -143,6 +145,7 @@
if filename is not None:
fsock = open(filename, 'rb')
+ fcntl.lockf(fsock, fcntl.LOCK_SH)
try:
self._prefs = six.moves.cPickle.load(fsock)
finally:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/configshell-fb-1.1.fb23/configshell/shell.py
new/configshell-fb-1.1.fb25/configshell/shell.py
--- old/configshell-fb-1.1.fb23/configshell/shell.py 2017-03-02
00:21:57.000000000 +0100
+++ new/configshell-fb-1.1.fb25/configshell/shell.py 2018-08-31
13:02:32.000000000 +0200
@@ -50,13 +50,14 @@
tty=False
# remember the original setting
- oldTerm = os.environ['TERM']
+ oldTerm = os.environ.get('TERM')
os.environ['TERM'] = ''
import readline
# restore the orignal TERM setting
- os.environ['TERM'] = oldTerm
+ if oldTerm != None:
+ os.environ['TERM'] = oldTerm
del oldTerm
# Pyparsing helper to group the location of a token and its value
@@ -117,7 +118,7 @@
# Grammar of the command line
command = locatedExpr(Word(alphanums + '_'))('command')
- var = Word(alphanums + '_\+/.<>()~@:-%[]')
+ var = Word(alphanums + ';,=_\+/.<>()~@:-%[]')
value = var
keyword = Word(alphanums + '_\-')
kparam = locatedExpr(keyword + Suppress('=') + Optional(value,
default=''))('kparams*')
@@ -125,7 +126,7 @@
parameter = kparam | pparam
parameters = OneOrMore(parameter)
bookmark = Regex('@([A-Za-z0-9:_.]|-)+')
- pathstd = Regex('([A-Za-z0-9:_.]|-)*' + '/' + '([A-Za-z0-9:_./]|-)*') \
+ pathstd = Regex('([A-Za-z0-9:_.\[\]]|-)*' + '/' +
'([A-Za-z0-9:_.\[\]/]|-)*') \
| '..' | '.'
path = locatedExpr(bookmark | pathstd | '*')('path')
parser = Optional(path) + Optional(command) + Optional(parameters)
@@ -842,7 +843,7 @@
@type cmdline: str
'''
if cmdline:
- self.log.debug("Running command line '%s'." % cmdline)
+ self.log.verbose("Running command line '%s'." % cmdline)
path, command, pparams, kparams = self._parse_cmdline(cmdline)[1:]
self._execute_command(path, command, pparams, kparams)
@@ -875,7 +876,7 @@
self._current_node = self._root_node
for cmdline in file_descriptor:
try:
- self.run_cmdline(cmdline)
+ self.run_cmdline(cmdline.strip())
except Exception as msg:
self.log.error(msg)
if exit_on_error is True:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/configshell-fb-1.1.fb23/examples/myshell
new/configshell-fb-1.1.fb25/examples/myshell
--- old/configshell-fb-1.1.fb23/examples/myshell 2017-03-02
00:21:57.000000000 +0100
+++ new/configshell-fb-1.1.fb25/examples/myshell 2018-08-31
13:02:32.000000000 +0200
@@ -1,4 +1,4 @@
-#!/usr/bin/python
+#!/usr/bin/env python
'''
This file is part of ConfigShell.
Copyright (c) 2011-2013 by Datera, Inc
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/configshell-fb-1.1.fb23/setup.py
new/configshell-fb-1.1.fb25/setup.py
--- old/configshell-fb-1.1.fb23/setup.py 2017-03-02 00:21:57.000000000
+0100
+++ new/configshell-fb-1.1.fb25/setup.py 2018-08-31 13:02:32.000000000
+0200
@@ -20,13 +20,17 @@
setup(
name = 'configshell-fb',
- version = '1.1.23',
+ version = '1.1.25',
description = 'A framework to implement simple but nice CLIs.',
license = 'Apache 2.0',
maintainer = 'Andy Grover',
maintainer_email = '[email protected]',
url = 'http://github.com/open-iscsi/configshell-fb',
packages = ['configshell', 'configshell_fb'],
+ install_requires = [
+ 'pyparsing',
+ 'six',
+ ],
classifiers = [
"Programming Language :: Python",
"Programming Language :: Python :: 3",