This repository has been archived by the owner on Sep 14, 2020. It is now read-only.
Publish types for kwargs/classes exposed to the user-side #341
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.
What do these changes do?
Publishes all object types which are exposed to the user-side: as handlers' kwargs or as overridable classes.
Description
This was actually promised in #194, but not actually implemented.
With these types exposed, the users can type-annotate the kwargs, making them friendly in the IDEs, or or to type-check their operators. It is more wordy than in the examples/docs, but this is how type annotations generally work:
Another group of classes exposed are those supposed to be used in the overridden/inherited classes, such as persistence storage classes: the storage classes were exposed, but the types of their arguments were not. This is now fixed.
There are no changes in the behaviour.
The
UserDict
class is renamed toMemo
to make it more clear what kind of an object it is (not only a dict, but also free-named field container). The kwargs remains the same:memo
.Issues/PRs
Type of changes
Checklist
CONTRIBUTORS.txt