diff options
Diffstat (limited to 'examples/network/fortuneclient.py')
-rw-r--r-- | examples/network/fortuneclient.py | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/examples/network/fortuneclient.py b/examples/network/fortuneclient.py index 00247eee0..ee4bc5670 100644 --- a/examples/network/fortuneclient.py +++ b/examples/network/fortuneclient.py @@ -118,13 +118,7 @@ class Client(QtWidgets.QDialog): return nextFortune = instr.readString() - - try: - # Python v3. - nextFortune = str(nextFortune, encoding='ascii') - except TypeError: - # Python v2. - pass + nextFortune = str(nextFortune, encoding='ascii') if nextFortune == self.currentFortune: QtCore.QTimer.singleShot(0, self.requestNewFortune) |