def _service(self, id):
        if self.service_cache not in id:
            c_query = """select start_date, end_date, monday, tuesday,
            wednesday, thursday, friday, saturday, sunday from calendar
            where service_id=:service_id and _feed=:_feed"""
            c_filter = {'service_id': id, '_feed': self.provider.feed_id}
            cur = self.provider.conn.cursor()
            self.service_cache[id] = dict(next(cur.execute(c_query, c_filter)))

            cd_query = """select date, exception_type as e from calendar_dates
            where service_id=:service_id and _feed=:_feed"""
            cd_result = cur.execute(cd_query, c_filter)
            self.service_cache[id]['exceptions'] = {r['date']: r['e']
                                                    for r in cd_result}
        return self.service_cache[id]
dataset/ETHPy150Open spaceboats/busbus/busbus/provider/gtfs.py/GTFSArrivalGenerator._service/swapped operands of `not in`