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

[v13] tsh: skip invalid profiles instead of failing #38512

Merged
merged 1 commit into from
Feb 21, 2024

Conversation

zmb3
Copy link
Collaborator

@zmb3 zmb3 commented Feb 21, 2024

Backport #38330 to branch/v13

changelog: Ensured that tsh continues to function if one of its profiles is invalid.

The tsh status command attempts to decode one profile per YAML
file in $TSH_HOME. If an error is encountered along the way,
the entire command fails and tsh does not display information
about any profiles.

An especially confusing corner case is when a user mistakenly
places tsh's configuration at $TSH_HOME/config.yaml instead of
$TSH_HOME/config/config.yaml. In this case, the config file is
assumed to be a profile and the user is presentedc with a
confusing error message.

Fix this by skipping over profiles that fail to load but continuing
to report on the ones that load successfully.

Closes #38302
@zmb3 zmb3 added this pull request to the merge queue Feb 21, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Feb 21, 2024
@zmb3 zmb3 added this pull request to the merge queue Feb 21, 2024
Merged via the queue into branch/v13 with commit 938ff5a Feb 21, 2024
24 checks passed
@zmb3 zmb3 deleted the bot/backport-38330-branch/v13 branch February 21, 2024 22:07
@camscale camscale mentioned this pull request Feb 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants