Skip to content

[Tool] FormatException in UTF-8 Process Output Decoding #188448

Closed

Description

@bkonyi

This issue is one of the top crashers identified in the Flutter 3.44.3 stable release.


The Flutter tool crashes with a FormatException: Missing extension byte when helper processes output non-UTF-8 bytes (e.g., on Windows/WSL under certain non-UTF-8 system locales).

Root Cause

In process.dart, ProcessUtils.stream uses the strict utf8LineDecoder (which has allowMalformed = false) to decode stdout/stderr. Any invalid byte sequence causes a fatal exception.

Proposed Solution

Update the process streaming mechanism to use the fault-tolerant utf8AllowMalformedLineDecoder instead, replacing invalid bytes with the Unicode replacement character (U+FFFD) to prevent crashes while preserving output.

Activity

  1. self-assigned this
    on Jun 23, 2026
  2. added
    P2Important issues not at the top of the work list
    team-toolOwned by Flutter Tool team
    triaged-toolTriaged by Flutter Tool team
    on Jun 23, 2026
  3. changed the title [-]FormatException in UTF-8 Process Output Decoding[/-] [+][Tool] FormatException in UTF-8 Process Output Decoding[/+] on Jun 23, 2026
  4. github-actions commented on Jul 14, 2026

    @github-actions

    This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

  5. locked as resolved and limited conversation to collaborators on Jul 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

P2Important issues not at the top of the work listteam-toolOwned by Flutter Tool teamtriaged-toolTriaged by Flutter Tool team

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions