Skip to content

Conversation

@andystaples
Copy link
Contributor

Saving the entity context to a property on _OrchestrationExecutor is both unnecessary and introduces the possibility of clobbering or race conditions - addresses this by reducing scope to _RuntimeOrchestrationContext

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR refactors the entity context management in the orchestration worker by simplifying how OrchestrationEntityContext is initialized and removing unnecessary state tracking.

Key Changes:

  • Moved OrchestrationEntityContext initialization from _OrchestrationExecutor.execute() to _RuntimeOrchestrationContext.__init__()
  • Removed the unused _entity_state field from _OrchestrationExecutor
  • Removed the entity_context parameter from _RuntimeOrchestrationContext.__init__()

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@berndverst berndverst merged commit d606b35 into main Nov 11, 2025
18 checks passed
@berndverst berndverst deleted the andystaples/minimize-entity-state-exposure branch November 11, 2025 00:29
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.

3 participants