You are not logged in.
I'm trying to create an AUR package.
Here:
# Maintainer: kryptxy <kryptxy@protonmail.com>
pkgname=torrench
pkgver=1.0.1.20160806
pkgrel=1
pkgdesc="Command-line torrent search tool"
arch=('any')
url="https://github.com/kryptxy/torrench"
license=('GPL')
depends=("python" "python-beautifulsoup4" "python-lxml" "python-requests" "python-termcolor" "python-tabulate")
makedepends=("python-setuptools")
provides=("torrench")
conflicts=("torrench")
source=('git+https://github.com/kryptxy/torrench.git')
md5sums=('SKIP')
build() {
cd "$pkgname"
python setup.py build
}
package() {
cd "$srcdir/$pkgname"
python setup.py install --prefix=/usr --root="${pkgdir}" --optimize=1
}
The package builds and installs successfully. But when I try to run it, I get following error:
$ torrench "ubuntu"
Traceback (most recent call last):
File "/usr/bin/torrench", line 6, in <module>
from pkg_resources import load_entry_point
File "/usr/lib/python3.6/site-packages/pkg_resources/__init__.py", line 3049, in <module>
@_call_aside
File "/usr/lib/python3.6/site-packages/pkg_resources/__init__.py", line 3033, in _call_aside
f(*args, **kwargs)
File "/usr/lib/python3.6/site-packages/pkg_resources/__init__.py", line 3062, in _initialize_master_working_set
working_set = WorkingSet._build_master()
File "/usr/lib/python3.6/site-packages/pkg_resources/__init__.py", line 658, in _build_master
ws.require(__requires__)
File "/usr/lib/python3.6/site-packages/pkg_resources/__init__.py", line 972, in require
needed = self.resolve(parse_requirements(requirements))
File "/usr/lib/python3.6/site-packages/pkg_resources/__init__.py", line 858, in resolve
raise DistributionNotFound(req, requirers)
pkg_resources.DistributionNotFound: The 'bs4' distribution was not found and is required by torrench
I checked, bs4 is installed in the system. But I'm still getting this error. [I am able to import bs4 from python interactive shell]
Project link: https://github.com/kryptxy/torrench
Help please.
Last edited by kryptxy (2017-08-06 20:28:21)
Offline
That's not the name of the python package. It's called beautifulsoup4, and that is what setuptools will look for when it attempts to check runtime dependencies.
The import path (bs4) is completely irrelevant.
I'm guessing there is a bad install_requires in that setup.py
Managing AUR repos The Right Way -- aurpublish (now a standalone tool)
Offline
That was the issue. Changing bs4 to beautifulsoup4 fixed it Thanks.
Offline
Please remember to mark your thread as [Solved] by editing your first post and prepending it to the title.
Offline
Please remember to mark your thread as [Solved] by editing your first post and prepending it to the title.
Unable to prepend - Title box reaches its max word length
Offline
You've hit the max field length, you need to delete a few characters. I'd suggest...
[SOLVED] pkg_resources.DistributionNotFound error
Offline