code: def partitions_for(self, topic):
          
          max_wait = self.config['max_block_ms'] / 1000.0
          return self._wait_on_metadata(topic, max_wait)
docs: Returns set of all known partitions for the topic.