Skip to content

fix: resolve 'No module named pwd' error on Windows #70

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

Merged

Conversation

IDontHaveBrain
Copy link
Contributor

When using the TypeScriptLanguageServer on Windows environments, users encounter a No module named 'pwd' error.
This occurs because the pwd module is only available on Unix-like systems but was being imported unconditionally.

This PR adds a conditional import for the pwd module that only executes on non-Windows platforms.

@IDontHaveBrain
Copy link
Contributor Author

@microsoft-github-policy-service agree

@LakshyAAAgrawal
Copy link
Collaborator

Great catch, and thanks a lot for the PR!

@LakshyAAAgrawalP LakshyAAAgrawalP merged commit 627841c into microsoft:main Mar 3, 2025
4 checks passed
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