code: def symbol(self) -> str:
          
          symbol = piece_symbol(self.piece_type)
          return symbol.upper() if self.color else symbol
docs: Gets the symbol ``P``, ``N``, ``B``, ``R``, ``Q`` or ``K`` for white
          pieces or the lower-case variants for the black pieces.