summaryrefslogtreecommitdiff
path: root/tutorial/py.twisted
diff options
context:
space:
mode:
authorJames E. King III <jking@apache.org>2019-01-31 18:35:51 -0500
committerJames E. King III <jking@apache.org>2019-02-01 11:13:49 -0500
commit3ec4031a4c6d685bcc02fa10dd13b2df58732b82 (patch)
treea8ca7edd5f22cc4503cdd194a2036e7764325663 /tutorial/py.twisted
parent53bd0e6295547e76ab00913cfd62f8d040bd996c (diff)
downloadthrift-3ec4031a4c6d685bcc02fa10dd13b2df58732b82.tar.gz
THRIFT-4405: fix cygwin on appveyor
Diffstat (limited to 'tutorial/py.twisted')
-rwxr-xr-xtutorial/py.twisted/PythonClient.py1
-rwxr-xr-xtutorial/py.twisted/PythonServer.py1
2 files changed, 2 insertions, 0 deletions
diff --git a/tutorial/py.twisted/PythonClient.py b/tutorial/py.twisted/PythonClient.py
index 63dde7e7a..2976495e3 100755
--- a/tutorial/py.twisted/PythonClient.py
+++ b/tutorial/py.twisted/PythonClient.py
@@ -67,6 +67,7 @@ def main(client):
print(('Check log: %s' % (log.value)))
reactor.stop()
+
if __name__ == '__main__':
d = ClientCreator(reactor,
TTwisted.ThriftClientProtocol,
diff --git a/tutorial/py.twisted/PythonServer.py b/tutorial/py.twisted/PythonServer.py
index 1b0e2d5b9..034e4a312 100755
--- a/tutorial/py.twisted/PythonServer.py
+++ b/tutorial/py.twisted/PythonServer.py
@@ -85,6 +85,7 @@ class CalculatorHandler:
def zip(self):
print('zip()')
+
if __name__ == '__main__':
handler = CalculatorHandler()
processor = Calculator.Processor(handler)