-
Notifications
You must be signed in to change notification settings - Fork 128
Closed
Description
This is an audit of pluggy's public API, from the perspective of typing. The idea is that every type which is reachable transitively through the public API should be exported from pluggy
and have a clean documented interface (and without _
prefixes), with possible exceptions.
Note: this is different from the goal of making hook calls themselves typed. That would be great, but is a separate enhancement.
-
_HookRelay
- throughpm.hook
- Now
pluggy.HookRelay
- Now
-
TagTracer
- throughpm.trace
- TODO: audit of API and transitive types
-
_Plugin
- type alias for a plugin object - justobject
.- Actually no need to export this.
-
_Namespace
- type alias forModuleType | type
- Actually no need to export this
-
DistFacade
- it is compat adapter, probably shouldn't be exported -
_HookCaller
- throughpm.get_hookcallers
,pm.subset_hook_caller
- Now
pluggy.HookCaller
- Now
-
HookSpec
- through_HookCaller.spec
-
HookImpl
- through_HookCaller.get_hookimpls
-
_HookSpecOpts
- throughpm.parse_hookspec_opts
- Now
pluggy.HookSpecOpts
- Now
-
_HookImplOpts
- throughpm.parse_hookimpl_opts
- Now
pluggy.HookImplOpts
- Now
-
_BeforeTrace
,_AfterTrace
- type aliases, inpm.add_hookcall_monitoring
- No need to export
-
_Result
- in old-style wrappers- Now
pluggy.Result
- Now
Other tasks are:
- Update the sphinx version we use in RTD (currently uses
<2
), need recent one for typing improvements - Mark immutable fields as
Final
- Mark non-subclassable classes
@final
- Make private contstructors of public types private/hidden
- Document all public types in the API reference
Metadata
Metadata
Assignees
Labels
No labels