Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.maint.python > #16319
| Path | csiph.com!news.samoylyk.net!gothmog.csi.it!bofh.it!news.nic.it!robomod |
|---|---|
| From | Simon McVittie <smcv@debian.org> |
| Newsgroups | linux.debian.bugs.dist, linux.debian.maint.python |
| Subject | Bug#1083471: Migrating away from pkg_resources is difficult for namespace packages |
| Date | Fri, 04 Oct 2024 15:40:01 +0200 |
| Message-ID | <JtQxz-gSyl-1@gated-at.bofh.it> (permalink) |
| References | <JtQxz-gSyl-3@gated-at.bofh.it> <JtNJn-gQQx-13@gated-at.bofh.it> <JtQHf-gSBf-3@gated-at.bofh.it> <JtNJn-gQQx-13@gated-at.bofh.it> |
| X-Mailbox-Line | From debian-bugs-dist-request@lists.debian.org Fri Oct 4 13:30:08 2024 |
| Old-Return-Path | <debbugs@buxtehude.debian.org> |
| X-Spam-Flag | NO |
| X-Spam-Score | -1.699 |
| Reply-To | Simon McVittie <smcv@debian.org>, 1083471@bugs.debian.org |
| Resent-To | debian-bugs-dist@lists.debian.org |
| Resent-Cc | Debian GNOME Maintainers <pkg-gnome-maintainers@lists.alioth.debian.org> |
| X-Debian-Pr-Message | followup 1083471 |
| X-Debian-Pr-Package | src:mallard-ducktype |
| X-Debian-Pr-Keywords | sid trixie |
| X-Debian-Pr-Source | mallard-ducktype |
| MIME-Version | 1.0 |
| Content-Type | text/plain; charset=utf-8 |
| Content-Disposition | inline |
| Content-Transfer-Encoding | 8bit |
| X-Debian-User | smcv |
| X-Debian-Message | from BTS |
| X-Mailing-List | <debian-bugs-dist@lists.debian.org> archive/latest/1861379 |
| List-ID | <debian-bugs-dist.lists.debian.org> |
| List-URL | <https://lists.debian.org/debian-bugs-dist/> |
| Approved | robomod@news.nic.it |
| Lines | 39 |
| Organization | linux.* mail to news gateway |
| Sender | robomod@news.nic.it |
| X-Original-Cc | debian-python@lists.debian.org |
| X-Original-Date | Fri, 4 Oct 2024 14:27:19 +0100 |
| X-Original-Message-ID | <Zv_tN9zID-j51lb7@remnant.pseudorandom.co.uk> |
| X-Original-References | <E1swezb-00DiGm-0w@paradis.debian.org> <Zv_B6KbMbNJEltA4@riva.ucam.org> <E1sweqT-00DgSt-BM@paradis.debian.org> <Zv_B6KbMbNJEltA4@riva.ucam.org> |
| Xref | csiph.com linux.debian.bugs.dist:1215139 linux.debian.maint.python:16319 |
Cross-posted to 2 groups.
Show key headers only | View raw
Control: tags -1 + upstream moreinfo
Control: forwarded -1 https://github.com/projectmallard/mallard-ducktype/issues/21
On Fri, 04 Oct 2024 at 11:22:32 +0100, Colin Watson wrote:
> While pkg_resources is indeed deprecated upstream, there's nothing that
> we can sensibly do about it at the Debian level in lazr.* or zope.*, and
> it's not even as clear as you might hope what to do upstream. They all
> do something like this in an __init__.py (with unimportant variations):
>
> __import__('pkg_resources').declare_namespace(__name__)
>
> As
> https://packaging.python.org/en/latest/guides/packaging-namespace-packages/#pkg-resources-style-namespace-packages
> says:
>
> If you are creating a new distribution within an existing namespace
> package that uses this method then it’s recommended to continue using
> this as the different methods are not cross-compatible and it’s not
> advisable to try to migrate an existing package.
>
> I know pkg_resources is deprecated for most other purposes, but even
> upstream currently advises here not to try to migrate in this case.
> Now, I know there've been some attempts to figure this out:
> https://github.com/pypa/sample-namespace-packages thinks a migration may
> be possible as long as developers are willing to accept some
> limitations.
mallard-ducktype (#1083471) is in a similar situation, although there don't
seem to be any third-party extensions to it packaged in Debian in practice,
so we might be able to get away with just deleting
/usr/lib/python3/dist-packages/mallard/ducktype/extensions/__init__.py and
hoping it doesn't break anything for unpackaged code.
I've asked upstream whether they are aware of third-party extensions that
are not packaged in Debian. I'm not intending to work on this further in
mallard-ducktype until there is an obvious correct thing to do.
Thanks,
smcv
Back to linux.debian.maint.python | Previous | Next | Find similar
Bug#1083471: Migrating away from pkg_resources is difficult for namespace packages Simon McVittie <smcv@debian.org> - 2024-10-04 15:40 +0200
csiph-web