Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
polybar python pkg_resources not found [solved]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
Banana
Veteran
Veteran


Joined: 21 May 2004
Posts: 1392
Location: Germany

PostPosted: Tue Dec 29, 2020 10:11 am    Post subject: polybar python pkg_resources not found [solved] Reply with quote

polybar-3.4.3 does not compile with the following error message:

Code:
...
ninja -v -j8 -l0
[1/84] : && /usr/bin/cmake -E rm -f lib/xpp/libxpp.a && /usr/bin/x86_64-pc-linux-gnu-ar qc lib/xpp/libxpp.a   && /usr/bin/x86_64-pc-linux-gnu-ranlib lib/xpp/libxpp.a && :
[2/84] cd /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3_build/doc && /usr/bin/sphinx-build -b html -c /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3_build/doc -d /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3_build/doc/doctrees /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3/doc /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3_build/doc/html > builder-html.log
FAILED: doc/CMakeFiles/doc_html
cd /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3_build/doc && /usr/bin/sphinx-build -b html -c /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3_build/doc -d /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3_build/doc/doctrees /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3/doc /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3_build/doc/html > builder-html.log
Traceback (most recent call last):
  File "/usr/lib/python-exec/python3.7/sphinx-build", line 6, in <module>
    from pkg_resources import load_entry_point
ModuleNotFoundError: No module named 'pkg_resources'
[3/84] cd /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3_build/doc && /usr/bin/sphinx-build -b man -c /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3_build/doc -d /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3_build/doc/doctrees /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3/doc /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3_build/doc/man > builder-man.log
FAILED: doc/CMakeFiles/doc_man
cd /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3_build/doc && /usr/bin/sphinx-build -b man -c /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3_build/doc -d /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3_build/doc/doctrees /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3/doc /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3_build/doc/man > builder-man.log
Traceback (most recent call last):
  File "/usr/lib/python-exec/python3.7/sphinx-build", line 6, in <module>
    from pkg_resources import load_entry_point
ModuleNotFoundError: No module named 'pkg_resources'
[4/84] cd /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3_build/lib/xpp && /var/tmp/portage/x11-misc/polybar-3.4.3/temp/python3.8/bin/python /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3/lib/xpp/generators/cpp_client.py -p /usr/lib/python3.8/site-packages //usr/share/xcb/composite.xml > /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3/lib/xpp/include/xpp/proto/composite.hpp
[5/84] cd /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3_build/lib/xpp && /var/tmp/portage/x11-misc/polybar-3.4.3/temp/python3.8/bin/python /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3/lib/xpp/generators/cpp_client.py -p /usr/lib/python3.8/site-packages //usr/share/xcb/xkb.xml > /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3/lib/xpp/include/xpp/proto/xkb.hpp
[6/84] cd /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3_build/lib/xpp && /var/tmp/portage/x11-misc/polybar-3.4.3/temp/python3.8/bin/python /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3/lib/xpp/generators/cpp_client.py -p /usr/lib/python3.8/site-packages //usr/share/xcb/randr.xml > /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3/lib/xpp/include/xpp/proto/randr.hpp
list: size, ['red', 'green', 'blue']
list: size, ['red', 'green', 'blue']
[7/84] /usr/bin/x86_64-pc-linux-gnu-g++  -I/var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3/lib/i3ipcpp/3rd/auss/include -I/var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3/lib/i3ipcpp/include -I/usr/include/jsoncpp  -O2 -pipe -march=native -Wall -Wextra -Wpedantic   -std=c++11 -Wall -Wextra -Wno-unused-parameter -Wno-deprecated-declarations -std=c++14 -MD -MT lib/i3ipcpp/CMakeFiles/i3ipc++.dir/src/ipc-util.cpp.o -MF lib/i3ipcpp/CMakeFiles/i3ipc++.dir/src/ipc-util.cpp.o.d -o lib/i3ipcpp/CMakeFiles/i3ipc++.dir/src/ipc-util.cpp.o -c /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3/lib/i3ipcpp/src/ipc-util.cpp
[8/84] /usr/bin/x86_64-pc-linux-gnu-g++  -I/var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3/lib/i3ipcpp/3rd/auss/include -I/var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3/lib/i3ipcpp/include -I/usr/include/jsoncpp  -O2 -pipe -march=native -Wall -Wextra -Wpedantic   -std=c++11 -Wall -Wextra -Wno-unused-parameter -Wno-deprecated-declarations -std=c++14 -MD -MT lib/i3ipcpp/CMakeFiles/i3ipc++.dir/src/ipc.cpp.o -MF lib/i3ipcpp/CMakeFiles/i3ipc++.dir/src/ipc.cpp.o.d -o lib/i3ipcpp/CMakeFiles/i3ipc++.dir/src/ipc.cpp.o -c /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3/lib/i3ipcpp/src/ipc.cpp
[9/84] cd /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3_build/lib/xpp && /var/tmp/portage/x11-misc/polybar-3.4.3/temp/python3.8/bin/python /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3/lib/xpp/generators/cpp_client.py -p /usr/lib/python3.8/site-packages //usr/share/xcb/xproto.xml > /var/tmp/portage/x11-misc/polybar-3.4.3/work/polybar-3.4.3/lib/xpp/include/xpp/proto/x.hpp
ninja: build stopped: subcommand failed.
...


It does not find a python 3.7 package even that the default interpreter is set to 3.8. Re-emerge of dev-python/setuptools did not help.

Emerge log of emerge x11-misc/polybar https://delta-labs.org/sp/Bu4
Emerge info: https://delta-labs.org/sp/F2U

available python interpreters eselect python list
Code:
Available Python interpreters, in order of preference:
  [1]   python3.8
  [2]   python3.7
  [3]   python3.6 (uninstalled)
  [4]   python3.9 (fallback)
  [5]   python2.7 (fallback)

_________________
My personal space
My delta-labs.org snippets do expire

PFL - Portage file list - find which package a file or command belongs to.


Last edited by Banana on Tue Dec 29, 2020 12:32 pm; edited 1 time in total
Back to top
View user's profile Send private message
fedeliallalinea
Administrator
Administrator


Joined: 08 Mar 2003
Posts: 30915
Location: here

PostPosted: Tue Dec 29, 2020 10:28 am    Post subject: Reply with quote

You can post emerge -pv dev-python/sphinx output?
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
Banana
Veteran
Veteran


Joined: 21 May 2004
Posts: 1392
Location: Germany

PostPosted: Tue Dec 29, 2020 12:27 pm    Post subject: Reply with quote

Code:
Calculating dependencies... done!
[ebuild   R    ] dev-python/namespace-sphinxcontrib-1.0::gentoo  PYTHON_TARGETS="python3_8* (-pypy3) -python3_6 -python3_7* -python3_9" 0 KiB
[ebuild     U  ] dev-python/pygments-2.7.2::gentoo [2.7.0::gentoo] USE="-doc -test" PYTHON_TARGETS="python3_8* (-pypy3) -python3_6 -python3_7* -python3_9" 2,296 KiB
[ebuild   R    ] dev-python/alabaster-0.7.12::gentoo  PYTHON_TARGETS="python3_8* (-pypy3) -python3_6 -python3_7* -python3_9" 0 KiB
[ebuild     U  ] dev-python/imagesize-1.2.0::gentoo [1.1.0::gentoo] USE="-test" PYTHON_TARGETS="python3_8* (-pypy3) -python3_6 -python3_7* -python3_9" 1,246 KiB
[ebuild   R    ] dev-python/snowballstemmer-2.0.0::gentoo  PYTHON_TARGETS="python3_8* (-pypy3) -python3_6 -python3_7* -python3_9" 0 KiB
[ebuild   R    ] dev-python/pyparsing-2.4.7-r1::gentoo  USE="-examples" PYTHON_TARGETS="python3_8* (-pypy3) -python3_6 -python3_7* -python3_9" 0 KiB
[ebuild     U  ] dev-python/pytz-2020.4::gentoo [2020.1-r1::gentoo] PYTHON_TARGETS="python3_8* (-pypy3) -python3_6 -python3_7* -python3_9" 304 KiB
[ebuild     U  ] dev-python/Babel-2.8.1::gentoo [2.8.0-r2::gentoo] USE="-doc -test" PYTHON_TARGETS="python3_8* (-pypy3) -python3_6 -python3_7* -python3_9" 8,273 KiB
[ebuild   R    ] dev-python/docutils-0.16-r1::gentoo  PYTHON_TARGETS="python3_8* (-pypy3) -python3_6 -python3_7* -python3_9" 0 KiB
[ebuild   R    ] dev-python/packaging-20.4-r1::gentoo  USE="-test" PYTHON_TARGETS="python3_8* (-pypy3) -python3_6 -python3_7* -python3_9" 0 KiB
[ebuild   R    ] dev-python/sphinxcontrib-applehelp-1.0.2::gentoo  USE="-test" PYTHON_TARGETS="python3_8* (-pypy3) -python3_6 -python3_7* -python3_9" 0 KiB
[ebuild   R    ] dev-python/sphinxcontrib-devhelp-1.0.2::gentoo  USE="-test" PYTHON_TARGETS="python3_8* (-pypy3) -python3_6 -python3_7* -python3_9" 0 KiB
[ebuild   R    ] dev-python/sphinxcontrib-jsmath-1.0.1-r1::gentoo  USE="-test" PYTHON_TARGETS="python3_8* (-pypy3) -python3_6 -python3_7* -python3_9" 0 KiB
[ebuild   R    ] dev-python/sphinxcontrib-htmlhelp-1.0.3::gentoo  USE="-test" PYTHON_TARGETS="python3_8* (-pypy3) -python3_6 -python3_7* -python3_9" 0 KiB
[ebuild   R    ] dev-python/sphinxcontrib-serializinghtml-1.1.4::gentoo  USE="-test" PYTHON_TARGETS="python3_8* (-pypy3) -python3_6 -python3_7* -python3_9" 0 KiB
[ebuild   R    ] dev-python/sphinxcontrib-qthelp-1.0.3::gentoo  USE="-test" PYTHON_TARGETS="python3_8* (-pypy3) -python3_6 -python3_7* -python3_9" 0 KiB
[ebuild   R    ] dev-python/sphinx-3.2.1::gentoo  USE="-doc -latex -test" PYTHON_TARGETS="python3_8* (-pypy3) -python3_6 -python3_7* -python3_9" 0 KiB


Running this now...

But why did a emerge -uDNpv @world not show these?
For sphinx only PYTHON_TARGETS changed and thus needs the other dependencies. Can I find those packages which have a changed PYTHON_TARGETS or is this overkill?

EDIT:
The re-emerge of sphinx did the trick. Thank you!
_________________
My personal space
My delta-labs.org snippets do expire

PFL - Portage file list - find which package a file or command belongs to.


Last edited by Banana on Tue Dec 29, 2020 12:32 pm; edited 1 time in total
Back to top
View user's profile Send private message
fedeliallalinea
Administrator
Administrator


Joined: 08 Mar 2003
Posts: 30915
Location: here

PostPosted: Tue Dec 29, 2020 12:31 pm    Post subject: Reply with quote

You can run emerge -UD @world for rebuild all package that have a change in use flag.
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
Banana
Veteran
Veteran


Joined: 21 May 2004
Posts: 1392
Location: Germany

PostPosted: Tue Dec 29, 2020 12:34 pm    Post subject: Reply with quote

nope, does not show anything. I suspect that the PYTHON_TARGETS is not handled the same way as the USE flag.
BTW, I do not have manually set PYTHON_TARGETS
Back to top
View user's profile Send private message
fedeliallalinea
Administrator
Administrator


Joined: 08 Mar 2003
Posts: 30915
Location: here

PostPosted: Tue Dec 29, 2020 1:05 pm    Post subject: Reply with quote

It's a use expand and is handled as normal use flag.
Quote:
USE_EXPAND and ARCH USE Flags

The VIDEO_CARDS, INPUT_DEVICES and L10N variables are automatically expanded into USE flags. These are known as USE_EXPAND variables. If the user has L10N="en fr" in make.conf, for example, then USE="l10n_en l10n_fr" will automatically be set by Portage.

And emerge -uUD @world what return?
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
Banana
Veteran
Veteran


Joined: 21 May 2004
Posts: 1392
Location: Germany

PostPosted: Tue Dec 29, 2020 1:23 pm    Post subject: Reply with quote

same. nothing
Code:
mirage ~ # emerge -uUD @world
Calculating dependencies... done!
>>> Auto-cleaning packages...

>>> No outdated packages were found on your system.


Doesn't my emerge -uDNpv @world cover this?
_________________
My personal space
My delta-labs.org snippets do expire

PFL - Portage file list - find which package a file or command belongs to.
Back to top
View user's profile Send private message
fedeliallalinea
Administrator
Administrator


Joined: 08 Mar 2003
Posts: 30915
Location: here

PostPosted: Tue Dec 29, 2020 1:33 pm    Post subject: Reply with quote

I see now that you have rebuild sphinx and your dependencies, maybe now there is nothing to update/rebuild.
You can check with eix
Code:
$ eix --installed-with-use python_targets_python3_7
$ eix --installed-with-use python_single_target_python3_7

_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
Banana
Veteran
Veteran


Joined: 21 May 2004
Posts: 1392
Location: Germany

PostPosted: Tue Dec 29, 2020 4:20 pm    Post subject: Reply with quote

Code:
mirage ~ # eix --installed-with-use python_targets_python3_7
[I] dev-lang/python-exec
     Available versions:  (2) 2.4.6-r2 ~2.4.6-r3
       {+native-symlinks PYTHON_TARGETS="pypy3 python2_7 python3_6 python3_7 python3_8 python3_9"}
     Installed versions:  2.4.6-r2(2)(09:34:17 AM 10/19/2020)(PYTHON_TARGETS="pypy3 python2_7 python3_6 python3_7 python3_8 python3_9")
     Homepage:            https://github.com/mgorny/python-exec/
     Description:         Python script wrapper

[I] dev-libs/libnl
     Available versions: 
     (1.1)  1.1.4 ~1.1.4-r1 **1.1.9999*l
     (3)    3.5.0 **99999999*l
       {+debug doc python static-libs +threads utils ABI_MIPS="n32 n64 o32" ABI_S390="32 64" ABI_X86="32 64 x32" PYTHON_TARGETS="python3_6 python3_7 python3_8"}
     Installed versions:  3.5.0(3)(12:57:52 PM 09/27/2020)(debug threads -python -static-libs -utils ABI_MIPS="-n32 -n64 -o32" ABI_S390="-32 -64" ABI_X86="64 -32 -x32" PYTHON_TARGETS="python3_7 -python3_6 -python3_8")
     Homepage:            http://www.infradead.org/~tgr/libnl/ https://github.com/thom311/libnl
     Description:         Libraries providing APIs to netlink protocol based Linux kernel interfaces

[I] dev-python/pyudev
     Available versions:  0.22.0^t {qt5 test PYTHON_TARGETS="python3_6 python3_7 python3_8 python3_9"}
     Installed versions:  0.22.0^t(04:19:58 PM 11/29/2020)(-qt5 -test PYTHON_TARGETS="python3_7 -python3_6 -python3_8 -python3_9")
     Homepage:            https://pyudev.readthedocs.io/en/latest/ https://github.com/pyudev/pyudev
     Description:         Python binding to libudev

[I] dev-python/typed-ast
     Available versions:  1.4.1^t {test PYTHON_TARGETS="python3_6 python3_7 python3_8 python3_9"}
     Installed versions:  1.4.1^t(04:27:09 PM 07/25/2020)(-test PYTHON_TARGETS="python3_7 -python3_6 -python3_8 -python3_9")
     Homepage:            https://pypi.org/project/typed-ast/ https://github.com/python/typed_ast
     Description:         Python typed-ast backported

[I] sys-libs/cracklib
     Available versions:  2.9.6-r2 2.9.7 {nls python split-usr static-libs zlib ABI_MIPS="n32 n64 o32" ABI_S390="32 64" ABI_X86="32 64 x32" PYTHON_TARGETS="python3_6 python3_7 python3_8"}
     Installed versions:  2.9.7(03:48:42 PM 05/10/2020)(nls split-usr zlib -python -static-libs ABI_MIPS="-n32 -n64 -o32" ABI_RISCV="-lp64 -lp64d" ABI_S390="-32 -64" ABI_X86="64 -32 -x32" PYTHON_TARGETS="python3_7 -python3_6 -python3_8")
     Homepage:            https://github.com/cracklib/cracklib/
     Description:         Password Checking Library

Found 5 matches


and and example emerge shows this:
Code:
emerge dev-python/pyudev -pv

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild   R    ] dev-python/pyudev-0.22.0::gentoo  USE="-qt5 -test" PYTHON_TARGETS="python3_8* -python3_6 -python3_7* -python3_9" 0 KiB


so it looks like that the change if the PYTHON_TARGETS flag is not picket up for every package. I remember some rebuilds after python3_8 was set to default. (but could be wrong...)
Maybe it only works if the package is in the world file?
_________________
My personal space
My delta-labs.org snippets do expire

PFL - Portage file list - find which package a file or command belongs to.
Back to top
View user's profile Send private message
fedeliallalinea
Administrator
Administrator


Joined: 08 Mar 2003
Posts: 30915
Location: here

PostPosted: Tue Dec 29, 2020 4:32 pm    Post subject: Reply with quote

Banana wrote:
Maybe it only works if the package is in the world file?

I'm pretty sure this is false.
These packages are required by someone?
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
Banana
Veteran
Veteran


Joined: 21 May 2004
Posts: 1392
Location: Germany

PostPosted: Wed Dec 30, 2020 8:43 am    Post subject: Reply with quote

well, python-exec and sphinx do have installed dependencies but not the other ones. Gonna run a deepclean.

Anyway, learned something and the problem is gone. Thank you for your time and help
_________________
My personal space
My delta-labs.org snippets do expire

PFL - Portage file list - find which package a file or command belongs to.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum