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

Write diagnostics/error messages to stderr #272

Open
wants to merge 12 commits into
base: main
Choose a base branch
from

Conversation

wstephenson
Copy link

Like a good POSIX program

https://bugzilla.suse.com/show_bug.cgi?id=1233147 describes a complaint from Amazon that the error output on --json --status when the system registration is not found on SCC is not in json format. The underlying problem is that the error messages are all output on stdout. The user should check the return code of the process before interpreting stdout.

Nevertheless, it's good practice to put error messages and diagnostics on stdout.

I'm unsure whether the error output on Register (lines 290ff) and deRegister (233ff) with --json can be put on stderr, because the code is outputting the result of the API operation as a json object, and consumers may rely on this behaviour.

felixsch and others added 12 commits October 7, 2024 15:12
Add --set-labels to register command to set labels at registration time on SCC
This allows the internal configuration of SUSEConnect to understand on
which kind of server it's trying to connect. This is relevant in case we
want to perform some operations on SCC and some others on RMT.

Signed-off-by: Miquel Sabaté Solà <[email protected]>
Fixes bsc#1231185

Signed-off-by: Miquel Sabaté Solà <[email protected]>
Signed-off-by: Miquel Sabaté Solà <[email protected]>
…on-pubcloud

Do not generate docker configuration on pubcloud
The parsing of CLI arguments and how these are passed through the
internal SCC client, zypper and other tools is not ideal and needs to be
re-worked quite urgently. This is why other silly bugs have appeared in
which we are not passing the correct arguments to our backend code.

Until this rework is not done, let's simply apply this quick fix which
simply passes the `--gpg-auto-import-keys` flag to the zypper backend
when finding product packages.

Fixes bsc#1231328

Signed-off-by: Miquel Sabaté Solà <[email protected]>
Honor auto-import-gpg-keys flag on migration
@felixsch
Copy link
Contributor

Awesome Will, I take a look right away

@felixsch
Copy link
Contributor

I asked Robert and Ignaz if they see problems with this

@rjschwei
Copy link
Member

This can proceed from my POV, we have SUSE-Enceladus/cloud-regionsrv-client#223 to accommodate this change.

@mssola
Copy link
Contributor

mssola commented Nov 29, 2024

@wstephenson could you rebase this PR? Then I will review it right away as @rjschwei gave a green light to this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants