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

WIP: Improve error message in the case where project is not initialized #1394

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/options.rs
Original file line number Diff line number Diff line change
Expand Up @@ -901,9 +901,9 @@ impl Options {

if e.is::<ClientNoCredentialsError>() {
let project_dir = get_project_path(None, true).await?;
let message = if project_dir.is_some() {
let message = if let Some(project_dir) = project_dir {
format!(
"project is not initialized and no connection options \
"project is not initialized at {project_dir:?} and no connection options \
Copy link
Member

Choose a reason for hiding this comment

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

Perhaps we need to clarify that it's not initialized in the specific directory or in any of the parent directories

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Agreed -- although I think I should close this PR in favour of the more verbose project init message discussed on Slack.

are specified: {errors:?}"
)
} else {
Expand Down
Loading