Closed andischan closed 7 years ago
What does
$ sh -c 'shopt -s nocaseglob; ls /usr/lib/python3.6/site-packages/habanero-*-info; pacman -Qo /usr/lib/python3.6/site-packages/habanero-*-info'
give you?
@andischan This looks easy enough to fix, but I'd like to know why you are hitting this issue, so please address my question above.
This error comes from wrong/outdated/language depended parsing of pacman -Qo. With german language cut -d' ' -f2,3 is the correct command. Since I'm not sure if this depend on language or any thing else I didn't created a pull request.
_run_shell(
"(shopt -s nocaseglob; pacman -Qo {}/{}-*-info 2>/dev/null) "
"| rev | cut -d' ' -f1,2 | rev".format(
_get_site_packages_location(),
to_wheel_name(pypi_normed_name)),
stdout=PIPE).stdout[:-1].split()
Can you confirm that
diff --git a/pypi2pkgbuild.py b/pypi2pkgbuild.py
index 8291935..0ea3e07 100755
--- a/pypi2pkgbuild.py
+++ b/pypi2pkgbuild.py
@@ -251,6 +251,7 @@ def _run_shell(args, **kwargs):
"""
kwargs = {"shell": isinstance(args, str),
"env": {**os.environ,
+ "LC_ALL": "C", # So that text outputs can be parsed.
"PYTHONNOUSERSITE": "1",
"PIP_CONFIG_FILE": "/dev/null"},
"check": True,
(i.e. forcing the locale for subprocesses) fixes the issue?
Committed the fix. Feel free to request a reopen if it still doesn't work.
Now I meet the same issue, tried to export LANG=C
but didn't work, original LANG
is zh_CN.UTF-8
.
I'm trying to make gdbgui's PKGBUILD file.
I use the version from git: python pypi2pkgbuild.py habanero