diff --git a/fix-sleep-path-in-test.patch b/fix-sleep-path-in-test.patch deleted file mode 100644 index 5cff187..0000000 --- a/fix-sleep-path-in-test.patch +++ /dev/null @@ -1,13 +0,0 @@ -Index: sh-1.13.1/test.py -=================================================================== ---- sh-1.13.1.orig/test.py -+++ sh-1.13.1/test.py -@@ -1974,7 +1974,7 @@ sys.stdout.write("line1") - try: - sh.sleep(sleep_for, _timeout=timeout).wait() - except sh.TimeoutException as e: -- self.assertEqual(e.full_cmd, '/bin/sleep 3') -+ self.assertEqual(e.full_cmd, '/usr/bin/sleep 3') - else: - self.fail("no timeout exception") - elapsed = time() - started diff --git a/fix-test_general_signal.diff b/fix-test_general_signal.diff deleted file mode 100644 index d02be6a..0000000 --- a/fix-test_general_signal.diff +++ /dev/null @@ -1,25 +0,0 @@ -Index: sh-1.13.1/test.py -=================================================================== ---- sh-1.13.1.orig/test.py -+++ sh-1.13.1/test.py -@@ -1449,10 +1449,9 @@ for i in range(5): - self.assertTrue("4" not in stdout) - - def test_general_signal(self): -- import signal - from signal import SIGINT - -- py = create_tmp_test(""" -+ py = create_tmp_test(r""" - import sys - import os - import time -@@ -1478,7 +1477,7 @@ for i in range(5): - process.signal(SIGINT) - return True - -- p = python(py.name, _out=agg, _tee=True) -+ p = python('-u', py.name, _out=agg, _tee=True) - p.wait() - - self.assertEqual(p.process.exit_code, 0) diff --git a/fix-test_signal_group.diff b/fix-test_signal_group.diff deleted file mode 100644 index bf2d2e1..0000000 --- a/fix-test_signal_group.diff +++ /dev/null @@ -1,20 +0,0 @@ -Index: sh-1.13.1/test.py -=================================================================== ---- sh-1.13.1.orig/test.py -+++ sh-1.13.1/test.py -@@ -1,4 +1,4 @@ --# -*- coding: utf8 -*- -+# -*- coding: utf-8 -*- - import sys - import os - -@@ -2174,7 +2174,8 @@ time.sleep(3) - """) - - parent = create_tmp_test(""" --import sys -+import os, sys -+sys.path.insert(0, os.getcwd()) - import sh - python = sh.Command(sys.executable) - p = python("{child_file}", _bg=True, _new_session=False) diff --git a/no-coverage.patch b/no-coverage.patch deleted file mode 100644 index c6e5f6d..0000000 --- a/no-coverage.patch +++ /dev/null @@ -1,66 +0,0 @@ -Index: sh-1.13.1/sh.py -=================================================================== ---- sh-1.13.1.orig/sh.py -+++ sh-1.13.1/sh.py -@@ -3785,14 +3785,9 @@ if __name__ == "__main__": # pragma: no - - if action in ("test", "travis", "tox"): - import test -- coverage = None -- if test.HAS_UNICODE_LITERAL: -- import coverage - - env = os.environ.copy() - env["SH_TESTS_RUNNING"] = "1" -- if coverage: -- test.append_module_path(env, coverage) - - # if we're testing locally, run all versions of python on the system - if action == "test": -Index: sh-1.13.1/test.py -=================================================================== ---- sh-1.13.1.orig/test.py -+++ sh-1.13.1/test.py -@@ -6,34 +6,6 @@ IS_PY3 = sys.version_info[0] == 3 - IS_PY2 = not IS_PY3 - MINOR_VER = sys.version_info[1] - --# coverage doesn't work in python 3.1, 3.2 due to it just being a shit --# python --HAS_UNICODE_LITERAL = not (IS_PY3 and MINOR_VER in (1, 2)) -- --cov = None --if HAS_UNICODE_LITERAL: -- run_idx = int(os.environ.pop("SH_TEST_RUN_IDX", "0")) -- first_run = run_idx == 0 -- -- try: -- import coverage -- except ImportError: -- pass -- else: -- # for some reason, we can't run auto_data on the first run, or the coverage -- # numbers get really screwed up -- auto_data = True -- if first_run: -- auto_data = False -- -- cov = coverage.Coverage(auto_data=auto_data) -- -- if first_run: -- cov.erase() -- -- cov.start() -- -- - from os.path import exists, join, realpath, dirname, split - import unittest - try: -@@ -3230,6 +3202,4 @@ if __name__ == "__main__": - exit(1) - - finally: -- if cov: -- cov.stop() -- cov.save() -+ pass diff --git a/python-sh.changes b/python-sh.changes index e5c3afb..9ed0a4a 100644 --- a/python-sh.changes +++ b/python-sh.changes @@ -1,3 +1,21 @@ +------------------------------------------------------------------- +Tue Dec 8 21:25:24 UTC 2020 - Benjamin Greiner + +- Update to 1.14.1: + * bugfix where setting _ok_code to not include 0, but 0 was the + exit code #545 +- Changes for 1.14.0 + * _env now more lenient in accepting dictionary-like objects #527 + * None and False arguments now do not pass through to underlying + command #525 + * Implemented find_spec on the fancy importer, which fixes some + Python3.4+ issues #536 +- Drop all patches: they are no longer applicable + * fix-sleep-path-in-test.patch + * fix-test_general_signal.diff + * fix-test_signal_group.diff + * no-coverage.patch + ------------------------------------------------------------------- Wed Jun 17 08:14:24 UTC 2020 - Steve Kowalik diff --git a/python-sh.spec b/python-sh.spec index 0246ebc..248b0e8 100644 --- a/python-sh.spec +++ b/python-sh.spec @@ -18,16 +18,12 @@ %{?!python_module:%define python_module() python-%{**} python3-%{**}} Name: python-sh -Version: 1.13.1 +Version: 1.14.1 Release: 0 Summary: Python subprocess interface License: MIT URL: https://github.com/amoffat/sh Source: https://files.pythonhosted.org/packages/source/s/sh/sh-%{version}.tar.gz -Patch0: no-coverage.patch -Patch1: fix-test_signal_group.diff -Patch2: fix-test_general_signal.diff -Patch3: fix-sleep-path-in-test.patch BuildRequires: %{python_module setuptools} BuildRequires: python-rpm-macros BuildArch: noarch @@ -45,7 +41,6 @@ sh is not a collection of system commands implemented in Python. %prep %setup -q -n sh-%{version} -%autopatch -p1 %build %python_build diff --git a/sh-1.13.1.tar.gz b/sh-1.13.1.tar.gz deleted file mode 100644 index 99f6e95..0000000 --- a/sh-1.13.1.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:97a3d2205e3c6a842d87ebbc9ae93acae5a352b1bc4609b428d0fd5bb9e286a3 -size 62768 diff --git a/sh-1.14.1.tar.gz b/sh-1.14.1.tar.gz new file mode 100644 index 0000000..046f51a --- /dev/null +++ b/sh-1.14.1.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:39aa9af22f6558a0c5d132881cf43e34828ca03e4ae11114852ca6a55c7c1d8e +size 63317