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

Improve log messages on failure #2061

Closed
jpkrohling opened this issue Oct 14, 2019 · 2 comments
Closed

Improve log messages on failure #2061

jpkrohling opened this issue Oct 14, 2019 · 2 comments
Assignees
Labels
triage/duplicate Indicates an issue is a duplicate of other open issue.

Comments

@jpkrohling
Copy link

When a failure during the generate openapi happens, it would be helpful to have a message that reflects the problem. I'm migrating an operator from 0.10.0 to 0.11.0, and I'm faced with this:

$ operator-sdk generate openapi 
INFO[0000] Running OpenAPI code-generation for Custom Resource group versions: [opentelemetry:[v1alpha1], ] 
Error: error generating CRD for Group opentelemetry Version v1alpha1 Kind OpenTelemetryCollector
Usage:
  operator-sdk generate openapi [flags]

Flags:
  -h, --help   help for openapi

Global Flags:
      --verbose   Enable verbose logging

I then decided to turn on the verbose logging, to figure out what's exactly going wrong:

$ operator-sdk generate openapi  --verbose
DEBU[0000] Debug logging is set                         
INFO[0000] Running OpenAPI code-generation for Custom Resource group versions: [opentelemetry:[v1alpha1], ] 
Error: error generating CRD for Group opentelemetry Version v1alpha1 Kind OpenTelemetryCollector
Usage:
  operator-sdk generate openapi [flags]

Flags:
  -h, --help   help for openapi

Global Flags:
      --verbose   Enable verbose logging

Operator SDK version:

$ operator-sdk version
operator-sdk version: "v0.11.0", commit: "39c65c36159a9c249e5f3c178205cc6e86c16f8d", go version: "go1.12.7 linux/amd64"
@camilamacedo86
Copy link
Contributor

Hi @jpkrohling,

it shows duplicated of #2042 because of this I am closing this one. However, please feel free to re-open if you fell that is required. My suggestion would be as described in this #2042 (comment).

I hope that it helps you.

@camilamacedo86 camilamacedo86 self-assigned this Oct 14, 2019
@camilamacedo86 camilamacedo86 added triage/support Indicates an issue that is a support question. triage/duplicate Indicates an issue is a duplicate of other open issue. and removed triage/support Indicates an issue that is a support question. labels Oct 14, 2019
@jpkrohling
Copy link
Author

Thanks @camilamacedo86 for the quick response and for pointing me to the right direction.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
triage/duplicate Indicates an issue is a duplicate of other open issue.
Projects
None yet
Development

No branches or pull requests

2 participants