Skip to content

Missing extension byte error on flutter pub get, related to git dependency #4787

@ysalmon

Description

@ysalmon

Not sure if this is relevant to dart or flutter (I am new to all this), but the error message I get does say to report here.

I am trying to build this app (not mine) : https://codeberg.org/epinez/Energize

I set up the dart/flutter framework and successfully built the Hello World app that comes with the relevant Codium extension.

The version is :

Flutter 3.41.2 • channel stable • https://github.com/flutter/flutter.git
Framework • revision 90673a4eef (il y a 11 jours) • 2026-02-18 13:54:59 -0800
Engine • hash d96704abcce17ff165bbef9d77123407ef961017 (revision 6c0baaebf7) (10 days ago) • 2026-02-18 19:22:23.000Z
Tools • Dart 3.11.0 • DevTools 2.54.1

Now I ran flutter pub get as per the Energize app build instructions.

This fails with the following message.

Resolving dependencies... (1.5s)
Missing extension byte (at offset 18)
dart:isolate  _RawReceivePort._handleMessage
This is an unexpected error. The full log and other details are collected in:

    /home/yann/.pub-cache/log/pub_log.txt

Consider creating an issue on https://github.com/dart-lang/pub/issues/new
and attaching the relevant parts of that log file.
Failed to update packages.

The log file is very long, and ends with

IO  : Created temp directory /home/yann/.pub-cache/_temp/dirEMXJRT
IO  : Spawning "git --version" in /home/yann/Documents/Programmes/Energize/.
IO  : Finished git. Exit code 0.
    | stdout:
    | | git version 2.43.0
    | | 
    | Nothing output on stderr.
FINE: Determined git command git.
IO  : Spawning "git clone --mirror https://codeberg.org/epinez/qr_code_scanner_revived /home/yann/.pub-cache/_temp/dirEMXJRT" in /home/yann/Documents/Programmes/Energize/.
IO  : Deleting directory /home/yann/.pub-cache/_temp/dirEMXJRT.
SLVR: Version solving took 0:00:02.945601 seconds.
    | Tried 1 solutions.
FINE: Resolving dependencies finished (2.9s).
ERR : Missing extension byte (at offset 18)
FINE: Exception type: FormatException
ERR : dart:isolate  _RawReceivePort._handleMessage
ERR : This is an unexpected error. The full log and other details are collected in:
    | 
    |     /home/yann/.pub-cache/log/pub_log.txt
    | 
    | Consider creating an issue on https://github.com/dart-lang/pub/issues/new
    | and attaching the relevant parts of that log file.

I am confused that a git repo is cloned then immediately deleted, without seemingly doing anything with it. So I tried to download the repo manually and changed the dependency line in the pubspec.yaml file to refer to the downloaded files (ie. path dependency).

With this change, I am able to get the dependencies, build and run the app.

Metadata

Metadata

Assignees

No one assigned

    Labels

    type-bugIncorrect behavior (everything from a crash to more subtle misbehavior)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions