Skip to content

Commit bc535c5

Browse files
author
rob
committed
fix robcarver17#1085 by removing functionality
1 parent 0442242 commit bc535c5

File tree

2 files changed

+1
-12
lines changed

2 files changed

+1
-12
lines changed

sysbrokers/IB/client/ib_client.py

+1-9
Original file line numberDiff line numberDiff line change
@@ -150,10 +150,6 @@ def get_instrument_code_from_broker_contract_object(
150150
instrument_code = self.get_instrument_code_from_broker_identity_for_contract(
151151
broker_identity
152152
)
153-
if instrument_code is missing_contract:
154-
## WE DON'T RAISE AN ERROR HERE AS IT CAUSES ERROR RECURSION SEE #1085
155-
156-
return missing_contract
157153

158154
return instrument_code
159155

@@ -194,9 +190,6 @@ def broker_identity_for_contract(
194190
allow_expired=False,
195191
allow_multiple_contracts=False,
196192
)
197-
if contract_details is missing_contract:
198-
## ## WE DON'T RAISE AN ERROR HERE AS IT CAUSES ERROR RECURSION SEE #1085
199-
return missing_contract
200193

201194
return IBInstrumentIdentity(
202195
ib_code=str(contract_details.contract.symbol),
@@ -217,8 +210,7 @@ def get_contract_details(
217210
)
218211

219212
if len(contract_details) == 0:
220-
## WE DON'T RAISE AN ERROR HERE AS IT CAUSES ERROR RECURSION SEE #1085
221-
return missing_contract
213+
raise missingContract
222214

223215
if allow_multiple_contracts:
224216
return contract_details

sysbrokers/IB/client/ib_contracts_client.py

-3
Original file line numberDiff line numberDiff line change
@@ -596,9 +596,6 @@ def ib_get_contract_chain(
596596
allow_multiple_contracts=True,
597597
)
598598

599-
if new_contract_details_list is missing_contract:
600-
raise missingContract
601-
602599
ibcontract_list = [
603600
contract_details.contract for contract_details in new_contract_details_list
604601
]

0 commit comments

Comments
 (0)