From 168113ce554ad6b4aa98ef1978d20c940696b202 Mon Sep 17 00:00:00 2001 From: Sebastien Bourdeauducq Date: Wed, 23 Mar 2016 15:13:56 +0800 Subject: [PATCH] protocols/pc_rpc: support dynamic target creation --- artiq/protocols/pc_rpc.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/artiq/protocols/pc_rpc.py b/artiq/protocols/pc_rpc.py index 512237d60..d4484dfc2 100644 --- a/artiq/protocols/pc_rpc.py +++ b/artiq/protocols/pc_rpc.py @@ -538,6 +538,9 @@ class Server(_AsyncioServer): except KeyError: return + if callable(target): + target = target() + while True: line = await reader.readline() if not line: