# from twisted.internet import defer,reactor # from ..utils.helper import Helper class ZuqiuPipeline(object): def open_spider(self, spider): pass # @defer.inlineCallbacks # def process_item(self,item,spider): # out=defer.Deferred() # reactor.callInThread(self._do_calculation,item,out) # yield out # def _do_calculation(self,item,out): # pass def process_item(self, item, spider): all = item['all'] team_h, team_c = all['team_h'], all['team_c'] league, league_id = all['league'], all['league'] datetime, re_time = all['datetime'], all['re_time'] match_id = all['gid'] print(league, team_h, team_c, datetime, match_id, league_id) return None