Applying black formatting
- Fixing flake8 configuration to agree with black - Adding black validation check to github actions
This commit is contained in:
@@ -12,8 +12,10 @@ capnp.create_event_loop(threaded=True)
|
||||
|
||||
|
||||
def parse_args():
|
||||
parser = argparse.ArgumentParser(usage='Connects to the Example thread server \
|
||||
at the given address and does some RPCs')
|
||||
parser = argparse.ArgumentParser(
|
||||
usage="Connects to the Example thread server \
|
||||
at the given address and does some RPCs"
|
||||
)
|
||||
parser.add_argument("host", help="HOST:PORT")
|
||||
|
||||
return parser.parse_args()
|
||||
@@ -21,10 +23,10 @@ at the given address and does some RPCs')
|
||||
|
||||
class StatusSubscriber(thread_capnp.Example.StatusSubscriber.Server):
|
||||
|
||||
'''An implementation of the StatusSubscriber interface'''
|
||||
"""An implementation of the StatusSubscriber interface"""
|
||||
|
||||
def status(self, value, **kwargs):
|
||||
print('status: {}'.format(time.time()))
|
||||
print("status: {}".format(time.time()))
|
||||
|
||||
|
||||
def start_status_thread(host):
|
||||
@@ -44,14 +46,14 @@ def main(host):
|
||||
status_thread.daemon = True
|
||||
status_thread.start()
|
||||
|
||||
print('main: {}'.format(time.time()))
|
||||
print("main: {}".format(time.time()))
|
||||
cap.longRunning().wait()
|
||||
print('main: {}'.format(time.time()))
|
||||
print("main: {}".format(time.time()))
|
||||
cap.longRunning().wait()
|
||||
print('main: {}'.format(time.time()))
|
||||
print("main: {}".format(time.time()))
|
||||
cap.longRunning().wait()
|
||||
print('main: {}'.format(time.time()))
|
||||
print("main: {}".format(time.time()))
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
if __name__ == "__main__":
|
||||
main(parse_args().host)
|
||||
|
||||
Reference in New Issue
Block a user