• Dan Jones's avatar
    fix: create data path and default client · 800066c0
    Dan Jones authored
    The code was catching a FileNotFoundError and trying
    to create the empty file but wasn't creating the
    data directory before trying to save into it.
    
    Rather than starting with 0 clients it now creates
    a default "admin" client so that when you start the
    app you always have something.
    
    We need to think about how to provide these credentials
    back to the user. Normally you save the response from
    the post to /client. You can just read the file.
    
    The admin client is set to receive all messages.
    It may be better to set it to receive nothing so that
    if the default client is not implemented the queues don't
    fill up.
    800066c0
client_model.py 2.53 KB