Skip to content

Could not import module in VSCode when non 7-bit ascii characters in path #687

@tomgron

Description

@tomgron

Describe the bug
DevSkim not able to import modules with non 7-bit chars in user path

To Reproduce
Steps to reproduce the behavior:

  1. Create a user with ä ö å or some other non 7-bit ascii characters in user path

Expected behavior
Import of DevSkim would work in VSCode

Screenshots

Image

Versions(please complete the following information):

  • OS: Microsoft Windows 11 Enterprise 10.0.26100 10.0.26100.1
  • VSCode 👍
    Version: 1.100.2 (user setup)
    Commit: 848b80aeb52026648a8ff9f7c45a9b0a80641e2e
    Date: 2025-05-14T21:47:40.416Z
    Electron: 34.5.1
    ElectronBuildId: 11369351
    Chromium: 132.0.6834.210
    Node.js: 20.19.0
    V8: 13.2.152.41-electron.0
    OS: Windows_NT x64 10.0.26100
  • Devskim Version 1.0.54

Additional context

Log entry :

2025-05-22 09:59:04.284 [error] Error [ERR_MODULE_NOT_FOUND]: Cannot find module 'c:\Users*TommiGrönlund*.vscode\extensions\ms-cst-e.vscode-devskim-1.0.54\client\out\extension' imported from c:\Users*TommiGrönlund*\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js
Did you mean to import "file:///c:/Users/TommiGr%C3%B6nlund/.vscode/extensions/ms-cst-e.vscode-devskim-1.0.54/client/out/extension.js"?
at

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions