Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When a ~/.spin/config file has incorrect formatting, the error message provided is confusing #75

Open
aaronaddleman opened this issue Apr 18, 2023 · 0 comments
Labels
DevX Developer Experience related enhancement New feature or request

Comments

@aaronaddleman
Copy link

aaronaddleman commented Apr 18, 2023

Summary

When having a mis-configured file at ~/.spin/config the error message provided is missing information about where to fix this issue.

Motivation

I was moving really fast and dumped in a ~/.spin/config file that was not formatted correctly. When I moved on to use the shore CLI it was then I found out about this issue and I did not know what was the context for this error. Having a clear identification of where the issue is occurring would help.

The expected outcome would have the filename of what is being parsed to set the context of where the issue is located.

Describe alternatives you've considered

Have not considered any alternatives.

Additional context

Here is an example of the ~/.spin/config I used:

auth:
  enabled: true
  ignoreCertErrors: true
  x509:
    certPath: ~/.config/spinnaker/id_spin.cert
    keyPath: ~/.config/spinnaker/id_spin.key
gate:
  endpoint: [https://hostname.org:442](https://hostname.org:443/)

I got the following output:

➜ shore save
WARN[0000] Save pipeline returned an error: error converting YAML to JSON: yaml: line 7: did not find expected key
error converting YAML to JSON: yaml: line 7: did not find expected key
@dkirillov dkirillov added enhancement New feature or request DevX Developer Experience related labels Apr 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
DevX Developer Experience related enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants