<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def cancelHistoricalData(self, bars: BarDataList):
 """ Cancel the update subscription for the historical bars. Args: bars: The bar list that was obtained from ``reqHistoricalData`` with a keepUpToDate subscription. """

        self.client.cancelHistoricalData(bars.reqId)
        self.wrapper.endSubscription(bars)