Pythonnet PEP8 fixes (#7931)
API Tests / build (push) Has been cancelled
Benchmarks / build (push) Has been cancelled
Build & Test Lean / build (push) Has been cancelled
Regression Tests / build (push) Has been cancelled
Report Generator Tests / build (push) Has been cancelled
Research Regression Tests / build (push) Has been cancelled
Python Virtual Environments / build (push) Has been cancelled

* Improve python exception message for cases when derived class uses member names already defined in base C# classes

* Update pythonnet version to 2.0.33

* Update error message

* Pythonnet version bump to 2.0.34. Minor unit test fix

* Enhance pythonnet overload tests

---------

Co-authored-by: Jared <jaredbroad@gmail.com>
Co-authored-by: Martin Molinero <martin.molinero1@gmail.com>
This commit is contained in:
Jhonathan Abreu
2024-04-17 13:25:25 -04:00
committed by GitHub
parent 3da1afb2fe
commit 17ba1088bd
16 changed files with 56 additions and 21 deletions
@@ -64,6 +64,31 @@ class CustomDataMultiFileObjectStoreRegressionAlgorithm(QCAlgorithm):
if customData2.Price == 0:
raise Exception("Custom data2 price was not expected to be zero, index access")
# pep8 `get`
# passing symbol
customData = slice.get(ExampleCustomData, self.customSymbol)
if customData.Price == 0:
raise Exception("Pep8: Custom data price was not expected to be zero")
customData2 = self.current_slice.get(ExampleCustomData, self.customSymbol)
if customData2.Price == 0:
raise Exception("Pep8: Custom data2 price was not expected to be zero")
# accessing by symbol
customData = slice.get(ExampleCustomData)[self.customSymbol]
if customData.Price == 0:
raise Exception("Pep8: Custom data price was not expected to be zero, index access")
customData2 = self.current_slice.get(ExampleCustomData)[self.customSymbol]
if customData2.Price == 0:
raise Exception("Pep8: Custom data2 price was not expected to be zero, index access")
# passing only symbol
customData = slice.get(self.customSymbol)
if customData.Price == 0:
raise Exception("Pep8: Custom data price was not expected to be zero")
customData2 = self.current_slice.get(self.customSymbol)
if customData2.Price == 0:
raise Exception("Pep8: Custom data2 price was not expected to be zero")
self.receivedData.append(customData)
def OnEndOfAlgorithm(self):