-
Notifications
You must be signed in to change notification settings - Fork 41
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
Forking/parallelism tracking #218
Conversation
83cf88a
to
3c81688
Compare
Also fixes #211 |
cacb9c3
to
467f484
Compare
dadd91b
to
3c619fe
Compare
3c619fe
to
e753966
Compare
@@ -42,6 +43,9 @@ | |||
from burr.lifecycle.base import LifecycleAdapter | |||
from burr.lifecycle.internal import LifecycleAdapterSet | |||
|
|||
if TYPE_CHECKING: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TODO -- double-check that this is needed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll remove it later but this is OK for now. The other one we do an in-line import, but this is for type-checking
@@ -1640,7 +1640,7 @@ | |||
"name": "python", | |||
"nbconvert_exporter": "python", | |||
"pygments_lexer": "ipython3", | |||
"version": "3.10.4" | |||
"version": "3.11.6" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TODO -- change this back
notebook.ipynb
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove
e1bca8b
to
1148692
Compare
A node can now query for application context by setting an input as __context -- this is of type ApplicationContext. This will allow forking (+ any other information we may need from inside the node). This is one of two __ variables (the other being tracer). The dependency factory is a bit in flux but the way these are constructed is not yet public-facing (we cannot arbitrarily add global injectors), so we can change it. This also fixes a bug in which dependency factories were not allowed to be optional/have defaults. This enables the user to build out a function that can be run outside the app (with a null context)..
This enables an application to specify the app that spawned it.
This enables us to track from child app the parents that spawned it
This does a little trickiness with the local tracker, but will allow the UI to display bidirectional links for forks/spawns.
This allows us to expand/focus on children in the app list. This also hides the partition key if it doesn't exist See #211
This adds the proper UI component + fixes logging/server to log correctly when spawning.
This is potentially backwards compatible, but people should really not be doing this -- in standard python convention (and burr, specifically), these are reserved for internal/special cases.
This way we can just run tests locally
Example + concepts doc
1148692
to
fa9ec33
Compare
Killing this on in favor of the mega-one (easier to iterate on): #225 |
Allows forking/parallelism. Part (1) of this: #52. In this PR we allow the user to do their own.
See #52
Changes
__context
input for nodes to declare__context
to be nullableTODO:
How I tested this
Notes
Checklist