- Notifications
You must be signed in to change notification settings - Fork 1.7k
Closed
Labels
P2A bug or feature request we're likely to work onA bug or feature request we're likely to work onarea-vmUse area-vm for VM related issues, including code coverage, and the AOT and JIT backends.Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends.type-bugIncorrect behavior (everything from a crash to more subtle misbehavior)Incorrect behavior (everything from a crash to more subtle misbehavior)
Description
I've been using the ZLib decoder as part of the dart-git project. With the 3.5.0 release decoding packfiles was now failing. Here is a simple test case -
import 'dart:convert'; import 'dart:io'; void main() { var inputBase64 = 'eJwzNOQCAAECAG0zeJwzMuICAAEHAG+gBHicMzQwMDMxUTDUy01h2HLP0j09OHF5Oa/mjhk6DtV8xzYtMITIG4Hkta8uWNlldoZj7YruBl/rB+7PVkV3AQC3+Bg/oAR4nDM0MDAzMVEw1MtNYdhyz9I9PThxeTmv5o4ZOg7VfMc2LTCEyBuB5Hl+f+ho+7Nypcz24DftJif8Tz/VmQ8AyhIZkDJ4nDPiAgAAcAA9oAR4nDM0MDAzMVEw1MtNYbjAMvFvXfS2XxpHxRfsNtqxlS14rq8hRN4IJM/z+0NH25+VK2W2B79pNznhf/qpznwACNQa3jJ4nDPkAgAAbgA8oAJ4nDM0MDAzMVEw1MtNYbjAMvFvXfS2XxpHxRfsNtqxlS14ri8As6AMrFeTuOFQovZrxXbBpf1PlYRP5yUE'; var inputBytes = base64.decode(inputBase64); zlib.decoder.convert(inputBytes); print('Everything worked'); }This code worked in dart 3.4.0 but throws the following exception with dart 3.5.0 -
Unhandled exception: FormatException: Filter error, bad data #0 _FilterImpl.processed (dart:io-patch/filter_patch.dart:13:71) #1 _FilterSink.addSlice (dart:io/data_transformer.dart:503:29) #2 _FilterSink.add (dart:io/data_transformer.dart:489:5) #3 ZLibDecoder.convert (dart:io/data_transformer.dart:363:9) #4 main (file:///Users/vishesh/src/gitjournal/dart-git/test.dart:8:16) #5 _delayEntrypointInvocation.<anonymous closure> (dart:isolate-patch/isolate_patch.dart:297:19) #6 _RawReceivePort._handleMessage (dart:isolate-patch/isolate_patch.dart:184:12) Here is the original test from which I created the smaller test case. Here is the Packfile zlib decompresssion code
I think this is caused by this change by @brianquinlan
Please could you provide a workaround or let me know if this can be fixed in time for the flutter Sept release. Accordingly, I'll roll back upgrading GitJournal to the latest flutter version.
Metadata
Metadata
Assignees
Labels
P2A bug or feature request we're likely to work onA bug or feature request we're likely to work onarea-vmUse area-vm for VM related issues, including code coverage, and the AOT and JIT backends.Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends.type-bugIncorrect behavior (everything from a crash to more subtle misbehavior)Incorrect behavior (everything from a crash to more subtle misbehavior)