Using self.sendline()

Replacing self.transport.write() with self.sendline()