Skip to content

Rename the algorithm brokerage data to deployment details and add a helper - #9792

Merged
Martin-Molinero merged 3 commits into
QuantConnect:masterfrom
Martin-Molinero:feature-rename-deployment-details
Sep 14, 2026
Merged

Martin-Molinero merged 3 commits into
QuantConnect:masterfrom
Martin-Molinero:feature-rename-deployment-details

Conversation

@Martin-Molinero

@Martin-Molinero Martin-Molinero commented Sep 14, 2026

Copy link
Copy Markdown
Member

Description

Renames the members added in #9788:

Before After
IAlgorithm.BrokerageData IAlgorithm.DeploymentDetails
IAlgorithm.SetBrokerageData IAlgorithm.SetDeploymentDetails
IResultHandler.AddBrokerageData IResultHandler.AddDeploymentDetail
IResultHandler.BrokerageData IResultHandler.DeploymentDetails
AlgorithmConfiguration.BrokerageData AlgorithmConfiguration.DeploymentDetails

Python: self.brokerage_data -> self.deployment_details.

LiveNodePacket.BrokerageData and IBrokerageFactory.BrokerageData, which hold the brokerage credentials, are untouched.

Also adds DeploymentDetailsHelper.Add(key, value), a single entry point for brokerages, data queue handlers and any other component to share a deployment detail. It resolves the result handler from the Composer so callers don't have to, never throws, and logs an error once if no result handler is found.

Related Issue

#9788

Motivation and Context

The name added in #9788 collided with the existing LiveNodePacket.BrokerageData / IBrokerageFactory.BrokerageData, which hold the brokerage credentials and are a different thing, making it easy to confuse the two. DeploymentDetails is also neutral for entries shared by a data queue handler or any other component, not only the brokerage, and it sits naturally next to DeployId / DeploymentTarget.

The helper keeps the caller side to one line and makes sharing a detail safe to call from anywhere, including when running without a result handler, like in a plugin's unit tests.

Requires Documentation Change

QCAlgorithm.DeploymentDetails / self.deployment_details, renamed from BrokerageData / brokerage_data before it was ever documented.

How Has This Been Tested?

Existing tests, renamed accordingly, plus new DeploymentDetailsHelperTests covering adding through the Composer, no result handler, and a result handler that throws. AlgorithmConfigurationTests, LiveTradingResultHandlerTests, AlgorithmManagerTests, BrokerageSetupHandlerTests, BacktestingResultHandlerTests, report and result deserialization suites all pass.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • Refactor (non-breaking change which improves implementation)
  • Performance (non-breaking change which improves performance. Please add associated performance test and results)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Non-functional change (xml comments/documentation/etc)

Checklist:

  • My code follows the code style of this project.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.
  • My branch follows the naming convention bug-<issue#>-<description> or feature-<issue#>-<description>

🤖 Generated with Claude Code

Martin-Molinero and others added 2 commits September 14, 2026 12:55
Renames the members added in QuantConnect#9788: IAlgorithm.BrokerageData ->
DeploymentDetails, SetBrokerageData -> SetDeploymentDetails,
IResultHandler.AddBrokerageData -> AddDeploymentDetail and
AlgorithmConfiguration.BrokerageData -> DeploymentDetails.

The old name collided with LiveNodePacket.BrokerageData and
IBrokerageFactory.BrokerageData, which hold the brokerage credentials and are
a different thing. The new name is also neutral for entries shared by a data
queue handler or any other component, not just the brokerage.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01UAELnEhZMd7X9D6rc9CAmC
Single entry point for brokerages, data queue handlers and any other component
to share a deployment detail, resolving the result handler from the Composer so
callers don't have to. Never throws and logs once if no result handler is found.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01UAELnEhZMd7X9D6rc9CAmC
@Martin-Molinero Martin-Molinero changed the title Rename the algorithm brokerage data to deployment details Rename the algorithm brokerage data to deployment details and add a helper Sep 14, 2026
Resetting dropped the parts registered by TestGlobals, like the factor file
provider, which nothing puts back, breaking later tests that resolve them from
the composer, IndicatorBasedOptionPriceModelTests through DividendYieldProvider.
The test now explicitly uses the result handler the composer resolves, adding
one only if there is none.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01UAELnEhZMd7X9D6rc9CAmC
@Martin-Molinero
Martin-Molinero merged commit 5b0c997 into QuantConnect:master Sep 14, 2026
7 of 8 checks passed
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.

1 participant