suppress dbus lib warnings + warn against no indent in config

This commit is contained in:
Mateusz Grzywacz 2020-11-10 04:40:57 +01:00
parent fcd862dfdf
commit c743785162
2 changed files with 2 additions and 2 deletions

View file

@ -82,6 +82,7 @@ user_to_sid:
"myusername": "S-1-5-21-1234567890-1234567890-1234567890-1001"
"someotheruser": "S-1-5-21-1234567890-1234567890-1234567890-1003"
```
Note the indentation; each entry has to be preceded by at least one space.
## Playground

View file

@ -30,7 +30,6 @@ from validitysensor.usb import usb
from validitysensor.winbio_constants import finger_ids
dbus.mainloop.glib.DBusGMainLoop(set_as_default=True)
GLib.threads_init()
INTERFACE_NAME = 'io.github.uunicorn.Fprint.Device'
@ -242,7 +241,7 @@ def main():
# Load and perform basic validation of config file.
try:
with (args.configpath / 'dbus-service.yaml').open(mode='rt') as configfd:
config = yaml.load(configfd)
config = yaml.load(configfd, Loader=yaml.BaseLoader)
except FileNotFoundError:
# No configuration file. Create default
config = {'user_to_sid': {}}