-
Notifications
You must be signed in to change notification settings - Fork 18
Version 2.0 #40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
geowurster
wants to merge
30
commits into
main
Choose a base branch
from
v2-vendorized
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Version 2.0 #40
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Pass the active exception to 'BrokenPlugin()' rather than just assuming that an exception is active.
Looking at the 'click' source code, it is quite hard to suggest a program name.
Can provide a _much_ better error message if we have the entire entry point.
The message is an error, and thus should be written to stderr.
Eliminating as many dependencies as possible.
This was referenced Jun 9, 2025
Closed
Closed
Plugins can be loaded from: * Entry point group name. * 'importlib.metadata.EntryPoint()'. * Sequence of 'EntryPoint()' objects. Closes #13
For loading plugins from multiple entry point groups.
Give users the module name containing the plugin that failed to load.
See inline comment in 'click_plugins_tests.py' for details. Closes #38.
This was referenced Jun 9, 2025
vendoring could be a a good option |
This was referenced Jun 9, 2025
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Version 2.0
No major changes to the functionality of the library, but major changes for the
project. This PR is quite large, and the project's end state can be viewed at:
https://github.com/click-contrib/click-plugins/tree/v2-vendorized
I no longer have the capacity or interest in maintaining this project, and I
am not really interested in vetting other potential owners. Instead, I am
switching to a model where users can either vendor
a single file, or use the project as a reference implementation. Issues like
#23 and #31 are great examples of where this package struggles, and where
vendoring allows for better or more opinionated solutions that are appropriate
for specific use cases or environments.
End State
This PR puts the project in a state where it has:
click>=6
click
v8.2.0 (Tests fail onclick>=8.2.0
#38)pkg_resources
toimportlib
(Clarifypkg_resources
vsimportlib_metadata
#37)Python Package
One major change is that the project no longer directly supports building a
pip
package – meaning that it no longer provides asetup.py
,pyproject.toml
, etc. Users are free to build a package as needed.Prior to merging this MR, I will publish an updated package on PyPI marking the
project as inactive, and directing users to this repository (#39).
API Changes
click_plugins.with_plugins()
likely do not need to beupdated. Users of alternate entrypoint loading mechanisms may hit surprises.
This function's signature has been improved, and can now accept a string
describing an entrypoint name.
click_plugins.core.BrokenPlugin()
has moved toclick_plugins.BrokenPlugin()
.See
CHANGES.rst
for other changes.Rollout
These changes require a bit of coordination with #39. The order of operations will be:
main
, resolve merge conflicts, etc.