code: def piece_size(self):
          
          if 'piece length' not in self.metainfo['info']:
              if self.size is None:
                  return None
              else:
                  self.calculate_piece_size()
          return self.metainfo['info']['piece length']
docs: Piece size/length or ``None``
  
          If set to ``None``, :attr:`calculate_piece_size` is called.
  
          If :attr:`size` returns ``None``, this also returns ``None``.
  
          Setting this property sets ``piece length`` in :attr:`metainfo`\
          ``['info']``.