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

[v9] db access denied error message improvement #17857

Conversation

GavinFrazar
Copy link
Contributor

Backports #16228 to branch/v9

GavinFrazar and others added 2 commits October 26, 2022 12:40
* Fix matchers not being printed in err message

* Add helpful message when access is denied to db connect

* Add test for converting command errors

* Simplify error message when access to db is denied

* Update lib/client/db/dbcmd/dbcmd_test.go

Co-authored-by: Marek Smoliński <[email protected]>

* Remove unnecessary cmd.Run in test

* Fix import order

* Add full error to message

* Fix formatting of github suggestion

* Add troubleshooting link

* Update troubleshooting link to use subheading

Co-authored-by: Marek Smoliński <[email protected]>
Comment on lines +628 to +633
c.exe = &fakeExec{
commandPathBehavior: forceBasePath,
execOutput: map[string][]byte{
tt.wantBin: tt.stderr,
},
}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had to update this test to use c.exe instead of c.options.exe since exe was moved after v9 and not backported, but it does not affect this PR.

@GavinFrazar GavinFrazar enabled auto-merge (squash) October 27, 2022 22:15
@GavinFrazar GavinFrazar merged commit c193cf5 into branch/v9 Oct 27, 2022
@GavinFrazar GavinFrazar deleted the gavinfrazar/v9_db_access_denied_error_message_improvement branch November 8, 2022 21:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants