You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With kwatchv0.6.1 built using go1.18.4, running kwatch with no config.yaml in present directory, the kwatch application panics after issuing WARN about the missing config file:
$ ./kwatch
INFO[0000] :tada: kwatch@dev just started!
WARN[0000] unable to load config file: open config.yaml: no such file or directory
panic: interface conversion: interface {} is nil, not map[string]interface {}
goroutine 1 [running]:
github.com/abahmed/kwatch/util.GetProviders()
/home/abuild/rpmbuild/BUILD/kwatch-0.6.1/util/util.go:121 +0x1316
main.main()
/home/abuild/rpmbuild/BUILD/kwatch-0.6.1/main.go:36 +0x1f3
$ ./kwatch --help
INFO[0000] :tada: kwatch@dev just started!
WARN[0000] unable to load config file: open config.yaml: no such file or directory
panic: interface conversion: interface {} is nil, not map[string]interface {}
goroutine 1 [running]:
github.com/abahmed/kwatch/util.GetProviders()
/home/abuild/rpmbuild/BUILD/kwatch-0.6.1/util/util.go:121 +0x1316
main.main()
/home/abuild/rpmbuild/BUILD/kwatch-0.6.1/main.go:36 +0x1f3
To Reproduce
Build kwatchv0.6.1 built using go1.18.4. Execute kwatch binary in a directory with no config.yaml and none present in locations expected by kwatch
Expected behavior
Warning that a config file is needed (this is the case currently) followed by instructions on how to create a valid minimal one.
Better yet would be if kwatch had defaults (even if empty / no-op) and only required a config file be present for operations that connect to a Kubernetes instance. E.g. kwatch --help should execute with no configuration file found.
Actual behavior
Warning (expected) followed by panic (unexpected).
Version/Commit
kwatchv0.6.1 built using go1.18.4.
The text was updated successfully, but these errors were encountered:
Describe the bug
With
kwatch
v0.6.1
built usinggo1.18.4
, runningkwatch
with noconfig.yaml
in present directory, thekwatch
application panics after issuingWARN
about the missing config file:To Reproduce
Build
kwatch
v0.6.1
built usinggo1.18.4
. Executekwatch
binary in a directory with noconfig.yaml
and none present in locations expected bykwatch
Expected behavior
Warning that a config file is needed (this is the case currently) followed by instructions on how to create a valid minimal one.
Better yet would be if
kwatch
had defaults (even if empty / no-op) and only required a config file be present for operations that connect to a Kubernetes instance. E.g.kwatch --help
should execute with no configuration file found.Actual behavior
Warning (expected) followed by panic (unexpected).
Version/Commit
kwatch
v0.6.1
built usinggo1.18.4
.The text was updated successfully, but these errors were encountered: