-
Notifications
You must be signed in to change notification settings - Fork 3
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
New Event Semantic and Major Improvements #12
Merged
Merged
Conversation
This file contains 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
commit 01e2d0f Author: Manuel Da Pena <[email protected]> Date: Mon Mar 25 02:29:21 2024 -0400 Refine Event Emitters docstring commit fbd4b2e Author: Manuel Da Pena <[email protected]> Date: Mon Mar 25 01:58:11 2024 -0400 Update FastAPI Event Emitter docstrings commit 23c5e16 Author: Manuel Da Pena <[email protected]> Date: Mon Mar 25 01:27:49 2024 -0400 Update Celery Event Emitter docstrings commit 4da034b Author: Manuel Da Pena <[email protected]> Date: Sun Mar 24 21:53:14 2024 -0400 Update RQ Event Emitter docstrings commit c539635 Author: Manuel Da Pena <[email protected]> Date: Sun Mar 24 21:29:02 2024 -0400 Update Executor Event Emitter docstrings commit 1cca568 Author: Manuel Da Pena <[email protected]> Date: Sun Mar 24 21:10:48 2024 -0400 Update AsyncIO Event Emitter docstrings commit e3e12cd Author: Manuel Da Pena <[email protected]> Date: Sun Mar 24 18:39:04 2024 -0400 Update Event Emitter docs commit d9221d2 Author: Manuel Da Pena <[email protected]> Date: Sun Mar 24 15:08:35 2024 -0400 Update color of badges
…larity and consistency
…proved clarity and consistency" This reverts commit 8aa09df.
- Improved performance of the event emitter and event linker. - Introduced a new event semantic where ellipsis (...) refers to all events. - Now supports subscription and emission of any dataclass object.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
dependencies
Pull requests that update a dependency
documentation
Improvements or additions to documentation
enhancement
Suggests an improvement or enhancement to an existing feature
feature
New feature or request
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.
Initial Checks
Description
This PR introduces significant improvements to Pyventus' event handling system, including a new event semantic model and extended
dataclass
support. Key changes focus on removing the baseEvent
class, enhancingsync
event handling, and strengthening documentation. Release Notes:Breaking Changes
Event
class due to improved event semantics and unnecessary redundancy.get_event_registry()
method ofEventLinker
toget_registry()
.__event_registry
inner property ofEventLinker
to__registry
.get_events_by_handler()
method ofEventLinker
toget_event_handlers_by_events()
.get_handlers_by_events()
method ofEventLinker
toget_event_handlers_by_events()
._executor_callback()
of theExecutorEventEmitter
to_callback()
.CeleryEventEmitter
from_executor
topyventus_executor
to avoid collisions with othertask names.
Added
__slots__
toEventLinkageWrapper
class for more efficient memory usage.dataclass
object, removing the limitation of onlyEvent
subclasses.
force_async
parameter to theEventHandler
class andEventLinker
subscription methods to be able tooptimize the execution of
sync
callbacks based on their workload....
(Ellipsis) is now used to refer to all events on asubscription, like the
onAny()
method but with a Pythonic syntax.mkdocs-material social cards
plugin, which provides a preview of the documentation content when shared onsocial media platforms.
Changed
EventLinker
andEventEmitter
classes.EventLinker
, andEventHandler
.git-revision-date-localized
plugin.git-authors
plugin with thegit-committers
plugin.features of Pyventus.
Removed
once
flag in theEventHandler
class.Fixed