pluggy icon indicating copy to clipboard operation
pluggy copied to clipboard

deprecate load_setuptools_entrypoints

Open RonnyPfannschmidt opened this issue 7 years ago • 4 comments

entry-point loading should be moved into a interface where one passes the entry-point system (either pkg_resources or entry_points), the plugin-manager and the entrypoint name into a helper that facilitates registration

RonnyPfannschmidt avatar May 23 '18 09:05 RonnyPfannschmidt

Good idea, this will make pluggy more useful in contexts outside the setuptools ecosystem.

nicoddemus avatar May 25 '18 00:05 nicoddemus

@RonnyPfannschmidt what would be some other examples for alternative registry namespaces? I find building out a general API at least requires a couple examples.

Maybe the filesystem-conftest.py listed pytest_plugins variables as discovered with pytest?

goodboy avatar May 25 '18 00:05 goodboy

@goodboy im not aware of any - the distribution<>entryoint mapping things is just something that is generalizable as a next step

RonnyPfannschmidt avatar May 25 '18 05:05 RonnyPfannschmidt

Hello,

I'm wondering if it is possible that the helper can load a plugin from a path to a python module? This will help to load plugin form user who don't fully mastering in packaging using setuptools.

for instance a function load_entrypoints(pm, entrypoint), the entrypoint could be a key as defined in setuptools or a path to a python module to be loaded.

The module imp could be used to load the module.

BR anxuae

anxuae avatar Mar 09 '20 20:03 anxuae