Issue I’m having problems to build a Flutter app in an Android device. The error bellow happens whenever I try to override current version, downloaded from Google Play Store, with new debug version. But it is very hard to find
Continue readingTag: dart-isolates
Access variables in external scope when using isolation in Dart
Issue In Isolates, I can refer to a local variable from an outer scope or a field variable of a class without passing it as a separate message. Is this implicitly copying the values into the new isolation’s memory area?
Continue readingHow to write and read data anywhere by shared_preferences on Flutter 3.7 background isolates?
Issue On Flutter 3.7 platform channels can run on any isolate. So I tried this sample, import ‘package:flutter/services.dart’; import ‘package:shared_preferences/shared_preferences.dart’; void main() { // Identify the root isolate to pass to the background isolate. // (API introduced in Flutter 3.7)
Continue readingFlutter ReceiverPort don't listen
Issue I’m using the flutter_downloader package to download files with my app. The progress notification is working nicely. but my ReceivePort is not listening to the progress. final ReceivePort port = ReceivePort(); @override void initState() { super.initState(); IsolateNameServer.registerPortWithName( port.sendPort, ‘downloader_sendport’);
Continue readingStream of millions of objects takes too much memory
Issue I’m generating a load of coordinates (made of 3 numbers) within a geographical area. However, using Streams (which should be much more efficient than Lists), fills up the app’s memory very quickly, as can be seen in this screenshot
Continue readingThe compute method is not executed completely when I use `List.generate` inside of it but when I use forloop the compute method is executed completely
Issue The below program is for understanding isolates in dart. The compute method is passed to the spawned isolate. Inside of compute method summation is performed but when List.generate is used the compute function doesn’t finish the execution because the
Continue readingWhy the exitPort hander `if` statement isn't called at the very end
Issue In the below program the printTest method must be called at the end after all Isolates have finished but why is printTest method called before the isolates have finished. This condition checks if (–liveIsolates == 0) weather isolates have
Continue readingFlutter – ReceiverPort doesn't listen data
Issue I’m using flutter_downloader package and I have to get the data in listen method, but it doesn’t work. I don’t receive anything. I read that the issue could be because in send method I have to paste only primitive
Continue readingCan a closure be sent to a SendPort
Issue I’m working on implementation two-isolates app. In this scope I’m exploring a possibility to send a closure via SendPort. The documentation says that in case isolates share same code anything can be sent with some exceptions. But when I
Continue readingdart Isolate listen don't triggered (or work)
Issue My class: import ‘dart:isolate’; import ‘dart:ui’; import ‘package:flutter_downloader/flutter_downloader.dart’; class SettingsPage extends StatefulWidget with WidgetsBindingObserver { SettingsPage({Key? key}) : super(key: key); @override State<SettingsPage> createState() => _SettingsPageState(); } class _SettingsPageState extends State<SettingsPage> { final ReceivePort _port = ReceivePort(); int uploadProgress =
Continue reading