• Iustin Pop's avatar
    Standardise LUXI call argument types · a629ecb9
    Iustin Pop authored
    
    
    Currently, we have 4 types of arguments in LUXI calls:
    
    - most common, a list of values
    - a single argument that is sent as a list of one element
    - a single argument that is sent by itself
    - a dictionary (only Query and QueryFields)
    
    This inconsistency makes it not only harder to auto-generate the
    HTools LUXI interface, but also in general to check the arguments and
    (if we ever want to do it) auto-generate the Python LUXI client.
    
    Compare this with the node daemon, which uses consistently a list for
    its arguments, and even with way more changes over time had no issues
    with extending the interface.
    
    In case we want to extend a call, there are two options:
    
    - preferred: add a new call, keep the old one unchanged
    - possible: add further parameters to the current argument list
    
    The patch against HTools will follow—sending separately as the Python
    changes are very clear by themselves.
    Signed-off-by: default avatarIustin Pop <iustin@google.com>
    Reviewed-by: default avatarMichael Hanselmann <hansmi@google.com>
    a629ecb9
luxi.py 15.8 KB