Description
chalk load doesn't support a config filename with a dash in it. It doesn't need to support that, but the error is opaque. Chalk should at least tell the user that the issue is because there's a dash in the filename.
admin@ubuntu:~$ ./chalk load heartbeat-config.c4m
warn: Could not find or install cosign; cannot sign or verify.
info: Attempting to load module from: heartbeat-config.c4m
Configuring Component: /home/admin/heartbeat-config
Finished configuration for /home/admin/heartbeat-config
info: [testing config]: Validating configuration.
error: chalk: [testing config]: 2:5:
Parse error: Expected either end of statement or: TtFrom
use heartbeat-config from "/home/admin"
^
admin@ubuntu:~$ mv heartbeat-config.c4m heartbeat_config.c4m
admin@ubuntu:~$ ./chalk load heartbeat_config.c4m
warn: Could not find or install cosign; cannot sign or verify.
info: Attempting to load module from: heartbeat_config.c4m
Configuring Component: /home/admin/heartbeat_config
Finished configuration for /home/admin/heartbeat_config
info: [testing config]: Validating configuration.
info: [testing config]: Configuration successfully validated.
info: Configuration replaced in binary: /home/admin/chalk
info: /home/admin/.local/chalk/chalk.log: Open (sink conf='default_out')
info: Full chalk report appended to: ~/.local/chalk/chalk.log
Result
Instead it should do something like this:
admin@ubuntu:~$ ./chalk load heartbeat-config.c4m
error: c4m config file name must not contain dash
Description
chalk loaddoesn't support a config filename with a dash in it. It doesn't need to support that, but the error is opaque. Chalk should at least tell the user that the issue is because there's a dash in the filename.Result
Instead it should do something like this: