I am passing Python tuple as a SQL parameter when making bulk API Call with simple salesforce library. The script works perfectly fine if my tuple has more than one element in it, however, it gives me IndexError: list index out of range if my tuple has just one element. . My code below:
id_params_tuple = ('0060z000023HFr4AAG',)
sql = "SELECT Id FROM OpportunityLineItem where Opportunity_ID__c IN {}".format(id_params_tuple)
opp_products_raw_data = sf.bulk.OpportunityLineItem.query(sql)
print(opp_products_raw_data)
How can I work around this issue?