Bug 273532 - textproc/py-sphinxcontrib-autoprogram fails to build with extension error (exception: No module named 'six') using poudriere 13.2-stable on amd64
Summary: textproc/py-sphinxcontrib-autoprogram fails to build with extension error (e...
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Robert Clausecker
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-09-02 19:38 UTC by Robert Cina
Modified: 2023-09-10 16:45 UTC (History)
3 users (show)

See Also:
dereks: maintainer-feedback+


Attachments
Add missing docs build depends py-six (1.10 KB, patch)
2023-09-03 02:27 UTC, Derek Schrock
dereks: maintainer-approval+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Robert Cina 2023-09-02 19:38:42 UTC
The port textproc/py-sphinxcontrib-autoprogram fails to build under poudriere on my 13.2-stable amd64 system. 

It could not import extension sphinxcontrib.autoprogram (exception: No module named 'six').

Below is the relevant excerpt of the build log:

===>  Configuring for py39-sphinxcontrib-autoprogram-0.1.8
/usr/local/lib/python3.9/site-packages/setuptools/dist.py:286: SetuptoolsDeprecationWarning: The namespace_packages parameter is deprecated, consider using implicit namespaces instead (PEP 420).
  warnings.warn(msg, SetuptoolsDeprecationWarning)
running config
===========================================================================
=======================<phase: build          >============================
===== env: NO_DEPENDS=yes USER=root UID=0 GID=0
===>  Building for py39-sphinxcontrib-autoprogram-0.1.8
/usr/local/lib/python3.9/site-packages/setuptools/dist.py:286: SetuptoolsDeprecationWarning: The namespace_packages parameter is deprecated, consider using implicit namespaces instead (PEP 420).
  warnings.warn(msg, SetuptoolsDeprecationWarning)
running build_sphinx
Running Sphinx v5.3.0

Extension error:
Could not import extension sphinxcontrib.autoprogram (exception: No module named 'six')
*** Error code 1

Stop.
make: stopped in /usr/ports/textproc/py-sphinxcontrib-autoprogram
=>> Cleaning up wrkdir
===>  Cleaning for py39-sphinxcontrib-autoprogram-0.1.8
build of textproc/py-sphinxcontrib-autoprogram@py39 | py39-sphinxcontrib-autoprogram-0.1.8 ended at Sat Sep  2 14:52:56 EDT 2023
build time: 00:00:07
!!! build failure encountered !!!
Comment 1 Derek Schrock 2023-09-03 02:27:46 UTC
Created attachment 244604 [details]
Add missing docs build depends py-six

Add missing build depends py-six that was previously brought in by another port.

portlint: ok. looks fine.
testport: ok. 13amd64.
unittest: ok. Ran 7 tests in 0.006s

With DOCS option both py-sphinx and py-six installed and without neither are installed during build.
Comment 2 Dan Langille freebsd_committer freebsd_triage 2023-09-07 13:41:22 UTC
This fixed it for me:

$ git diff
diff --git a/textproc/py-sphinxcontrib-autoprogram/Makefile b/textproc/py-sphinxcontrib-autoprogram/Makefile
index 80dbd375ddcc..dd7513eed277 100644
--- a/textproc/py-sphinxcontrib-autoprogram/Makefile
+++ b/textproc/py-sphinxcontrib-autoprogram/Makefile
@@ -10,6 +10,8 @@ WWW=          https://github.com/sphinx-contrib/autoprogram
 
 LICENSE=       BSD2CLAUSE
 
+BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}six>0:devel/py-six@${PY_FLAVOR}
+
 RUN_DEPENDS=   ${PYTHON_PKGNAMEPREFIX}six>0:devel/py-six@${PY_FLAVOR} \
                ${PYTHON_PKGNAMEPREFIX}sphinx>=1.2,1:textproc/py-sphinx@${PY_FLAVOR}
 
$
Comment 3 Derek Schrock 2023-09-07 22:19:12 UTC
(In reply to Dan Langille from comment #2)
This is what the attached patch does but is only needed if the DOCS option is enabled.
Comment 4 commit-hook freebsd_committer freebsd_triage 2023-09-10 16:14:49 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=f16165e7a3c90778496c7f1f641584ac57b43005

commit f16165e7a3c90778496c7f1f641584ac57b43005
Author:     Derek Schrock <dereks@lifeofadishwasher.com>
AuthorDate: 2023-09-03 02:18:17 +0000
Commit:     Robert Clausecker <fuz@FreeBSD.org>
CommitDate: 2023-09-10 16:13:03 +0000

    textproc/py-sphinxcontrib-autoprogram: Add py-six DOCS_BUILD_DEPENDS

    Add missing build depends py-six that was previously brought in by
    another port.

    Reported by:    transitive@gmail.com
    PR:             273532

 textproc/py-sphinxcontrib-autoprogram/Makefile | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
Comment 5 Robert Clausecker freebsd_committer freebsd_triage 2023-09-10 16:45:59 UTC
Thank you for your contribution.