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
Fixes from other extensions #103
Conversation
942918e
to
9625f93
Compare
return pathlib.Path(file_path1) == pathlib.Path(file_path2) | ||
|
||
|
||
def normalize_path(file_path: str) -> str: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
how did this function before without the path normalization?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Normally we don't need path normalization. It is needed in windows if user launches VS Code using case different from the one used in the workspace name. This bug is not hit commonly. But we need to propagate this fix to all extensions in python extension set.
def is_stdlib_file(file_path) -> bool: | ||
"""Return True if the file belongs to standard library.""" | ||
return os.path.normcase(os.path.normpath(file_path)).startswith(_site_paths) | ||
def is_stdlib_file(file_path: str) -> bool: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this the standard library for autopep8 specifically?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nope, this is general standard library
No description provided.