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

language server: pass correct non-POSIX paths to detect_crate_for #4388

Merged
merged 4 commits into from
Nov 15, 2023

Conversation

dedushky
Copy link
Contributor

@dedushky dedushky commented Nov 9, 2023

Uri to path conversion is not performed correctly on Windows because file paths are not POSIX style. That's why detect_crate_for works incorrectly:

Error loading file /d%3A/projects/cairo...


This change is Reviewable

Copy link
Collaborator

@orizi orizi left a comment

Choose a reason for hiding this comment

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

Reviewed all commit messages.
Reviewable status: 0 of 1 files reviewed, 1 unresolved discussion (waiting on @dedushky)


crates/cairo-lang-language-server/src/lib.rs line 373 at r1 (raw file):

            if let FileLongId::OnDisk(file_path) = file {
				self.detect_crate_for(&mut db, file_path).await;
            }

run ./scripts/cairo_fmt.sh
use spaces.

Code quote:

            if let FileLongId::OnDisk(file_path) = file {
				self.detect_crate_for(&mut db, file_path).await;
            }

@dedushky
Copy link
Contributor Author

formatted with fmt - tabs are replaced with spaces

Copy link
Collaborator

@orizi orizi left a comment

Choose a reason for hiding this comment

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

:lgtm:

Reviewed 1 of 1 files at r2, all commit messages.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @dedushky)

Copy link
Collaborator

@orizi orizi left a comment

Choose a reason for hiding this comment

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

Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @gilbens-starkware)

a discussion (no related file):
Add @gilbens-starkware for 2nd eye.


Copy link
Collaborator

@orizi orizi left a comment

Choose a reason for hiding this comment

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

Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @dedushky and @gilbens-starkware)

a discussion (no related file):
fix clippy warning.


@dedushky
Copy link
Contributor Author

clippy warning fixed

Copy link
Collaborator

@orizi orizi left a comment

Choose a reason for hiding this comment

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

Reviewed 1 of 1 files at r3, all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @dedushky and @gilbens-starkware)

Copy link
Collaborator

@orizi orizi left a comment

Choose a reason for hiding this comment

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

Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @gilbens-starkware)

Copy link
Contributor

@gilbens-starkware gilbens-starkware left a comment

Choose a reason for hiding this comment

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

:lgtm:

Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @dedushky)

@gilbens-starkware gilbens-starkware added this pull request to the merge queue Nov 15, 2023
Merged via the queue into starkware-libs:main with commit 45f9bc8 Nov 15, 2023
orizi added a commit that referenced this pull request Dec 28, 2023
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.

3 participants