mirror of
https://git.freebsd.org/ports.git
synced 2025-07-18 09:49:18 -04:00
sysutils/py-supervisor: Update to 3.0
- Update to 3.0 (and bump PORTEPOCH) - Update pkg-plist - Replace NOPORTDOCS with DOCS (pet portlint) - Remove unecessary test_childutils patch (upstreamed) - Disable two failing tests and report upstream [1] Changes: https://github.com/Supervisor/supervisor/blob/3.0/CHANGES.txt [1] https://github.com/Supervisor/supervisor/issues/284 [1] https://github.com/Supervisor/supervisor/issues/285 PR: ports/181138 Approved by: Ildar Hizbulin <hizel@vyborg.ru> (maintainer)
This commit is contained in:
parent
53b9f84cd2
commit
c5d0ef85f7
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=325328
7 changed files with 125 additions and 28 deletions
|
@ -2,7 +2,8 @@
|
||||||
# $FreeBSD$
|
# $FreeBSD$
|
||||||
|
|
||||||
PORTNAME= supervisor
|
PORTNAME= supervisor
|
||||||
PORTVERSION= 3.0b1
|
PORTVERSION= 3.0
|
||||||
|
PORTEPOCH= 1
|
||||||
CATEGORIES= sysutils python
|
CATEGORIES= sysutils python
|
||||||
MASTER_SITES= CHEESESHOP
|
MASTER_SITES= CHEESESHOP
|
||||||
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
|
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
|
||||||
|
@ -42,7 +43,7 @@ post-install:
|
||||||
[ -d ${PIDDIR} ] || ${MKDIR} ${PIDDIR}
|
[ -d ${PIDDIR} ] || ${MKDIR} ${PIDDIR}
|
||||||
${INSTALL_DATA} ${FILESDIR}/supervisord.conf.sample ${PREFIX}/etc
|
${INSTALL_DATA} ${FILESDIR}/supervisord.conf.sample ${PREFIX}/etc
|
||||||
[ -f ${PREFIX}/etc/supervisord.conf ] || ${CP} -p ${PREFIX}/etc/supervisord.conf.sample ${PREFIX}/etc/supervisord.conf
|
[ -f ${PREFIX}/etc/supervisord.conf ] || ${CP} -p ${PREFIX}/etc/supervisord.conf.sample ${PREFIX}/etc/supervisord.conf
|
||||||
.if !defined(NOPORTDOCS)
|
.if ${PORT_OPTIONS:MDOCS}
|
||||||
${MKDIR} ${DOCSDIR}
|
${MKDIR} ${DOCSDIR}
|
||||||
.for i in ${PORTDOCS}
|
.for i in ${PORTDOCS}
|
||||||
@${INSTALL_DATA} ${WRKSRC}/${i} ${DOCSDIR}/
|
@${INSTALL_DATA} ${WRKSRC}/${i} ${DOCSDIR}/
|
||||||
|
|
|
@ -1,2 +1,2 @@
|
||||||
SHA256 (supervisor-3.0b1.tar.gz) = 7361e224871257534cac3bc035e90571c35b9fa9245ec46207de9d89191a7d0c
|
SHA256 (supervisor-3.0.tar.gz) = 82aac54c5760b6a4f4c28dda203714e362a68b4a9ba8549fa65955998e3a2212
|
||||||
SIZE (supervisor-3.0b1.tar.gz) = 452676
|
SIZE (supervisor-3.0.tar.gz) = 459820
|
||||||
|
|
|
@ -1,11 +0,0 @@
|
||||||
--- supervisor/tests/test_childutils.py
|
|
||||||
+++ supervisor/tests/test_childutils.py
|
|
||||||
@@ -41,7 +41,7 @@ class ChildUtilsTests(unittest.TestCase):
|
|
||||||
|
|
||||||
def test_get_asctime(self):
|
|
||||||
from supervisor.childutils import get_asctime
|
|
||||||
- timestamp = time.mktime((2009, 1, 18, 22, 14, 7, 0, 0, 0))
|
|
||||||
+ timestamp = time.mktime((2009, 1, 18, 22, 14, 7, 0, 0, -1))
|
|
||||||
result = get_asctime(timestamp)
|
|
||||||
self.assertEqual(result, '2009-01-18 22:14:07,000')
|
|
||||||
|
|
|
@ -0,0 +1,71 @@
|
||||||
|
--- supervisor/tests/test_options.py.old 2013-08-23 15:04:37.000000000 +0400
|
||||||
|
+++ supervisor/tests/test_options.py 2013-08-23 15:07:45.000000000 +0400
|
||||||
|
@@ -56,12 +56,12 @@
|
||||||
|
short='p:', long='other=', handler=integer)
|
||||||
|
return options
|
||||||
|
|
||||||
|
- def test_searchpaths(self):
|
||||||
|
- options = self._makeOptions()
|
||||||
|
- self.assertEquals(len(options.searchpaths), 5)
|
||||||
|
- self.assertTrue('supervisord.conf' in options.searchpaths)
|
||||||
|
- self.assertTrue('etc/supervisord.conf' in options.searchpaths)
|
||||||
|
- self.assertTrue('/etc/supervisord.conf' in options.searchpaths)
|
||||||
|
+# def test_searchpaths(self):
|
||||||
|
+# options = self._makeOptions()
|
||||||
|
+# self.assertEquals(len(options.searchpaths), 5)
|
||||||
|
+# self.assertTrue('supervisord.conf' in options.searchpaths)
|
||||||
|
+# self.assertTrue('etc/supervisord.conf' in options.searchpaths)
|
||||||
|
+# self.assertTrue('/etc/supervisord.conf' in options.searchpaths)
|
||||||
|
|
||||||
|
def test_options_and_args_order(self):
|
||||||
|
# Only config file exists
|
||||||
|
@@ -209,15 +209,15 @@
|
||||||
|
else:
|
||||||
|
self.fail("expected exception")
|
||||||
|
|
||||||
|
- tempf = tempfile.NamedTemporaryFile()
|
||||||
|
- os.chmod(tempf.name, 0) # Removing read perms
|
||||||
|
- try:
|
||||||
|
- instance.read_config(tempf.name)
|
||||||
|
- except ValueError, e:
|
||||||
|
- self.assertTrue("could not read config file" in str(e))
|
||||||
|
- else:
|
||||||
|
- self.fail("expected exception")
|
||||||
|
- tempf.close()
|
||||||
|
+# tempf = tempfile.NamedTemporaryFile()
|
||||||
|
+# os.chmod(tempf.name, 0) # Removing read perms
|
||||||
|
+# try:
|
||||||
|
+# instance.read_config(tempf.name)
|
||||||
|
+# except ValueError, e:
|
||||||
|
+# self.assertTrue("could not read config file" in str(e))
|
||||||
|
+# else:
|
||||||
|
+# self.fail("expected exception")
|
||||||
|
+# tempf.close()
|
||||||
|
|
||||||
|
def test_options_unixsocket_cli(self):
|
||||||
|
from StringIO import StringIO
|
||||||
|
@@ -616,15 +616,15 @@
|
||||||
|
else:
|
||||||
|
self.fail("expected exception")
|
||||||
|
|
||||||
|
- tempf = tempfile.NamedTemporaryFile()
|
||||||
|
- os.chmod(tempf.name, 0) # Removing read perms
|
||||||
|
- try:
|
||||||
|
- instance.read_config(tempf.name)
|
||||||
|
- except ValueError, e:
|
||||||
|
- self.assertTrue("could not read config file" in str(e))
|
||||||
|
- else:
|
||||||
|
- self.fail("expected exception")
|
||||||
|
- tempf.close()
|
||||||
|
+# tempf = tempfile.NamedTemporaryFile()
|
||||||
|
+# os.chmod(tempf.name, 0) # Removing read perms
|
||||||
|
+# try:
|
||||||
|
+# instance.read_config(tempf.name)
|
||||||
|
+# except ValueError, e:
|
||||||
|
+# self.assertTrue("could not read config file" in str(e))
|
||||||
|
+# else:
|
||||||
|
+# self.fail("expected exception")
|
||||||
|
+# tempf.close()
|
||||||
|
|
||||||
|
def test_readFile_failed(self):
|
||||||
|
from supervisor.options import readFile
|
|
@ -0,0 +1,35 @@
|
||||||
|
--- supervisor/tests/test_supervisorctl.py.old 2013-05-27 06:39:09.000000000 +0400
|
||||||
|
+++ supervisor/tests/test_supervisorctl.py 2013-08-23 15:06:11.000000000 +0400
|
||||||
|
@@ -889,19 +889,19 @@
|
||||||
|
val = plugin.ctl.stdout.getvalue()
|
||||||
|
self.failUnless(val.startswith('Error: bad argument wrong'), val)
|
||||||
|
|
||||||
|
- def test_maintail_dashf(self):
|
||||||
|
- plugin = self._makeOne()
|
||||||
|
- plugin.listener = DummyListener()
|
||||||
|
- result = plugin.do_maintail('-f')
|
||||||
|
- errors = plugin.listener.errors
|
||||||
|
- self.assertEqual(len(errors), 1)
|
||||||
|
- error = errors[0]
|
||||||
|
- self.assertEqual(plugin.listener.closed,
|
||||||
|
- 'http://localhost:65532/mainlogtail')
|
||||||
|
- self.assertEqual(error[0],
|
||||||
|
- 'http://localhost:65532/mainlogtail')
|
||||||
|
- for msg in ('Cannot connect', 'socket.error'):
|
||||||
|
- self.assertTrue(msg in error[1])
|
||||||
|
+# def test_maintail_dashf(self):
|
||||||
|
+# plugin = self._makeOne()
|
||||||
|
+# plugin.listener = DummyListener()
|
||||||
|
+# result = plugin.do_maintail('-f')
|
||||||
|
+# errors = plugin.listener.errors
|
||||||
|
+# self.assertEqual(len(errors), 1)
|
||||||
|
+# error = errors[0]
|
||||||
|
+# self.assertEqual(plugin.listener.closed,
|
||||||
|
+# 'http://localhost:65532/mainlogtail')
|
||||||
|
+# self.assertEqual(error[0],
|
||||||
|
+# 'http://localhost:65532/mainlogtail')
|
||||||
|
+# for msg in ('Cannot connect', 'socket.error'):
|
||||||
|
+# self.assertTrue(msg in error[1])
|
||||||
|
|
||||||
|
def test_maintail_nobytes(self):
|
||||||
|
plugin = self._makeOne()
|
|
@ -1,14 +1,14 @@
|
||||||
--- supervisor/options.py.orig 2012-01-10 12:55:20.000000000 +0300
|
--- supervisor/options.py.orig 2013-06-20 21:00:12.000000000 +0400
|
||||||
+++ supervisor/options.py 2012-01-10 12:56:14.000000000 +0300
|
+++ supervisor/options.py 2013-08-08 14:41:08.000000000 +0400
|
||||||
@@ -92,10 +92,7 @@
|
@@ -99,10 +99,7 @@
|
||||||
def default_configfile(self):
|
self.add("configfile", None, "c:", "configuration=")
|
||||||
"""Return the name of the found config file or raise. """
|
|
||||||
here = os.path.dirname(os.path.dirname(sys.argv[0]))
|
here = os.path.dirname(os.path.dirname(sys.argv[0]))
|
||||||
- paths = [os.path.join(here, 'etc', 'supervisord.conf'),
|
- searchpaths = [os.path.join(here, 'etc', 'supervisord.conf'),
|
||||||
- os.path.join(here, 'supervisord.conf'),
|
- os.path.join(here, 'supervisord.conf'),
|
||||||
- 'supervisord.conf', 'etc/supervisord.conf',
|
- 'supervisord.conf', 'etc/supervisord.conf',
|
||||||
- '/etc/supervisord.conf']
|
- '/etc/supervisord.conf']
|
||||||
+ paths = [ '%%PREFIX%%/etc/supervisord.conf' ]
|
+ searchpaths = [ '/usr/local/etc/supervisord.conf' ]
|
||||||
config = None
|
self.searchpaths = searchpaths
|
||||||
for path in paths:
|
|
||||||
if os.path.exists(path):
|
def default_configfile(self):
|
||||||
|
|
|
@ -318,6 +318,7 @@ etc/supervisord.conf.sample
|
||||||
%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/supervisor/ui/images/button_refresh.gif
|
%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/supervisor/ui/images/button_refresh.gif
|
||||||
%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/supervisor/ui/images/button_restart.gif
|
%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/supervisor/ui/images/button_restart.gif
|
||||||
%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/supervisor/ui/images/button_stop.gif
|
%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/supervisor/ui/images/button_stop.gif
|
||||||
|
%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/supervisor/ui/images/icon.png
|
||||||
%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/supervisor/ui/images/rule.gif
|
%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/supervisor/ui/images/rule.gif
|
||||||
%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/supervisor/ui/images/state0.gif
|
%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/supervisor/ui/images/state0.gif
|
||||||
%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/supervisor/ui/images/state1.gif
|
%%PYTHON_SITELIBDIR%%/%%PYEASYINSTALL_EGG%%/supervisor/ui/images/state1.gif
|
||||||
|
|
Loading…
Add table
Reference in a new issue