Skip to content

Update QuantConnect.pythonnet to 2.0.67 - #9964

Merged
jhonabreul merged 3 commits into
QuantConnect:masterfrom
jhonabreul:feature-update-pythonnet-2.0.68
Oct 28, 2026
Merged

jhonabreul merged 3 commits into
QuantConnect:masterfrom
jhonabreul:feature-update-pythonnet-2.0.68

Conversation

@jhonabreul

@jhonabreul jhonabreul commented Oct 28, 2026 •

Copy link
Copy Markdown
Collaborator

Description

Updates the QuantConnect.pythonnet package reference to 2.0.67 in the 11 csproj files that consume it.

2.0.67 binds C# extension methods to the type they extend, so Python can call order_event.status.is_open() or Resolution.MINUTE.to_time_span() (QuantConnect/pythonnet#150), and gives types with an implicit numeric conversion, such as OrderFee, Python's number protocol, so sum(fees), fee > 0 and float(fee) work (QuantConnect/pythonnet#151).

Companions: QuantConnect/LeanCloud#1548, QuantConnect/LeanCloud.Services#278.

Related Issue

N/A

Motivation and Context

Keeps LEAN on the latest QuantConnect.pythonnet, so Python algorithms can use extension methods and arithmetic on fees the way C# does.

Requires Documentation Change

No

How Has This Been Tested?

  • OrderEventTests.EnumExtensionMethodsAreCallableFromPython: is_open, is_closed, is_limit_order and to_time_span called on enum values from a Python module.
  • OrderFeesTests.OrderFeeIsNumericFromPython: sum, +, comparisons, float and max on order fees from a Python module.
  • Both fail on 2.0.66 with the original AttributeError and unsupported operand type(s) errors and pass with the 2.0.67 runtime built from the pythonnet branch, injected over the test output.

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>

@jhonabreul jhonabreul closed this Oct 28, 2026
@jhonabreul
jhonabreul deleted the feature-update-pythonnet-2.0.68 branch October 28, 2026 15:40
@jhonabreul jhonabreul changed the title Update QuantConnect.pythonnet to 2.0.68 Update QuantConnect.pythonnet to 2.0.67 Oct 28, 2026
@jhonabreul
jhonabreul restored the feature-update-pythonnet-2.0.68 branch October 28, 2026 15:44
@jhonabreul jhonabreul reopened this Oct 28, 2026
@jhonabreul
jhonabreul merged commit f1c7ed1 into QuantConnect:master Oct 28, 2026
7 of 16 checks passed
@jhonabreul
jhonabreul deleted the feature-update-pythonnet-2.0.68 branch October 28, 2026 18:42
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.

2 participants