Skip to content
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

Remove unused attributes from EngineContext #13917

Merged
merged 5 commits into from
Jun 12, 2024
Merged

Conversation

desertaxle
Copy link
Member

@desertaxle desertaxle commented Jun 11, 2024

After the engine refactor, there are some attributes on the EngineContext that are used any longer. This PR removes them to avoid cruft and simplify the creation of a EngineContext.

Closes #13951

Example

Checklist

  • This pull request references any related issue by including "closes <link to issue>"
    • If no issue exists and your change is not a small fix, please create an issue first.
  • If this pull request adds new functionality, it includes unit tests that cover the changes
  • This pull request includes a label categorizing the change e.g. maintenance, fix, feature, enhancement, docs.

For documentation changes:

  • This pull request includes redirect settings in mint.json for files that are removed or renamed.

For new functions or classes in the Python SDK:

  • This pull request includes helpful docstrings.
  • If a new Python file was added, this pull request contains a stub page in the Python SDK docs and an entry in docs/mint.json navigation.

@desertaxle desertaxle marked this pull request as ready for review June 11, 2024 23:42
@desertaxle desertaxle requested a review from a team as a code owner June 11, 2024 23:42
Comment on lines -394 to -406
# Tracking for objects created by this flow run
task_run_futures: List[PrefectFuture] = Field(default_factory=list)
task_run_states: List[State] = Field(default_factory=list)
# Tracking for result from task runs in this flow run
task_run_results: Dict[int, State] = Field(default_factory=dict)
flow_run_states: List[State] = Field(default_factory=list)

# The synchronous portal is only created for async flows for creating engine calls
# from synchronous task and subflow calls
sync_portal: Optional[anyio.abc.BlockingPortal] = None
timeout_scope: Optional[anyio.abc.CancelScope] = None

# Task group that can be used for background tasks during the flow run
background_tasks: anyio.abc.TaskGroup
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🙇

@desertaxle desertaxle merged commit 295efbd into main Jun 12, 2024
26 checks passed
@desertaxle desertaxle deleted the remove-extra-context-attr branch June 12, 2024 21:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Remove unused attributes from flow and task run context models
2 participants