<pre style='margin:0'>
Renee Otten (reneeotten) pushed a commit to branch master
in repository macports-ports.
</pre>
<p><a href="https://github.com/macports/macports-ports/commit/1d9e999f4fa18925bd3da42ebf423cec4c6e8ca1">https://github.com/macports/macports-ports/commit/1d9e999f4fa18925bd3da42ebf423cec4c6e8ca1</a></p>
<pre style="white-space: pre; background: #F8F8F8"><span style='display:block; white-space:pre;color:#808000;'>commit 1d9e999f4fa18925bd3da42ebf423cec4c6e8ca1
</span>Author: Renee Otten <reneeotten@macports.org>
AuthorDate: Wed Feb 12 08:30:23 2020 -0500
<span style='display:block; white-space:pre;color:#404040;'> py-sphinxcontrib-versioning: fix dependencies / tests
</span>---
python/py-sphinxcontrib-versioning/Portfile | 29 ++++++++++++++--------
.../patch-sphinxcontrib_versioning_sphinx_.py.diff | 19 ++++++++++++++
.../files/patch-tests_conftest.py.diff | 27 ++++++++++++++++++++
.../patch-tests_test_main_push_scenarios.py.diff | 23 +++++++++++++++++
4 files changed, 88 insertions(+), 10 deletions(-)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/python/py-sphinxcontrib-versioning/Portfile b/python/py-sphinxcontrib-versioning/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index 84d6421..675533f 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/python/py-sphinxcontrib-versioning/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/python/py-sphinxcontrib-versioning/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -5,17 +5,16 @@ PortGroup github 1.0
</span> PortGroup python 1.0
github.setup sphinx-contrib sphinxcontrib-versioning 2.2.1 v
<span style='display:block; white-space:pre;background:#ffe0e0;'>-revision 0
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+revision 1
</span> name py-${github.project}
<span style='display:block; white-space:pre;background:#ffe0e0;'>-categories-append devel
</span>
<span style='display:block; white-space:pre;background:#e0ffe0;'>+categories-append devel
</span> license MIT
maintainers nomaintainer
platforms darwin
<span style='display:block; white-space:pre;background:#ffe0e0;'>-description Sphinx extension that allows building versioned\
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+description Sphinx extension that allows building versioned \
</span> docs for self-hosting.
<span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span> long_description ${description}
checksums rmd160 d8968af5f62fa35381c48979642092aefc248403 \
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -24,13 +23,27 @@ checksums rmd160 d8968af5f62fa35381c48979642092aefc248403 \
</span>
python.versions 37 38
<span style='display:block; white-space:pre;background:#e0ffe0;'>+# fix for newer versions of Sphinx and pytest
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+patchfiles patch-sphinxcontrib_versioning_sphinx_.py.diff \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ patch-tests_conftest.py.diff \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ patch-tests_test_main_push_scenarios.py.diff
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span> if {${name} ne ${subport}} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- depends_build-append \
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- port:py${python.version}-setuptools
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ depends_lib-append \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ port:py${python.version}-click \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ port:py${python.version}-colorclass \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ port:py${python.version}-setuptools \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ port:py${python.version}-sphinx
</span>
depends_test-append \
port:py${python.version}-pytest
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ # FIXME: even with the current upstream patches applied, the tests do not pass.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ test.run yes
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ test.cmd pytest-${python.branch}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ test.target
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ test.env PYTHONPATH=${worksrcpath}/build/lib
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span> post-destroot {
set docdir ${prefix}/share/doc/${subport}
xinstall -d ${destroot}${docdir}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -38,9 +51,5 @@ if {${name} ne ${subport}} {
</span> ${destroot}${docdir}
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- test.run yes
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- test.cmd pytest-${python.branch}
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- test.target tests
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span> livecheck.type none
}
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/python/py-sphinxcontrib-versioning/files/patch-sphinxcontrib_versioning_sphinx_.py.diff b/python/py-sphinxcontrib-versioning/files/patch-sphinxcontrib_versioning_sphinx_.py.diff
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..7b17d34
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/python/py-sphinxcontrib-versioning/files/patch-sphinxcontrib_versioning_sphinx_.py.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,19 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# see PR 78
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# https://github.com/sphinx-contrib/sphinxcontrib-versioning/pull/78/commits/d6d0260e42223889aa1b14c742a3958279848a2d
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- sphinxcontrib/versioning/sphinx_.py.orig 2020-02-12 09:14:28.000000000 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ sphinxcontrib/versioning/sphinx_.py 2020-02-12 09:15:04.000000000 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -6,7 +6,12 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ import os
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ import sys
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+-from sphinx import application, build_main, locale
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++from sphinx import application, locale
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++try:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ from sphinx import build_main
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++except ImportError:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ # Sphinx 1.7+ ImportError fix
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ from sphinx.cmd.build import build_main
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ from sphinx.builders.html import StandaloneHTMLBuilder
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ from sphinx.config import Config as SphinxConfig
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ from sphinx.errors import SphinxError
</span><span style='display:block; white-space:pre;color:#808080;'>diff --git a/python/py-sphinxcontrib-versioning/files/patch-tests_conftest.py.diff b/python/py-sphinxcontrib-versioning/files/patch-tests_conftest.py.diff
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..057b273
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/python/py-sphinxcontrib-versioning/files/patch-tests_conftest.py.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,27 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# see upstream commit:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# https://github.com/sphinx-contrib/sphinxcontrib-versioning/commit/91e97376559bb25199120ea1ece93e1b67e843aa
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- tests/conftest.py.orig 2020-02-12 09:24:59.000000000 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ tests/conftest.py 2020-02-12 09:26:17.000000000 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -45,17 +45,15 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ return run_command(str(directory), [str(i) for i in command], *args, **kwargs)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+-def pytest_namespace():
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++def pytest_configure():
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ """Add objects to the pytest namespace. Can be retrieved by importing pytest and accessing pytest.<name>.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ :return: Namespace dict.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ :rtype: dict
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ """
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- return dict(
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- author_committer_dates=author_committer_dates,
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- ROOT_TS=ROOT_TS,
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- run=run,
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- )
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ pytest.author_committer_dates = author_committer_dates
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ pytest.ROOT_TS = ROOT_TS
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ pytest.run = run
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ @pytest.fixture
</span><span style='display:block; white-space:pre;color:#808080;'>diff --git a/python/py-sphinxcontrib-versioning/files/patch-tests_test_main_push_scenarios.py.diff b/python/py-sphinxcontrib-versioning/files/patch-tests_test_main_push_scenarios.py.diff
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..06c0d40
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/python/py-sphinxcontrib-versioning/files/patch-tests_test_main_push_scenarios.py.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,23 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# see upstream commit:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# https://github.com/sphinx-contrib/sphinxcontrib-versioning/commit/cf18bd40f3e6547a718670b8126796a6042746b7
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- tests/test__main__/test_main_push_scenarios.py.orig 2020-02-12 09:31:10.000000000 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ tests/test__main__/test_main_push_scenarios.py 2020-02-12 09:30:38.000000000 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -235,7 +235,7 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if remove:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ with pytest.raises(CalledProcessError) as exc:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ pytest.run(local_docs_ghp, ['git', 'checkout', 'origin/gh-pages'])
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- assert "origin/gh-pages' did not match any file(s) known to git." in exc.value.output
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ assert "origin/gh-pages' did not match any file(s) known to git" in exc.value.output
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ else:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ pytest.run(local_docs_ghp, ['git', 'checkout', 'origin/gh-pages'])
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ pytest.run(local_docs_ghp, ['git', 'pull', 'origin', 'gh-pages'])
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -261,7 +261,7 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if remove:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ with pytest.raises(CalledProcessError) as exc:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ pytest.run(local_docs_ghp, ['git', 'checkout', 'origin/gh-pages'])
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- assert "origin/gh-pages' did not match any file(s) known to git." in exc.value.output
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ assert "origin/gh-pages' did not match any file(s) known to git" in exc.value.output
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ else:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ pytest.run(local_docs_ghp, ['git', 'checkout', 'origin/gh-pages'])
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ pytest.run(local_docs_ghp, ['git', 'pull', 'origin', 'gh-pages'])
</span></pre><pre style='margin:0'>
</pre>