Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.maint.python > #14521
| Path | csiph.com!news.mixmin.net!aioe.org!news.servidellagleba.it!bofh.it!news.nic.it!robomod |
|---|---|
| From | Bo YU <tsu.yubo@gmail.com> |
| Newsgroups | linux.debian.maint.python |
| Subject | Re: how to fix TypeError: expected string or bytes-like object ? |
| Date | Thu, 06 Oct 2022 03:50:02 +0200 |
| Message-ID | <Fdobo-ckrL-1@gated-at.bofh.it> (permalink) |
| References | <Fd9cl-cbqD-1@gated-at.bofh.it> <Fda8p-cbZB-3@gated-at.bofh.it> <FdarL-cclL-5@gated-at.bofh.it> <FdaL8-ccsd-5@gated-at.bofh.it> |
| X-Mailbox-Line | From debian-python-request@lists.debian.org Thu Oct 6 01:43:53 2022 |
| Old-Return-Path | <tsu.yubo@gmail.com> |
| X-Amavis-Spam-Status | No, score=-10.699 tagged_above=-10000 required=5.3 tests=[BAYES_00=-2, BODY_8BITS=1.5, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, LDO_WHITELIST=-5, PGPSIGNATURE=-5, RCVD_IN_DNSWL_NONE=-0.0001] autolearn=ham autolearn_force=no |
| X-Policyd-Weight | using cached result; rate: -5.5 |
| X-Gm-Message-State | ACrzQf1ls8asA5BJKpFvWGXEqm5t4dHKCHQPBSf7VrH1DoIxtwyYMntC AESe2rjumZ44P4ZIvmB4VuAhYS0VAkA= |
| X-Google-SMTP-Source | AMsMyM6KWSM8QfIat4L6DnF/Y+I8kMggJriMLqNqM9G1dggK9LGxpNtG/vQ5vMqzDDLkxkskf6Bbkg== |
| X-Received | by 2002:a17:902:e414:b0:17f:5c82:ac01 with SMTP id m20-20020a170902e41400b0017f5c82ac01mr2165595ple.123.1665020614723; Wed, 05 Oct 2022 18:43:34 -0700 (PDT) |
| X-PGP-Key | https://github.com/yuzibo/yuzibo.github.io/blob/master/_includes/subkey-signing-06-18-143E4BAF-pub.asc |
| MIME-Version | 1.0 |
| Content-Type | multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="g5oalxxmscmrfqqh" |
| Content-Disposition | inline |
| X-Mailing-List | <debian-python@lists.debian.org> archive/latest/20370 |
| List-ID | <debian-python.lists.debian.org> |
| List-URL | <https://lists.debian.org/debian-python/> |
| List-Archive | https://lists.debian.org/msgid-search/20221006014330.v4qhktvrcdej3b7q@debian |
| Approved | robomod@news.nic.it |
| Lines | 94 |
| Organization | linux.* mail to news gateway |
| Sender | robomod@news.nic.it |
| X-Original-Cc | debian-python <debian-python@lists.debian.org> |
| X-Original-Date | Thu, 6 Oct 2022 09:43:30 +0800 |
| X-Original-Message-ID | <20221006014330.v4qhktvrcdej3b7q@debian> |
| X-Original-References | <CAKq8=3LoQ6uAV6kWNiVu49kAk3wrsHuzVMNJ2je2bS0twxKvWA@mail.gmail.com> <eec94ea5-7036-1019-48c4-e51d8a0c8b5b@archlinux.org> <20221005110221.5ctgsxgzp2vnk5ed@debian> <cbf87064-e35f-2872-cfd1-3707ab77603b@archlinux.org> |
| Xref | csiph.com linux.debian.maint.python:14521 |
Show key headers only | View raw
[Multipart message — attachments visible in raw view] - view raw
Hi,
On Wed, Oct 05, 2022 at 02:28:56PM +0300, Felix Yan wrote:
>On 10/5/22 14:02, Bo YU wrote:
>>```
>>vimer@dev:~/build/rfs/packages/test_dir$ sudo pip3 install
>>sphinxcontrib-ditaa
>>Collecting sphinxcontrib-ditaa
>> Using cached sphinxcontrib-ditaa-1.0.1.tar.gz (7.5 kB)
>> Preparing metadata (setup.py) ... error
>> error: subprocess-exited-with-error
>>
[...]
>> return self._name_from_stem(stem) or super()._normalized_name
>> File "/usr/lib/python3.10/importlib/metadata/__init__.py",
>>line 622, in _normalized_name
>> return Prepared.normalize(self.name)
>> File "/usr/lib/python3.10/importlib/metadata/__init__.py",
>>line 871, in normalize
>> return re.sub(r"[-_.]+", "-", name).lower().replace('-', '_')
>> File "/usr/lib/python3.10/re.py", line 209, in sub
>> return _compile(pattern, flags).sub(repl, string, count)
>> TypeError: expected string or bytes-like object
>> [end of output]
>>
>> note: This error originates from a subprocess, and is likely not
>>a problem with pip.
>>error: metadata-generation-failed
>>
>>× Encountered error while generating package metadata.
>>╰─> See above for output.
>>
>>```
>
>You are right. The traceback is indeed different but more similar to
>this one, probably: https://github.com/pypa/setuptools/issues/3273
>
>I have tried to make an empty .dist-info dir and got the very similar
>result to yours.
>
>The following command may help to locate the actual offending package:
>
>strace -eopenat python -c "from importlib.metadata import
>entry_points; print(entry_points(group='sphinx.builders'))"
>
Great! It works.
I deleted the package that was installed by setup.py with above command
hint. Everythng is well now.
Many thanks~
--
Regards,
--
Bo YU
Back to linux.debian.maint.python | Previous | Next — Previous in thread | Find similar | Unroll thread
how to fix TypeError: expected string or bytes-like object ? Bo YU <tsu.yubo@gmail.com> - 2022-10-05 11:50 +0200
Re: how to fix TypeError: expected string or bytes-like object ? Felix Yan <felixonmars@archlinux.org> - 2022-10-05 12:50 +0200
Re: how to fix TypeError: expected string or bytes-like object ? Bo YU <tsu.yubo@gmail.com> - 2022-10-05 13:10 +0200
Re: how to fix TypeError: expected string or bytes-like object ? Felix Yan <felixonmars@archlinux.org> - 2022-10-05 13:30 +0200
Re: how to fix TypeError: expected string or bytes-like object ? Bo YU <tsu.yubo@gmail.com> - 2022-10-06 03:50 +0200
csiph-web