Skip to content

Visual studio fails to format with error InvalidUtf8 #533

@bpeake13

Description

@bpeake13

On windows when trying to format a file I get the following log

[Info  - 1:01:28 AM] [info-main] zls initialized
[Info  - 1:01:28 AM] [info-main] ClientCapabilities{ .supports_snippets = true, .supports_semantic_tokens = true, .hover_supports_md = true, .completion_doc_supports_md = true, .label_details_support = true, .supports_configuration = true }
[Info  - 1:01:28 AM] [info-main] Using offset encoding: utf16
[Info  - 1:01:28 AM] [info-main] Requesting configuration!
[Info  - 1:01:28 AM] [info-doc_store] builtin config not found, falling back to default: <file>
[Info  - 1:01:34 AM] [info-doc_store] builtin config not found, falling back to default: <file>
[Warn  - 1:01:34 AM] [warn-doc_store] Failed to load packages of build file <file>
[Info  - 1:01:34 AM] [info-main] Setting configuration...
[Warn  - 1:01:52 AM] [warn-main] Failed to spawn zig fmt process, error: error.InvalidUtf8

It seems like it is using utf16 for some reason, but i dont see a config related to this

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions