text:
Firestore - where array contains

Is there a way to access the API for Firestore instances which query a collection like the JS implementation : array-contains?
https://firebase.google.com/docs/firestore/query-data/queries#array_membership
@Hixie @sethladd  @xster -> thoughts?

Actually, I don't need this... found a way around it. Cheers!

I really need this feature too. It will allow for a much better design and might even save money due to less document reads.
In general it would be great to support all firestore features as soon as they are available to avoid that flutter developers feel like second class citizens of firebase.

Hi @Daibaku0615 indentation is important in your pubspec.yaml file - that issue looks like an indentation problem where pub can't parse the options properly. Make sure its indented as follows:
dependencies:                                                 # 0 spaces
  flutter:                                                    # 2 spaces
    sdk: flutter                                              # 4 spaces
  cloud_firestore:                                            # 2 spaces
    git:                                                      # 4 spaces
      url: git://github.com/buntagonalprism/plugins.git       # 6 spaces
      path: packages/cloud_firestore                          # 6 spaces
      ref: firestore_array_contains                           # 6 spaces

@michael87 After I ran the following to update the firestore pod I was able to successfully build and deploy to iOS simulator, and verify that array-contains functionality is also working as expected on iOS in my fork.
cd ios
pod update Firebase/Firestore

While this manual update worked, I feel it would be better if the cloud_firestore plugin specified the minimum Firebase/Firestore pod version it required so that other people don't need to run this manual update. But none of the other podspec files among the other Flutter plugins specify exact versions for their pod dependencies as far as I can tell, so I'm not sure what the best approach is.

Sorry for late response.
It worked thank you so much!

Looks like https://github.com/flutter/plugins/pull/760 is supposed to fix that.

@zoechi yes. Also PR is merged and released as 0.8.0.

Looks like this is now a non-issue so I'm closing this... issue.

@pulyaevskiy I was hoping an official release would happen soon! Now, when using ArrayContains it's returning all documents in the collection rather than just the ones that match the ArrayContains query.
await _db.collection('collection').limit(limit).where('arrayField',
				arrayContains: string).getDocuments().then((result){
//do stuff with the result
}

I've created a composite index but that doesn't help me. I'm doing something wrong.

@adriancmurray For me it would be hard to tell what's wrong in your case.
I've noticed that (at least on iOS) Firestore SDK is kinda unstable in some cases. Like I don't always get events for local changes. Or when I delete a document manually in Firebase Console I'd still get it in query snapshots, which seems like SDK cache is not invalidated for deletes (the only solution I found for this is to uninstall the app from Simulator, restart it and run the app again).
There is also the whole thing about queries and security rules which if your query even potentially can include a document which it has no access to it will not be executed and will fail. Though if you are listening on snapshots stream you won't see any errors and it'd simply return empty snapshots.
I've just tested arrayContains again in my app and it does seem to work as expected for my query:
var query = firestore
        .collection(path)
        .where('things', arrayContains: thingId)
        .where('serverTimestamp', isGreaterThan: lastUpdatedAt)
        .orderBy('serverTimestamp', descending: true);

I'd probably recommend to clear all caches (including flutter clean), make sure that your Firebase/Firestore pod is at least 5.5.0 or later, restart simulator and try again. Check security rules as well (though if it returns everything it seems unlikely because of the rules).

@pulyaevskiy the Firebase/Firestore pod update fixed it for me. I forgot that was required. Thank you very much for your help!

Is something like this possible yet? https://stackoverflow.com/questions/52905836/how-to-query-nested-objects-in-firestore/52906042#52906042

@HerrNiklasRaab arrayContains is supported, though you’ll have to test it yourself if it works with complex objects.

I see until now there is no way to filter elements using Firestore when the condition is "Filter elements where it starts with ..."

Is it possible to somehow filter the query by arrayNotContains? I can not find something similar in the documentation.

@adriancmurray
This issue has been moved to https://github.com/FirebaseExtended/flutterfire/issues/714. Any further collaboration will be done there.

@kroikie thanks, though this is a non-issue now. The plug-in has been updated to support this type of query.

Is it possible to somehow filter the query by arrayNotContains? I can not find something similar in the documentation.

I'm looking for a thing like that. Please take me informed if you find a solution.

Is it possible to somehow filter the query by arrayNotContains? I can not find something similar in the documentation.

I'm looking for a thing like that. Please take me informed if you find a solution.

Unfortunately, did not find :(

Is it possible to somehow filter the query by arrayNotContains? I can not find something similar in the documentation.

I'm looking for a thing like that. Please take me informed if you find a solution.

Unfortunately, did not find :(
The only way now, I guess, its query all items and check if the array contains specific elements on a client. Or as an alternative create cloud function if it's possible.

That's what I did. But I wonder what will happen if there plenty things to get from the server, it will take long time to executing. But I didn't use cloud function, maybe it will be the best way. Thanks a lot.

authors: BerndWessels Daibaku0615 FQuouhadiho Frozmen GRTO HerrNiklasRaab adriancmurray buntagonalprism kroikie pulyaevskiy zoechi


text:
Hot reloading a page with streambuilder bugs out

I have a Streambuilder listening to a behaviourSubject broadcastStream, but whenever I Hot Reload or Hot Restart the code for any small change, The streambuilder stops seing what's on the tip of the stream, forcing me to re-do what I originally did to fill the stream

Unfortunately this is not enough information to diagnose the problem.
Please add the output of flutter doctor -v
and the code for a working minimal reproduction (main.dart).

Without additional information, we are unfortunately not sure how to resolve this issue. We are therefore reluctantly going to close this bug for now. Please don't hesitate to comment on the bug if you have any more information for us; we will reopen it right away!
Thanks for your contribution.

I'm actually experiencing this problem.
When the app is hot reloaded, the streambuilder stream gets resetted and set to the initialData. Meaning no state is preserved on hot reload.
Happens on every single streambuilder I have. For example
  Widget _buildUserAvatar(UserService userService) {
    return StreamBuilder(
      stream: userService.loggedInUserChange,
      initialData: null,
      builder: (context, AsyncSnapshot<User> snapshot) {
        var user = snapshot.data;

        var avatar;

        if (user == null) {
          avatar = AssetImage('assets/images/avatar.png');
        } else {
          avatar = NetworkImage(user.profile.avatar);
        }

        return Container(
          child: null,
          decoration: BoxDecoration(
              image: DecorationImage(image: avatar, fit: BoxFit.cover)),
        );
      },
    );
  }

Loads well when the app is opened, once its hot reloaded the initialData is set to null and therefore state lost.
Here's the doctor output
[✓] Flutter (Channel dev, v0.10.0, on Mac OS X 10.14 18A391, locale en-NL)
    • Flutter version 0.10.0 at /Users/joelhernandez/Documents/code/flutter
    • Framework revision d954ae6850 (4 weeks ago), 2018-10-09 16:21:06 -0400
    • Engine revision bf377896ff
    • Dart version 2.1.0-dev.6.0.flutter-a50dfd6698

[✓] Android toolchain - develop for Android devices (Android SDK 28.0.2)
    • Android SDK at /Users/joelhernandez/Library/Android/sdk
    • Android NDK location not configured (optional; useful for native profiling support)
    • Platform android-28, build-tools 28.0.2
    • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1024-b01)
    • All Android licenses accepted.

[✓] iOS toolchain - develop for iOS devices (Xcode 10.1)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 10.1, Build version 10B61
    • ios-deploy 1.9.2
    • CocoaPods version 1.5.3

[✓] Android Studio (version 3.1)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin version 27.1.1
    • Dart plugin version 173.4700
    • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1024-b01)

[✓] IntelliJ IDEA Ultimate Edition (version 2018.2.4)
    • IntelliJ at /Applications/IntelliJ IDEA.app
    • Flutter plugin version 29.1.3
    • Dart plugin version 182.4999

[!] VS Code (version 1.25.1)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension not installed; install from
      https://marketplace.visualstudio.com/items?itemName=Dart-Code.flutter

[✓] Connected device (1 available)
    • iPhone XR • FA438BBC-174B-4CD2-88A1-781FB12304BC • ios • iOS 12.1 (simulator)

The state is preserved but also build() is run again and this causes StreamBuilder to re-subscribe.
You probably don't want to use StreamBuilder and instead subscribe imperatively to the stream yourself in initState

I experienced the issue too. It's not the end of the world, but it's kinda annoying that we have to avoid StreamBuilders in the upper hierarchy of our apps to keep hot-reload happy. At the same time I understand there are benefits to maintaining a disciplined StreamBuilder api.

If the stream is the same it shouldn't be rebuilt (see https://github.com/flutter/flutter/blob/aae968cd455cd6a4fbd3861afe0f5c55c75e6e2c/packages/flutter/lib/src/widgets/async.dart#L115). It sounds like you are creating a new stream on build accidentally.

Ah, good to know! Working through this saved me a bug. So, for stream-heavy apps that use bloc-style services injected via inherited widget, a couple of implications are:

Bloc methods that return streams should return the same stream instance if they want to trouble themselves with avoiding a connecting state on hot reload. (kind of standard behavior for app-level streams like 'user' or 'user-email')
Take care not to instantiate Bloc-like services in a build method b.c. Bloc instance change -> stream instance change (actually this is general good advice for Flutter rookies like me who care about managing a handful of high-level app service instances)

Ah, good to know! Working through this saved me a bug. So, for stream-heavy apps that use bloc-style services injected via inherited widget, a couple of implications are:

Bloc methods that return streams should return the same stream instance if they want to trouble themselves with avoiding a connecting state on hot reload. (kind of standard behavior for app-level streams like 'user' or 'user-email')
Take care not to instantiate Bloc-like services in a build method b.c. Bloc instance change -> stream instance change (actually this is general good advice for Flutter rookies like me who care about managing a handful of high-level app service instances)

I'm having the same issue, i set the user id from before i get to the home page which has 4 pages into it including a profile page and in the profile page i need the user id .. at first i can retrieve it from the bloc, but when i hot reload the stream returns null..
Do you have any idea how i can fix my issue..
Let me give you a clear picture first..
There's an
== InitializationPage in it i set the: BlocProvider<userInfoBloc>(bloc: UserInfoBloc, child ConnectPage).
==ConnectPage is a stateless widget in the build method i call
UserInfoBloc userInformationBloc = BlocProvider.of<UserInfoBloc>(context);
FirebaseAuth.instance.currentUser().then((currentUser){
      userInformationBloc.onUidChanged(currentUser.uid);
      Future.delayed(const Duration(milliseconds: 1000), () {
        _redirectToPage(context, HomePage());
      });
    });

==HomePage() has a NavigationTabBar with 4 Pages including ProfilePage()
==ProfilePage is a statefull widget, i've tried to call the bloc from the build method and from initState() but each time after reload it Uid from bloc returns null;
Any help is appreciated, thanks.

@zoechi Hi,
You mentioned "...subscribe imperatively to the stream yourself in initState",
Can you please provide a rough example of this?
Rolling my own Providers and Blocs (best way to do it, not using provider or builtValue), say for an AuthBloc, has an accounts stream accessed via bloc.accounts, the StreamBuilder stream prop  is bloc.accounts. The reload is re/unsubscribing from the stream and the StreamBuilder has no data. How then could  this stream data be set to the Screens State?
Thanks

Create stream outside widget, keep it as a singleton object, thus StreamBuilder work as usual

source: gharchive/issue

authors: Y-ndm d-silveira hientrung jonahwilliams lifenautjoe richehmer sashvoncurtis zoechi

repo: flutter/flutter

license_type: permissive

license_source: github-api


text:
Text is greyed out after waking up

Steps to Reproduce
I woke up my phone in a minute after it went into sleep. This is what I see both on android and iOS

Running app in development mode
Logs
flutter run --verbose
No logs after locking(sleeping) and unlocking(waking) the device
flutter analyze
Analyzing ideaspace...

   info - The value of the field '_videoThumbnail' isn't used - lib\screens\interaction\chat_window.dart:59:10 - unused_field
   info - This class inherits from a class marked as @immutable, and therefore should be immutable (all instance fields must be final) -
          lib\widgets\adhararichtext.dart:8:7 - must_be_immutable
   info - This class inherits from a class marked as @immutable, and therefore should be immutable (all instance fields must be final) -
          lib\widgets\adharatextfield_tags.dart:7:7 - must_be_immutable
   info - This class inherits from a class marked as @immutable, and therefore should be immutable (all instance fields must be final) -
          lib\widgets\filterchips.dart:6:7 - must_be_immutable

4 issues found. (ran in 63.3s)

flutter doctor -v
[√] Flutter (Channel beta, v0.11.3, on Microsoft Windows [Version 10.0.17134.407], locale en-IN)
    • Flutter version 0.11.3 at C:\flutter
    • Framework revision 72bf075e8d (11 days ago), 2018-11-09 20:36:17 -0800
    • Engine revision 5646e86a6f
    • Dart version 2.1.0 (build 2.1.0-dev.9.3 9c07fb64c4)

[√] Android toolchain - develop for Android devices (Android SDK 28.0.3)
    • Android SDK at C:\Users\Rohit\AppData\Local\Android\sdk
    • Android NDK location not configured (optional; useful for native profiling support)
    • Platform android-28, build-tools 28.0.3
    • ANDROID_HOME = C:\Users\Rohit\AppData\Local\Android\sdk
    • Java binary at: C:\Program Files\Android\Android Studio\jre\bin\java
    • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1136-b06)
    • All Android licenses accepted.

[√] Android Studio (version 3.2)
    • Android Studio at C:\Program Files\Android\Android Studio
    • Flutter plugin version 30.0.1
    • Dart plugin version 181.5656
    • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1136-b06)

[√] Connected device (1 available)
    • ONEPLUS A5010 • f0f79579 • android-arm64 • Android 8.1.0 (API 27)

• No issues found!

This is what I see both on android and iOS

What do you expect to see instead?

The text is greyed out in bottom navigation bar and other actionable areas where the like and comment buttons are present

@tiholic it would be more obvious if you'd add a screenshot before you switch the app in the background (before/after compairson)

This definitely looks like #24216 to me. Can you please check if it has been fixed in the master branch?

@liyuqian yes, looks very similar and It's already fixed on dev branch also  (v0.11.9)

@tiholic try on dev or master channel   >= v0.11.9

authors: diegoveloper liyuqian tiholic zoechi


text:
Requesting Feature: Add DoubleTapDetails params in GestureDoubleTapCallback like GestureTapDownCallback

for now, if a Gesture was detected as a DoubleTap, the previous TapDown event will not trigger onTapDown. I think it is reasonable.
BUT here is the problem: I want to add a icon and play animations on the double-tap point of the screen but GestureDoubleTapCallback doesn't provide any tap information and I also can not retrieve the TapDown point  since onTapDown is not fired.

Looks a bit like #20000


text:
Failed assertion when Scaffold is disposed with open drawer

Here's a simple repro (press the button in the drawer).
import 'package:flutter/material.dart';

void main() {
  runApp(MyApp());
}

class MyApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Flutter Demo',
      theme: ThemeData(
        primarySwatch: Colors.blue,
      ),
      home: MyHomePage(title: 'Flutter Demo Home Page'),
    );
  }
}

class MyHomePage extends StatefulWidget {
  final String title;

  const MyHomePage({Key key, this.title}) : super(key: key);

  @override
  _MyHomePageState createState() => _MyHomePageState();
}

class _MyHomePageState extends State<MyHomePage> {
  var _displayScaffold = true;

  @override
  Widget build(BuildContext context) {
    if (!_displayScaffold) return Container();
    return MyScaffold(
      onDrawerButtonPressed: () {
        setState(() {
          _displayScaffold = false;
        });
      },
    );
  }
}

class MyScaffold extends StatelessWidget {
  final VoidCallback onDrawerButtonPressed;

  const MyScaffold({Key key, this.onDrawerButtonPressed}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(),
      drawer: Drawer(
        child: RaisedButton(
          onPressed: onDrawerButtonPressed,
          child: Text('PRESS ME'),
        ),
      ),
    );
  }
}

I/flutter (24703): ══╡ EXCEPTION CAUGHT BY WIDGETS LIBRARY ╞═══════════════════════════════════════════════════════════
I/flutter (24703): The following assertion was thrown while finalizing the widget tree:
I/flutter (24703): setState() or markNeedsBuild() called when widget tree was locked.
I/flutter (24703): This _ModalScope<dynamic> widget cannot be marked as needing to build because the framework is
I/flutter (24703): locked.
I/flutter (24703): The widget on which setState() or markNeedsBuild() was called was:
I/flutter (24703):   _ModalScope<dynamic>-[LabeledGlobalKey<_ModalScopeState<dynamic>>#994b6](state:
I/flutter (24703):   _ModalScopeState<dynamic>#e7d70)
I/flutter (24703):
I/flutter (24703): When the exception was thrown, this was the stack:
I/flutter (24703): #0      Element.markNeedsBuild.<anonymous closure> (package:flutter/src/widgets/framework.dart:3502:9)
I/flutter (24703): #1      Element.markNeedsBuild (package:flutter/src/widgets/framework.dart:3511:6)
I/flutter (24703): #2      State.setState (package:flutter/src/widgets/framework.dart:1146:14)
I/flutter (24703): #3      _ModalScopeState._routeSetState (package:flutter/src/widgets/routes.dart:584:5)
I/flutter (24703): #4      ModalRoute.setState (package:flutter/src/widgets/routes.dart:683:30)
I/flutter (24703): #5      ModalRoute.changedInternalState (package:flutter/src/widgets/routes.dart:1154:5)
I/flutter (24703): #6      _ModalRoute&TransitionRoute&LocalHistoryRoute.removeLocalHistoryEntry (package:flutter/src/widgets/routes.dart:468:7)
I/flutter (24703): #7      LocalHistoryEntry.remove (package:flutter/src/widgets/routes.dart:299:12)
I/flutter (24703): #8      DrawerControllerState.dispose (package:flutter/src/material/drawer.dart:211:20)
I/flutter (24703): #9      StatefulElement.unmount (package:flutter/src/widgets/framework.dart:3878:12)
I/flutter (24703): #10     _InactiveElements._unmount (package:flutter/src/widgets/framework.dart:1709:13)
I/flutter (24703): #11     _InactiveElements._unmount.<anonymous closure> (package:flutter/src/widgets/framework.dart:1707:7)
I/flutter (24703): #12     ComponentElement.visitChildren (package:flutter/src/widgets/framework.dart:3733:14)
I/flutter (24703): #13     _InactiveElements._unmount (package:flutter/src/widgets/framework.dart:1705:13)
I/flutter (24703): #14     _InactiveElements._unmount.<anonymous closure> (package:flutter/src/widgets/framework.dart:1707:7)
I/flutter (24703): #15     ComponentElement.visitChildren (package:flutter/src/widgets/framework.dart:3733:14)
I/flutter (24703): #16     _InactiveElements._unmount (package:flutter/src/widgets/framework.dart:1705:13)
I/flutter (24703): #17     _InactiveElements._unmount.<anonymous closure> (package:flutter/src/widgets/framework.dart:1707:7)
I/flutter (24703): #18     MultiChildRenderObjectElement.visitChildren (package:flutter/src/widgets/framework.dart:4926:16)
I/flutter (24703): #19     _InactiveElements._unmount (package:flutter/src/widgets/framework.dart:1705:13)
I/flutter (24703): #20     _InactiveElements._unmount.<anonymous closure> (package:flutter/src/widgets/framework.dart:1707:7)
I/flutter (24703): #21     ComponentElement.visitChildren (package:flutter/src/widgets/framework.dart:3733:14)
I/flutter (24703): #22     _InactiveElements._unmount (package:flutter/src/widgets/framework.dart:1705:13)
I/flutter (24703): #23     _InactiveElements._unmount.<anonymous closure> (package:flutter/src/widgets/framework.dart:1707:7)
I/flutter (24703): #24     ComponentElement.visitChildren (package:flutter/src/widgets/framework.dart:3733:14)
I/flutter (24703): #25     _InactiveElements._unmount (package:flutter/src/widgets/framework.dart:1705:13)
I/flutter (24703): #26     _InactiveElements._unmount.<anonymous closure> (package:flutter/src/widgets/framework.dart:1707:7)
I/flutter (24703): #27     ComponentElement.visitChildren (package:flutter/src/widgets/framework.dart:3733:14)
I/flutter (24703): #28     _InactiveElements._unmount (package:flutter/src/widgets/framework.dart:1705:13)
I/flutter (24703): #29     _InactiveElements._unmount.<anonymous closure> (package:flutter/src/widgets/framework.dart:1707:7)
I/flutter (24703): #30     SingleChildRenderObjectElement.visitChildren (package:flutter/src/widgets/framework.dart:4826:14)
I/flutter (24703): #31     _InactiveElements._unmount (package:flutter/src/widgets/framework.dart:1705:13)
I/flutter (24703): #32     _InactiveElements._unmount.<anonymous closure> (package:flutter/src/widgets/framework.dart:1707:7)
I/flutter (24703): #33     ComponentElement.visitChildren (package:flutter/src/widgets/framework.dart:3733:14)
I/flutter (24703): #34     _InactiveElements._unmount (package:flutter/src/widgets/framework.dart:1705:13)
I/flutter (24703): #35     _InactiveElements._unmount.<anonymous closure> (package:flutter/src/widgets/framework.dart:1707:7)
I/flutter (24703): #36     SingleChildRenderObjectElement.visitChildren (package:flutter/src/widgets/framework.dart:4826:14)
I/flutter (24703): #37     _InactiveElements._unmount (package:flutter/src/widgets/framework.dart:1705:13)
I/flutter (24703): #38     _InactiveElements._unmount.<anonymous closure> (package:flutter/src/widgets/framework.dart:1707:7)
I/flutter (24703): #39     ComponentElement.visitChildren (package:flutter/src/widgets/framework.dart:3733:14)
I/flutter (24703): #40     _InactiveElements._unmount (package:flutter/src/widgets/framework.dart:1705:13)
I/flutter (24703): #41     _InactiveElements._unmount.<anonymous closure> (package:flutter/src/widgets/framework.dart:1707:7)
I/flutter (24703): #42     ComponentElement.visitChildren (package:flutter/src/widgets/framework.dart:3733:14)
I/flutter (24703): #43     _InactiveElements._unmount (package:flutter/src/widgets/framework.dart:1705:13)
I/flutter (24703): #44     _InactiveElements._unmount.<anonymous closure> (package:flutter/src/widgets/framework.dart:1707:7)
I/flutter (24703): #45     ComponentElement.visitChildren (package:flutter/src/widgets/framework.dart:3733:14)
I/flutter (24703): #46     _InactiveElements._unmount (package:flutter/src/widgets/framework.dart:1705:13)
I/flutter (24703): #47     _InactiveElements._unmount.<anonymous closure> (package:flutter/src/widgets/framework.dart:1707:7)
I/flutter (24703): #48     ComponentElement.visitChildren (package:flutter/src/widgets/framework.dart:3733:14)
I/flutter (24703): #49     _InactiveElements._unmount (package:flutter/src/widgets/framework.dart:1705:13)
I/flutter (24703): #50     _InactiveElements._unmount.<anonymous closure> (package:flutter/src/widgets/framework.dart:1707:7)
I/flutter (24703): #51     ComponentElement.visitChildren (package:flutter/src/widgets/framework.dart:3733:14)
I/flutter (24703): #52     _InactiveElements._unmount (package:flutter/src/widgets/framework.dart:1705:13)
I/flutter (24703): #53     _InactiveElements._unmount.<anonymous closure> (package:flutter/src/widgets/framework.dart:1707:7)
I/flutter (24703): #54     ComponentElement.visitChildren (package:flutter/src/widgets/framework.dart:3733:14)
I/flutter (24703): #55     _InactiveElements._unmount (package:flutter/src/widgets/framework.dart:1705:13)
I/flutter (24703): #56     ListIterable.forEach (dart:_internal/iterable.dart:39:13)
I/flutter (24703): #57     _InactiveElements._unmountAll (package:flutter/src/widgets/framework.dart:1718:25)
I/flutter (24703): #58     BuildOwner.finalizeTree.<anonymous closure> (package:flutter/src/widgets/framework.dart:2372:27)
I/flutter (24703): #59     BuildOwner.lockState (package:flutter/src/widgets/framework.dart:2204:15)
I/flutter (24703): #60     BuildOwner.finalizeTree (package:flutter/src/widgets/framework.dart:2371:7)
I/flutter (24703): #61     _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding&PaintingBinding&SemanticsBinding&RendererBinding&WidgetsBinding.drawFrame (package:flutter/src/widgets/binding.dart:678:18)
I/flutter (24703): #62     _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding&PaintingBinding&SemanticsBinding&RendererBinding._handlePersistentFrameCallback (package:flutter/src/rendering/binding.dart:219:5)
I/flutter (24703): #63     _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding._invokeFrameCallback (package:flutter/src/scheduler/binding.dart:990:15)
I/flutter (24703): #64     _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding.handleDrawFrame (package:flutter/src/scheduler/binding.dart:930:9)
I/flutter (24703): #65     _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding._handleDrawFrame (package:flutter/src/scheduler/binding.dart:842:5)
I/flutter (24703): #66     _invoke (dart:ui/hooks.dart:151:13)
I/flutter (24703): #67     _drawFrame (dart:ui/hooks.dart:140:3)
I/flutter (24703): ════════════════════════════════════════════════════════════════════════════════════════════════════
I/flutter (24703): Another exception was thrown: 'package:flutter/src/widgets/framework.dart': Failed assertion: line 3473 pos 12: '_debugLifecycleState != _ElementLifecycle.defunct': is not true.
I/chatty  (24703): uid=10149(com.example.testing) 1.ui identical 13 lines
I/flutter (24703): Another exception was thrown: 'package:flutter/src/widgets/framework.dart': Failed assertion: line 3473 pos 12: '_debugLifecycleState != _ElementLifecycle.defunct': is not true.

The crash occurs because DrawerControllerState.dispose() removes its local history entry in BuildOwner.finalizeTree(), where we dispose of the inactive elements.
  class DrawerControllerState extends State<DrawerController> with SingleTickerProviderStateMixin {
    @override
    void dispose() {
      _historyEntry?.remove(); // !!
      _controller.dispose();
      super.dispose();
    }
  }

This causes the enclosing ModalRoute to call setState() (on its ModalScope) which trips an assert about calling setState() from within build.
It's possible to avoid the problem by doing the _historyEntry work in a new frame:
  void dispose() {
    SchedulerBinding.instance.scheduleFrameCallback((Duration timestamp) {
      _closed = true; // so that DrawerState.close() will do nothing
      _historyEntry?.remove();
    });

The version of the code above passes the tests and appears to work correctly. It's a hack of course, but it's not clear what the "correct" approach would be.
It seems like we shouldn't ever do anything in State.dispose() that might trigger a build and we should warn about that in the State.dispose() docs. In this case, we can't know that the local history entry needs to be removed until we discover as much in the dispose() method. The request for a build is needed because visuals, notably the appbar's back button, depend on the history entries.
Talking with @Hixie  about this.

After looking into this further, we've sadly concluded that removing the scaffold while the drawer is open is not supported. The app will have to close the drawer, with Navigator.pop(), before rebuilding the app without the scaffold. Here's a version of the test app that does that: https://gist.github.com/HansMuller/8ff39856dd5ee1f13bd4e93a907cf200
Detecting this failure mode is difficult for the same reason that automatically correcting it is: by the time we learn that the Scaffold is being removed (by the time its dispose() method is called) it's too late.

Mulligan does this in production today. Do you know if there will be any
release mode side effects? Of the top of my head I think we've seen random
crashes related to this although maybe I'm mistaken.
It would be a large effort for us to refactor this. I can explain why if
you're curious (or link you to an internal design doc). The refactoring is
something we'd like to do for other reasons but we probably won't be able
to get to it anytime soon.
On Tue, Dec 18, 2018, 5:06 PM Hans Muller <notifications@github.com wrote:

After looking into this further, we've sadly concluded that removing the
scaffold while the drawer is open is not supported. The app will have to
close the drawer, with Navigator.pop(), before rebuilding the app without
the scaffold. Here's a version of the test app that does that:
https://gist.github.com/HansMuller/8ff39856dd5ee1f13bd4e93a907cf200
Detecting this failure mode is difficult for the same reason that
automatically correcting it is: by the time we learn that the Scaffold is
being removed (by the time its dispose() method is called) it's too late.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/flutter/flutter/issues/25047#issuecomment-448431099,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ACH0Z4ayugpY_qP7M005Xt4x5nSSs53xks5u6ZEggaJpZM4ZHME-
.

Closing the drawer before rebuilding without the scaffold shouldn't have any side effects. It queues up the same rebuild request, but that happens in the same frame as everything else.

As in the above referenced issue, I am getting this error without even disposing the drawer at all. It happens for me when I push while the drawer is opened.

@MichaelPriebe - you're right, it's enough to rebuild a scaffold that had a drawer without one. To avoid the problem with implicitly disposing the drawer, pop the route first. See https://github.com/flutter/flutter/issues/25601#issuecomment-451018092

@HansMuller How would you close the drawer when in response to rotation event?
Is a chicken and egg scenario: In order to determine if the drawer is open, we need to listen to a LayoutBuilder or OrientationBuilder, and by then, the Scaffold has already been rebuilt, and thus the crash.
It's a pretty common scenario to support a drawer on phone screens, but not on tablets, since they have more room.
Would you consider reopening? Maybe it could be fixed in the future.

same problem here. there should be a proper fix.

authors: HansMuller MichaelPriebe Xgamefactory alanrussian larssn


text:
Changes to PhysicalModel's clipBehavior not reflected by hot reload

I have this code in an otherwise empty app:
import 'package:flutter/material.dart';

void main() {
  runApp(MyApp());
}

class MyApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        appBar: AppBar(
          title: Text('Title!'),
        ),
        body: Center(
          child: PhysicalModel(
            elevation: 2.0,
            borderRadius: const BorderRadius.all(Radius.circular(10.0)),
            shape: BoxShape.rectangle,
            color: Colors.grey,
            child: Container(
              height: 100,
              width: 100,
              color: Colors.blue,
            ),
          ),
        ),
      ),
    );
  }
}

If I run the app, the corners of the blue container are not clipped, since PhysicalModel's clipBehavior defaults to none. If I try to remedy this by adding clipBehavior: Clip.antiAlias to the PhysicalModel, nothing happens when I hot reload. I have to do a full hot restart to see the change.
PhysicalModel's updateRenderObject method doesn't update the clipBehavior:
  @override
  void updateRenderObject(BuildContext context, RenderPhysicalModel renderObject) {
    renderObject
      ..shape = shape
      ..borderRadius = borderRadius
      ..elevation = elevation
      ..color = color
      ..shadowColor = shadowColor;
  }

That's the reason a hot restart is required. Is this by design? This would mean it's impossible to rebuild the PhysicalModel with a different clipBehavior under normal circumstances as well:
import 'package:flutter/material.dart';

void main() {
  runApp(MyApp());
}

class MyApp extends StatefulWidget {
  @override
  _MyAppState createState() => _MyAppState();
}

class _MyAppState extends State<MyApp> {
  int count = 0;

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        appBar: AppBar(
          title: Text('Title!'),
        ),
        body: Center(
          child: PhysicalModel(
            elevation: 2.0,
            borderRadius: const BorderRadius.all(Radius.circular(10.0)),
            shape: BoxShape.rectangle,
            color: Colors.grey,
            clipBehavior: count % 2 == 0 ? Clip.none : Clip.antiAlias,
            child: GestureDetector(
              onTap: () {
                setState(() => count++);
              },
              child: Container(
                height: 100,
                width: 100,
                color: Colors.blue,
              ),
            ),
          ),
        ),
      ),
    );
  }
}

Logs
Flutter doctor:
[✓] Flutter (Channel stable, v1.2.1, on Mac OS X 10.13.6 17G5019, locale en-US)
    • Flutter version 1.2.1 at /Users/redbrogdon/Library/flutter
    • Framework revision 8661d8aecd (8 weeks ago), 2019-02-14 19:19:53 -0800
    • Engine revision 3757390fa4
    • Dart version 2.1.2 (build 2.1.2-dev.0.0 0a7dcf17eb)

[✓] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
    • Android SDK at /Users/redbrogdon/Library/Android/sdk
    • Android NDK location not configured (optional; useful for native profiling support)
    • Platform android-28, build-tools 28.0.3
    • ANDROID_HOME = /Users/redbrogdon/Library/Android/sdk
    • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1024-b01)
    • All Android licenses accepted.

[✓] iOS toolchain - develop for iOS devices (Xcode 10.1)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 10.1, Build version 10B61
    • ios-deploy 1.9.4
    • CocoaPods version 1.6.1

[✓] Android Studio (version 3.1)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin version 27.1.1
    • Dart plugin version 173.4700
    • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1024-b01)

[✓] IntelliJ IDEA Community Edition (version 2018.3.5)
    • IntelliJ at /Applications/IntelliJ IDEA CE.app
    • Flutter plugin version 33.4.2
    • Dart plugin version 183.5912.23

[✓] Connected device (1 available)
    • iPhone XR • 2998CF6D-5051-46A1-B4FC-5336EDDD73E2 • ios • iOS 12.1 (simulator)

• No issues found!

cc @liyuqian, there might be other places with this issue. We should do an audit.

PhysicalShape seemed to have the same problem, though I haven't tried using it.
https://github.com/flutter/flutter/blob/ab06d033ca210964c541f09c53803590aa95e865/packages/flutter/lib/src/widgets/basic.dart#L972

Feel free to send us a PR too if you'd like @RedBrogdon. Would be happy to help or review.

authors: RedBrogdon xster


text:
firebase_messaging stopped triggering onResume etc

Messages were arriving as expected but stopped working on all instances of my flutter android apps even though there were no code changes.
Firebase logging is showing messages sent successfully.
I'm on old version of firebase_messaging, 2.01. Was support for this version removed or has something changed in how it should be called. No errors are appearing in emulator also.
Thanks.

Closing, topic names had been changed.


text:
flutter run failed with wayland on linux

Follow the steps of https://github.com/chinmaygarde/flutter_wayland
./flutter_wayland /home/oppo/AndroidStudioProjects/flutter_app1/build/flutter_assets/
ERROR: ../src/main.cc:63: Arg: /home/oppo/AndroidStudioProjects/flutter_app1/build/flutter_assets/
flutter: Observatory listening on http://127.0.0.1:38682/
[ERROR:flutter/shell/common/engine.cc(112)] Engine run configuration was invalid.
[ERROR:flutter/shell/platform/embedder/embedder_engine.cc(65)] Could not launch the engine with configuration.
Any suggestions from here?

Please don't file duplicate bugs; I've already explained in #35735 why this isn't a Flutter issue. https://github.com/chinmaygarde/flutter_wayland/issues/4 is the right place for your issue.


text:
Discuss how we would like devs to approach splash behavior when using FlutterView directly

Discuss how we would like devs to approach splash behavior when using FlutterView directly

This is probably mentioned in this document on how to use splash screen using FlutterView.
I am going ahead and closing this as resolved. If anybody disagrees or think this should be kept open, please write in comments and I'll reopen.
Thanks.

authors: darshankawar matthew-carroll


text:
RTL Layouts

Hello flutter team,
my question is about RTL direction, I know you're not familiar with the Arabic language.
and I'm here to clarify my situation.
I live in Morocco, I speak Arabic language, the second language is French, so the language I use in my mobile is French and millions of users use French or English Language as a default language on their mobile like me. And also there's another user (Morocco, Saudi Arabia, Algeria, Egypte, Tunisia, Emirate, Qatar, Bahrain, Jordan... ) use the Arabic language in their mobile.
So the issue here is about layout direction, I see some examples of how to change the direction of layout, but I think the example works if I have Arabic as a default language on my mobile.
I think in Android Studio, they fix the issue using : android:layoutDirection="rtl"
so how can I get RTL Direction of layout without change the default language of mobile?

Hello @rachidev84 !
Thank you for posting.
This issue might be related to the #39865 and #41324 as well.

This is more of a SO question
but the answer is simply using the Directionality widget
Directionality(
textDirection: TextDirection.rtl,
child: Text('Hello')
),

Thank you @Rahiche  for your Idea,
I'm using photoshop to explain my situation:
this is the AppBar with (title and icon) in version LTR:

and this is how should appear the AppBard with (title and icon) version RTL

I'll be grateful if you resolve this issue using your example:
using my code:
file: scaffoldDesign.dart
import 'package:flutter/material.dart';
import 'package:flutter/painting.dart';
class ScaffoldDesign extends StatelessWidget {
void onPressedPrintIcon() {
print("Hello I'm Print Icon");
}
@override
Widget build(BuildContext context) {
onClickPrinterIcon() {
print('The Icon Print is Clicked');
}
return new Scaffold(
appBar: new AppBar(
backgroundColor: Colors.amber.shade900,
title: new Text("العربية",
style: new TextStyle(
color: Colors.white,
fontSize: 28.0,
fontWeight: FontWeight.bold,
)
),
actions: [
new IconButton(
icon: new Icon(Icons.print),
onPressed: onClickPrinterIcon,
),
],
),
);
}
}
file: main.dart
import 'package:flutter/material.dart';
import 'GUI/scafoldDesign.dart';
void main() {
runApp(new MaterialApp(
home: ScaffoldDesign(),
title: 'Hello Scaffold',
));
}

Hi @rachidev84,
This issue doesn't seem to describe a bug or a feature request. Please see https://flutter.dev/community for resources and asking questions like this.
You may also get some help if you post it on Stack Overflow and if you need help with your code, please see https://www.reddit.com/r/flutterhelp/
Closing, as this isn't an issue with Flutter itself. If you disagree, please write in the comments and I will reopen it.
Thank you

any solution

authors: Rahiche bhargavsejpalindianic darshankawar janmoppel rachidev84


text:
Interrupting Duo calls do not work on

https://b.corp.google.com/issues/143612326. Conversation should occur there.
Believed patched and tested in https://github.com/flutter/engine/pull/13731.
/cc @chinmaygarde

We believe this is now fixed internally and are waiting on verification.


text:
GoogleSignIn:  ERROR_INVALID_CREDENTIAL, OAuth2 client id in access token audience is not found.

Steps to Reproduce
Steps to reproduce the behavior:

Create a Firebase Project
Create Flutter Project
Register the iOS application under Firebase project
Add URL Type and GoogleService-Info.plist to Flutter Runner
Attempt to sign up with google with below code

void handleGoogleSignIn() async {
    final GoogleSignInAccount googleUser = await _googleSignIn.signIn();
    final GoogleSignInAuthentication googleAuth =
        await googleUser.authentication;

      final AuthCredential credential = GoogleAuthProvider.getCredential(
        accessToken: googleAuth.accessToken,
        idToken: googleAuth.idToken,
      );

      final FirebaseUser user =
          (await _auth.signInWithCredential(credential)).user;
      print("signed in " + user.displayName);
      setUserId(user);
      _user = new User(name: user.displayName, email: user.email);
      var debug = true;
  }

Expected results:
Google login is successful and FirebaseUser is populated
Actual results:
An exception is thrown and app crashes
Unhandled Exception: PlatformException(ERROR_INVALID_CREDENTIAL, OAuth2 client id in access token audience is not found., null)

Logs

[        ] [DEVICE LOG] 2020-04-21 10:48:16.503768+0400  localhost Runner[28327]:
(Flutter) [VERBOSE-2:ui_dart_state.cc(157)] Unhandled Exception:
PlatformException(ERROR_INVALID_CREDENTIAL, OAuth2 client id in access token
audience is not found., null)
[        ] [DEVICE LOG] #0      StandardMethodCodec.decodeEnvelope
(package:flutter/src/services/message_codecs.dart:569:7)
[        ] [DEVICE LOG] #1      MethodChannel.invokeMethod
(package:flutter/src/services/platform_channel.dart:321:33)
[        ] [DEVICE LOG] <asynchronous suspension>
[        ] [DEVICE LOG] #2      MethodChannel.invokeMapMethod
(package:flutter/src/services/platform_channel.dart:349:48)
[        ] [DEVICE LOG] #3      MethodChannelFirebaseAuth.signInWithCredential
(package:firebase_auth_platform_interface/src/method_channel_firebase_auth.dart:161
:23)
[        ] [DEVICE LOG] #4      FirebaseAuth.signInWithCredential
(package:firebase_auth/src/firebase_auth.dart:208:10)
[        ] [DEVICE LOG] #5      _AsyncAwaitCompleter.start
(dart:async-patch/async_patch.dart:45:6)
[        ] [DEVICE LOG] #6      FirebaseAuth.signInWithCredential
(package:firebase_auth/src/firebase_auth.dart:205:42)
[        ] [DEVICE LOG] #7      UserStore.handleGoogleSignIn
(package:newbie_test/provider/userStore.dart:45:24)
[        ] [DEVICE LOG] #8      _asyncThenWrapperHelper.<a<…>
[  +11 ms] [VERBOSE-2:ui_dart_state.cc(157)] Unhandled Exception:
PlatformException(ERROR_INVALID_CREDENTIAL, OAuth2 client id in access token
audience is not found., null)
[        ] #0      StandardMethodCodec.decodeEnvelope
(package:flutter/src/services/message_codecs.dart:569:7)
[        ] #1      MethodChannel.invokeMethod
(package:flutter/src/services/platform_channel.dart:321:33)
[        ] <asynchronous suspension>
[        ] #2      MethodChannel.invokeMapMethod
(package:flutter/src/services/platform_channel.dart:349:48)
[        ] #3      MethodChannelFirebaseAuth.signInWithCredential
(package:firebase_auth_platform_interface/src/method_channel_firebase_auth.dart:161
:23)
[        ] #4      FirebaseAuth.signInWithCredential
(package:firebase_auth/src/firebase_auth.dart:208:10)
[        ] #5      _AsyncAwaitCompleter.start
(dart:async-patch/async_patch.dart:45:6)
[        ] #6      FirebaseAuth.signInWithCredential
(package:firebase_auth/src/firebase_auth.dart:205:42)
[        ] #7      UserStore.handleGoogleSignIn
(package:newbie_test/provider/userStore.dart:45:24)
[        ] #8      _asyncThenWrapperHelper.<a<…>

[✓] Flutter (Channel stable, v1.12.13+hotfix.9, on Mac OS X 10.15.3 19D76, locale
    en-AE)
    • Flutter version 1.12.13+hotfix.9 at /Users/niall/Development/flutter
    • Framework revision f139b11009 (3 weeks ago), 2020-03-30 13:57:30 -0700
    • Engine revision af51afceb8
    • Dart version 2.7.2

[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
    • Android SDK at /Users/niall/Library/Android/sdk
    • Android NDK location not configured (optional; useful for native profiling
      support)
    • Platform android-29, build-tools 29.0.2
    • Java binary at: /Applications/Android
      Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build
      1.8.0_202-release-1483-b49-5587405)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 11.3)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 11.3, Build version 11C29
    • CocoaPods version 1.8.4

[✓] Android Studio (version 3.5)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin version 42.1.1
    • Dart plugin version 191.8593
    • Java version OpenJDK Runtime Environment (build
      1.8.0_202-release-1483-b49-5587405)

[✓] VS Code (version 1.44.1)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.9.1

[✓] Connected device (1 available)
    • iPhone 11 Pro Max • 5EE7AB3A-DA20-4F4A-A4CF-57E1D8F79A45 • ios •
      com.apple.CoreSimulator.SimRuntime.iOS-13-3 (simulator)

• No issues found!

Hi @niallshaw
Your are missing client id from step 7 of iOS integration
Make you get iOS OAuth2 Client id from https://console.developers.google.com/
Go to credentials then OAuth 2.0 Client IDs and put your client id in step 7

Thank you

Hi @TahaTesser ,
Apologies if it seems to be a waste of time!
This was the bane of my existence for the past two days.
I thought I had the client IDs registered.
Anyway - I have made a new project and all works as expected.
Thanks for your help.

authors: TahaTesser niallshaw


text:
Discrepancy on TextFormField focus change between desktop and web

Noticed an difference between how desktop and web handles TextFormField focus. This is very similar to this issue (https://github.com/flutter/flutter/issues/32433), but wanted to give a clear example of the problem.
Can't really prescribe what should done, since it I kind of see the pros/cons of both approaches :P
But think they should be the same for consistency at least, so we could use the same approach when handling in apps.
Thanks!
import 'package:flutter/material.dart';

void main() {
  runApp(MyApp());
}

class MyApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Flutter Demo',
      theme: ThemeData(
        primarySwatch: Colors.blue,
        visualDensity: VisualDensity.adaptivePlatformDensity,
      ),
      home: MyHomePage(title: 'Flutter Demo Home Page'),
    );
  }
}

class MyHomePage extends StatefulWidget {
  MyHomePage({Key key, this.title}) : super(key: key);
  final String title;

  @override
  _MyHomePageState createState() => _MyHomePageState();
}

class _MyHomePageState extends State<MyHomePage> {
  FocusNode _focusNode;

  void _handleBtnClick() {
    print("Button clicked!");
  }

  @override
  void initState() {
    _focusNode = FocusNode(
      canRequestFocus: true,
    );
    _focusNode.addListener(() => print("FocusNode changed. Top text input HasFocus?: ${_focusNode.hasFocus}"));

    super.initState();
  }

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: Text(widget.title),
      ),
      body: Center(
        child: Column(
          crossAxisAlignment: CrossAxisAlignment.start,
          children: <Widget>[
            Container(
              padding: EdgeInsets.all(24),
              child: TextFormField(
                focusNode: _focusNode,
              ),
            ),
            Container(
              padding: EdgeInsets.all(24),
              child: TextFormField(),
            ),
            Container(
              padding: EdgeInsets.all(24),
              child: Column(
                crossAxisAlignment: CrossAxisAlignment.start,
                children: [
                  Text("Demo to show discrepancy in focus between TextFormField in desktop vs web"),
                  Text("\n1) Click on the top-most TextFormField above, so you can see the text carat"),
                  Text("2) Click the action button on bottom right"),
                  Text("3) Check the console"),
                  Text("\nNotice on desktop: \n -Focus does not change, text carat stays put"),
                  Text("\nNotice on web: \n -Focus changes (hasFocus = false), loses text carat"),
                  Text(
                      "\nNot sure what the expected/best behavior should be, but just want to highlight the difference"),
                  Text(
                      "\nNote that on desktop & web, clicking the bottom-most text input will change the focus from the top, which is expected"),
                ],
              ),
            ),
          ],
        ),
      ),
      floatingActionButton: FloatingActionButton(
        onPressed: _handleBtnClick,
        tooltip: 'Click me',
        child: Icon(Icons.add),
      ),
    );
  }
}

But think they should be the same for consistency at least

Desktop platforms don't necessarily have the same conventions as the web, so doing the same thing on every platform would be inconsistent with the platforms the applications are running on. On macOS, for instance, clicking on a non-control area of an application window will not have any effect on focus.

imo, it should generally be up to the developer to respect or ignore platform conventions, without the framework deciding it knows best in various circumstances. This leads to a much larger testing footprint when you build in variable behavior like this.
In one scenario, I know exactly how my app will behave, on every platform, it will do exactly as I ask, and I can add in simple, specific logic to respect platform conventions if I choose.
In another, I have no clue, without pouring through source code, what the minute differences are on every platform, and I have to actually test every single platform on a regular basis, which defeats much of the efficiency gains you get from a cross-platform framework.
Consistency should be king here, especially across Web-Running-On-Desktop and Desktop.
For example, if a Developer decides he wants to support the 'convention' of Clickable-background on Web, and not on Desktop, it's a couple lines of code, and he can add it anytime he wants.
If the framework decides to do it, developer either is not even aware he has a bug, has to test on every single possible platform to notice the bug, and then has to figure out how to fight the framework to just get back to the non-opinionated behavior he is looking for.

@eddie-at-work Thanks for filing the issue. We changed our approach this week.
Previously, Flutter for Web behaved like a web page. If user click on an area other than the input field itself, the input field is blurred, thus the connection is closed.
We changed this behavior for Desktop Browsers. Now only, pressing enter, tab changes the focus of the input fields. Therefore clicking on a button as you suggested also won't change the focus.
Please check  the PR: https://github.com/flutter/engine/pull/18743
There is another issue with a longer discussion: https://github.com/flutter/flutter/issues/49785 Please also have a look there.

authors: eddie-at-work esDotDev nturgut stuartmorgan


text:
Overstretching SliverAppBar causes navigation bar color to reset

Steps to reproduce
Run the sample code provided and overscroll until the navigation bar turns black. Depending on screen size, you may need to keep your first finger always touching the screen and use a second finger to scroll. The color change is done when SliverAppBar size is ~50% of the screen.
Sample code
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';

void main() => runApp(SampleApp());

class SampleApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    SystemChrome.setSystemUIOverlayStyle(
      const SystemUiOverlayStyle(
        statusBarColor: Colors.transparent,
        statusBarIconBrightness: Brightness.dark,
        systemNavigationBarColor: Colors.white,
        systemNavigationBarIconBrightness: Brightness.dark,
      ),
    );
    return const MaterialApp(
      home: Scaffold(
        body: CustomScrollView(
          physics: BouncingScrollPhysics(),
          slivers: <Widget>[
            SliverAppBar(
              stretch: true,
            ),
            SliverFillRemaining(
              child: Placeholder(),
            ),
          ],
        ),
      ),
    );
  }
}

Expected results: After overscrolling, navigation bar is still white
Actual results: Navigation bar is set to black
This was tested and reproduced on:

Oneplus 5 running Android 10
Pixel 3 XL running Android 11

Logs
[ +231 ms] D/PhoneWindow( 7561): setNavigationBarColor: ffffffff
[+9886 ms] D/PhoneWindow( 7561): setNavigationBarColor: ff000000

Flutter 1.22.0-10.0.pre.137 • channel master • https://github.com/flutter/flutter.git
Framework • revision 37e2013774 (3 hours ago) • 2020-09-11 04:05:02 -0400
Engine • revision bdaac368f8
Tools • Dart 2.10.0 (build 2.10.0-115.0.dev)

I can reproduce it on OnePlus 8
D/PhoneWindow(10350): setNavigationBarColor: ffffffff
I/Surface (10350): opservice is null false
I/Surface (10350): opservice is null false
D/PhoneWindow(10350): setNavigationBarColor: ff000000
I/Surface (10350): opservice is null false

code sample
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';

void main() => runApp(SampleApp());

class SampleApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    SystemChrome.setSystemUIOverlayStyle(
      const SystemUiOverlayStyle(
        statusBarColor: Colors.transparent,
        statusBarIconBrightness: Brightness.dark,
        systemNavigationBarColor: Colors.white,
        systemNavigationBarIconBrightness: Brightness.dark,
      ),
    );
    return const MaterialApp(
      home: Scaffold(
        body: CustomScrollView(
          physics: BouncingScrollPhysics(),
          slivers: <Widget>[
            SliverAppBar(
              stretch: true,
            ),
            SliverFillRemaining(
              child: Placeholder(),
            ),
          ],
        ),
      ),
    );
  }
}

flutter doctor -v
[✓] Flutter (Channel master, 1.22.0-10.0.pre.137, on Mac OS X 10.15.6 19G2021,
    locale en-GB)
    • Flutter version 1.22.0-10.0.pre.137 at
      /Users/tahatesser/Code/flutter_master
    • Framework revision 37e2013774 (4 hours ago), 2020-09-11 04:05:02 -0400
    • Engine revision bdaac368f8
    • Dart version 2.10.0 (build 2.10.0-115.0.dev)

[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.2)
    • Android SDK at /Users/tahatesser/Code/sdk
    • Platform android-30, build-tools 30.0.2
    • ANDROID_HOME = /Users/tahatesser/Code/sdk
    • Java binary at: /Applications/Android
      Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build
      1.8.0_242-release-1644-b3-6222593)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 11.7)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 11.7, Build version 11E801a
    • CocoaPods version 1.9.3

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 4.0)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin version 49.0.2
    • Dart plugin version 193.7547
    • Java version OpenJDK Runtime Environment (build
      1.8.0_242-release-1644-b3-6222593)

[✓] VS Code (version 1.49.0)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.14.1

[✓] Connected device (3 available)
    • macOS (desktop)  • macos      • darwin-x64     • Mac OS X 10.15.6 19G2021
    • Web Server (web) • web-server • web-javascript • Flutter Tools
    • Chrome (web)     • chrome     • web-javascript • Google Chrome 85.0.4183.102

• No issues found!

@Zazo032 You should be able to overcome the issue wrapping your UI with:
AnnotatedRegion<SystemUiOverlayStyle>(
            value: SystemUiOverlayStyle(
        statusBarColor: Colors.transparent,
        statusBarIconBrightness: Brightness.dark,
        systemNavigationBarColor: Colors.white,
        systemNavigationBarIconBrightness: Brightness.dark,
      ),
            child: your_ui,
          )

@Zazo032 You should be able to overcome the issue wrapping your UI with:
AnnotatedRegion<SystemUiOverlayStyle>(
            value: SystemUiOverlayStyle(
        statusBarColor: Colors.transparent,
        statusBarIconBrightness: Brightness.dark,
        systemNavigationBarColor: Colors.white,
        systemNavigationBarIconBrightness: Brightness.dark,
      ),
            child: your_ui,
          )

The issue still happens with your proposed solution

Yep, I can confirm, this issue still persists, with the proposed solution
Restarted application in 712ms.
D/PhoneWindow(18044): setNavigationBarColor: ffffffff
D/PhoneWindow(18044): setNavigationBarColor: ff000000
D/PhoneWindow(18044): setNavigationBarColor: ffffffff

code sample
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';

void main() => runApp(SampleApp());

class SampleApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    // SystemChrome.setSystemUIOverlayStyle(
    //   const SystemUiOverlayStyle(
    //     statusBarColor: Colors.transparent,
    //     statusBarIconBrightness: Brightness.dark,
    //     systemNavigationBarColor: Colors.white,
    //     systemNavigationBarIconBrightness: Brightness.dark,
    //   ),
    // );

    return AnnotatedRegion<SystemUiOverlayStyle>(
      value: SystemUiOverlayStyle(
        statusBarColor: Colors.transparent,
        statusBarIconBrightness: Brightness.dark,
        systemNavigationBarColor: Colors.white,
        systemNavigationBarIconBrightness: Brightness.dark,
      ),
      child: const MaterialApp(
        home: Scaffold(
          body: CustomScrollView(
            physics: BouncingScrollPhysics(),
            slivers: <Widget>[
              SliverAppBar(
                stretch: true,
              ),
              SliverFillRemaining(
                child: Placeholder(),
              ),
            ],
          ),
        ),
      ),
    );
    // return const MaterialApp(
    //   home: Scaffold(
    //     body: CustomScrollView(
    //       physics: BouncingScrollPhysics(),
    //       slivers: <Widget>[
    //         SliverAppBar(
    //           stretch: true,
    //         ),
    //         SliverFillRemaining(
    //           child: Placeholder(),
    //         ),
    //       ],
    //     ),
    //   ),
    // );
  }
}

flutter doctor -v
[✓] Flutter (Channel master, 1.22.0-10.0.pre.317, on Mac OS X 10.15.6 19G2021
    x86_64, locale en-GB)
    • Flutter version 1.22.0-10.0.pre.317 at
      /Users/tahatesser/Code/flutter_master
    • Framework revision 10febea877 (3 hours ago), 2020-09-23 07:22:10 +0200
    • Engine revision 57ee3d4b32
    • Dart version 2.10.0 (build 2.10.0-156.0.dev)

[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.2)
    • Android SDK at /Users/tahatesser/Code/sdk
    • Platform android-30, build-tools 30.0.2
    • ANDROID_HOME = /Users/tahatesser/Code/sdk
    • Java binary at: /Applications/Android
      Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build
      1.8.0_242-release-1644-b3-6222593)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 12.0)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 12.0, Build version 12A7209
    • CocoaPods version 1.9.3

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 4.0)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin version 49.0.2
    • Dart plugin version 193.7547
    • Java version OpenJDK Runtime Environment (build
      1.8.0_242-release-1644-b3-6222593)

[✓] VS Code (version 1.49.1)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.14.1

[✓] Connected device (4 available)
    • iPhone 11 (mobile) • 9A8EFBFE-A806-4FF9-ACA5-F3F98D94979D • ios
      • com.apple.CoreSimulator.SimRuntime.iOS-14-0 (simulator)
    • macOS (desktop)    • macos                                • darwin-x64
      • Mac OS X 10.15.6 19G2021 x86_64
    • Web Server (web)   • web-server                           • web-javascript
      • Flutter Tools
    • Chrome (web)       • chrome                               • web-javascript
      • Google Chrome 85.0.4183.102

• No issues found!

@Zazo032, @TahaTesser sorry my fault. I haven't understood enough the issue description. @TahaTesser thanks for the screenshot that helped me understand this!
Looks like I filled issue report, that tracks root of the bug that is described here. You can also find a Flutter fix under there: https://github.com/flutter/flutter/issues/66429#issuecomment-697261308

authors: TahaTesser Zazo032 jacek-marchwicki


text:
Input reopens keyboard after user interacts with a form element other than Input

Create a simple form with a dropdown button and an Input.
Tap on input, keyboard appears.
Close the keyboard.
Open up the dropdown and select something.
As the dropdown closes, Input regains focus and opens the keyboard automatically.

I don't mind Input keeping the focus since dropdown isn't a focusable element (typically) but it should not reopen the keyboard. Keyboard should only open when the input element is tapped.

Matt is probably the right place to start.

This is tricky. It means we have to distinguish gaining the focus because the user tapped on it or hit "next" or whatever, and gaining the focus because the focus scope changed.

authors: Hixie eseidelGoogle mehmetf


text:
CanvasKit fonts.dart is missing unit-tests

There were a couple of runtime errors in the past couple of days (https://github.com/flutter/engine/pull/22251, https://github.com/flutter/engine/pull/22248), which could be caught by a test.

I added a screenshot test in https://github.com/flutter/engine/pull/22807 that loads a real font and checks the rendering using a screenshot, which covers this use-case.


text:
[ERROR:flutter/lib/ui/ui_dart_state.cc(177)] Unhandled Exception: NoSuchMethodError: The method 'animateCamera' was called on null.

@override
void initState() {
getUserLocation();
super.initState();
}
void getUserLocation() async {
Position position = await Geolocator.getCurrentPosition(
desiredAccuracy: LocationAccuracy.best);
List placeMark =
await placemarkFromCoordinates(position.latitude, position.longitude);
currentLocation = LatLng(position.latitude, position.longitude);
locationController.text = placeMark[0].name;
_mapController.animateCamera(CameraUpdate.newLatLng(currentLocation));
}

How was this solved ? I'm having the same issue

How was this solved ? I'm having the same issue


text:
bin/format.dart tries to format bash scripts using gn

https://cs.opensource.google/flutter/engine/+/master:ci/bin/format.dart is trying to format bash scripts using gn. Here is one example:
https://github.com/flutter/engine/pull/26666/commits/96f83e87c3cacd75bf166fe691e69a2f6aed7ad3

There was actually a trailing space although it was reported in a different line.


text:
Unable to give the path in command line for setting android in  flutter.

Team,
I have installed android studio in my local system. but flutter didn't recognize it, and asked me to give the directory. So I gave the directory with the command and still I am facing the issue. please help me in the problem.

@mrlakshman88
The Android studio path seems to be pointing to bin and not to Android Studio
Try changing that path to point to Android Studio folder instead of bin and see if it helps.

Without additional information, we are unfortunately not sure how to resolve this issue.
We are therefore reluctantly going to close this bug for now.
Please don't hesitate to comment on the bug if you have any more information for us; we will reopen it right away!
Thanks for your contribution.
Could everyone who still has this problem please file a new issue with the exact description of what happens, logs, and the output of flutter doctor -v.
All system setups can be slightly different, so it's always better to open new issues and reference related issues.

authors: TahaTesser darshankawar mrlakshman88


text:
Please help me to fix this problem, Thanks

error logs
FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:stripDebugDebugSymbols'.
> NDK at C:\Users\Engineering\AppData\Local\Android\Sdk\ndk\21.1.6352462 did not have a source.properties file

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 6s
Exception: Gradle task assembleDebug failed with exit code 1

flutter doctor -v
C:\Users\Engineering\StudioProjects\untitled10>flutter doctor -v
[√] Flutter (Channel stable, 2.2.3, on Microsoft Windows [Version 10.0.19043.1165], locale en-US)
    • Flutter version 2.2.3 at C:\src\flutter
    • Framework revision f4abaa0735 (9 weeks ago), 2021-07-01 12:46:11 -0700
    • Engine revision 241c87ad80
    • Dart version 2.13.4

[√] Android toolchain - develop for Android devices (Android SDK version 31.0.0)
    • Android SDK at C:\Users\Engineering\AppData\Local\Android\Sdk
    • Platform android-31, build-tools 31.0.0
    • ANDROID_HOME = C:\Program Files\Android\Android Studio1\bin
    • ANDROID_SDK_ROOT = C:\Users\Engineering\AppData\Local\Android
    • Java binary at: C:\Program Files\Android\Android Studio\jre\bin\java
    • Java version OpenJDK Runtime Environment (build 11.0.10+0-b96-7249189)
    • All Android licenses accepted.

[√] Chrome - develop for the web
    • Chrome at C:\Program Files\Google\Chrome\Application\chrome.exe

[√] Android Studio
    • Android Studio at C:\Program Files\Android\Android Studio
    • Flutter plugin can be installed from:
       https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
       https://plugins.jetbrains.com/plugin/6351-dart
    • android-studio-dir = C:\Program Files\Android\Android Studio
    • Java version OpenJDK Runtime Environment (build 11.0.10+0-b96-7249189)

[√] VS Code (version 1.55.0)
    • VS Code at C:\Users\Engineering\AppData\Local\Programs\Microsoft VS Code
    • Flutter extension version 3.21.0

[√] Connected device (3 available)
    • AOSP on IA Emulator (mobile) • emulator-5554 • android-x86    • Android 9 (API 28) (emulator)
    • Chrome (web)                 • chrome        • web-javascript • Google Chrome 92.0.4515.159
    • Edge (web)                   • edge          • web-javascript • Microsoft Edge 92.0.902.78

• No issues found!

C:\Users\Engineering\StudioProjects\untitled10>Run  --scan
'Run' is not recognized as an internal or external command,
operable program or batch file.

C:\Users\Engineering\StudioProjects\untitled10>flutter doctor _v
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable, 2.2.3, on Microsoft Windows [Version 10.0.19043.1165], locale en-US)
[√] Android toolchain - develop for Android devices (Android SDK version 31.0.0)
[√] Chrome - develop for the web
[√] Android Studio
[√] VS Code (version 1.55.0)
[√] Connected device (3 available)

• No issues found!

Hi @rezahabibpour, thanks for filing the issue.
Kindly take a look the following SO threads and see if they help you with your issue:
https://stackoverflow.com/questions/68250933/execution-failed-for-task-appstripdebugdebugsymbols-in-flutter
https://stackoverflow.com/questions/64254163/android-studio-warning-on-my-app-appstripdebugdebugsymbols-up-to-date/64281498
Thank you

After adding google maps in AndroidManifest.xml now I have this error that I dont know what should I do,
zipro W 09-12 21:21:29 36704 407998 Error opening archive /Users/johnhabibpour/StudioProjects/08-19-2021 AM/absolutestonedesignpro/build/app/outputs/flutter-apk/app.apk: Invalid file
ERROR: dump failed because resource AndroidManifest.xml not found
Failed to extract manifest from APK: ProcessException: The command failed
Command: /Users/johnhabibpour/Library/Android/sdk/build-tools/31.0.0/aapt dump xmltree /Users/johnhabibpour/StudioProjects/08-19-2021 AM/absolutestonedesignpro/build/app/outputs/flutter-apk/app.apk AndroidManifest.xml.
No application found for TargetPlatform.android_x86.
Is your project missing an android/app/src/main/AndroidManifest.xml?
Consider running "flutter create ." to create one.

Hi @rezahabibpour, the issue tracker is not the place for these kind of issues.
I believe it would be in your best interest to check stackoverflow or other flutter communities for help with these kinds of issues.
That aside, please checkout this stackoverflow link and see if you can find a fix to your problem and do let me know if you do.
Thank you

I really appreciate for your reply but I couldnt find any same as my issue,
if you have time I can explain what happened,
Actually my IOS working very well but after I edited Androismanifest and
add google maps information,
at first was working but it couldnt connect with google maps but after I
edited again and after that I changed with previous saved one that I had
but now I send you the final error that android studio shows me, please
help to fix this problem,
Thanks
On Mon, Sep 13, 2021 at 2:11 AM Daniel Agbemava @.***>
wrote:

Hi @rezahabibpour https://github.com/rezahabibpour, the issue tracker
is not the place for these kind of issues.
I believe it would be in your best interest to check stackoverflow or
other flutter communities for help with these kinds of issues.
That aside, please checkout this stackoverflow link
https://stackoverflow.com/questions/54636718/no-application-found-for-targetplatform-android-x86
and see if you can find a fix to your problem and do let me know if you do.
Thank you
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/flutter/flutter/issues/89217#issuecomment-917872880,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ASSABBIPIY6BPKMP7S3LUSTUBWI2FANCNFSM5DEGH2IA
.
Triage notifications on the go with GitHub Mobile for iOS
https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675
or Android
https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

Can you share your AndroidManifest.xml?

This is my Androidmanifest.xml

Can you show me a screenshot of your AndroidManifest.xml?

Now another problem, I dont know what is this new Ios folder that include some files that when I want to execute pub get , it says couldnt find pubspec.yaml,
I confused completely

The lib, macOS, android folders are not supposed to be in the parent iOS folder.
Would it be possible for you to zip your project and share it?

sure, how can i attach zip file here,

Zip the file and drop it in the editor, just make sure it's not too large. There's a file upload limit

unfortunately the file is 450 mb , is there anyway to send it ,

sorry 415 Mb

Hi @rezahabibpour, can you upload the project to github?

I am so sorry to ask , yesterday I tried but I dont know how can I do it, is there any instruction to help me to do, sorry about my silly question,

Kindly take a look at this article.
It's a general overview of git and github, but it should apply

Hi there,
unfortunately Github doesn't let me upload complete project , just I add Lib folder,
How can I remove unnecessary files from my project please?
After this project I started to write all of them from scratch in new project, everything was good but just I want to add  modal_progress_hud package , everything destroyed again, I could run iOS but I couldnt run Android,
I think Flutter couldnt help me to be an App developer,
https://github.com/rezahabibpour/absolutestonedesignpro.git
this is second project as well:
https://github.com/rezahabibpour/asdapp.git

Hi @rezahabibpour, looking at the current state of things, I would advise you find me on discord at danagbemava-nc#2030 so I can find time to take a look at your project for you.
For now, I will close this issue as we have gone far off-topic and the intended use of this space.
Thank you.

authors: danagbemava-nc rezahabibpour


text:
native_ui_tests_macos failing, xcodebuild: error: No signing certificate "Mac Development" found: No "Mac Development" signing certificate matching team ID "S8QB4VV633" with a private key was found.

[native_ui_tests_macos] [STDOUT] stdout: error: No signing certificate "Mac Development" found: No "Mac Development" signing certificate matching team ID "S8QB4VV633" with a private key was found. (in target 'Pods-RunnerTests' from project 'Pods')

https://logs.chromium.org/logs/flutter/buildbucket/cr-buildbucket/8834888476758502401/+/u/run_native_ui_tests_macos/test_stdout

native_ui_tests_macos is now passing in post submit.


text:
[webview_flutter] Prevent deep linking to third party applications

Hello
We have application which allow users to sign-in in Aliexpress account via our webview, but we have some problem with third party Aliexpress application, when user trying to sign in aliexpress via our webview, installed Aliexpress app will catch that url and open it in self, how we can avoid that? Thank you!

Hey @koteesy , as this is a plugin issue you can resubmit your issues on this thread https://github.com/flutter/plugins/tree/master/packages/webview_flutter/webview_flutter

There's no issues in repository, they move all issues to this repository, see description: https://github.com/flutter/plugins

@koteesy
I am not completely sure but I guess you can make use of shouldOverrideUrlLoading function to prevent that if you are able to add the 3rd party protocol to originWhitelist.
Also, your question seems to be better suited for support channels like StackOverflow, so please ask the same there.
Closing from here.

@koteesy I am not completely sure but I guess you can make use of shouldOverrideUrlLoading function to prevent that if you are able to add the 3rd party protocol to originWhitelist.
Also, your question seems to be better suited for support channels like StackOverflow, so please ask the same there. Closing from here.

But there's no protocol, there's just url like https://example.com/login.html, and if i will use shouldOverrideUrlLoading i just will stop user webview, not opening third party app, this in't it?

authors: darshankawar koteesy


text:
The method pumpAndSettle() don't wait for the widget to finish.

I have a question about the flutter integration test.
In the integration test we have pumpAndSettle(), which is used to wait for widget to finish, but there are times in tests I have wait for a external API and I need to put for example pumpAndSettle(const Duration(seconds: 5)) because the pumpAndSettle alone does not solve.
My question is, does flutter have another way for me to wait for the widget is finished or it have a method of intercept and wait a external API request.

Actually waiting on a real API request during tests is a bad practice. Use a test stub / mock class for your API calls that return a value like Future.value(myFakeApiResponse).

Hi @Gusttavogs,  This is working as intended when you don't pass a duration to pumpAndSettle it pumps for 100 milliseconds. Passing a duration seems to be the right way  for more please refer the docs https://api.flutter.dev/flutter/flutter_test/WidgetTester/pumpAndSettle.html
Closing as this is neither a bug nor a feature request.

authors: Gusttavogs maheshmnj navaronbracke


text:
Widgets don't check if FocusNode is focused when they receive it

cc @abarth

Closing on advice from @abarth.


text:
Simplify colorizing icons

Now you can colorize an Icon simply by proving a Color for the Icon.

@HansMuller

It would be interesting for theme transitions if IconButton supported this. The difficulty is working out which underlying image to colorize (we have white and black variants).

IMHO, we should just get rid of the white variants.  We can just use Colors.white to colorize the black images.

LGTM

source: gharchive/pull-request

authors: HansMuller Hixie abarth


text:
Roll Flutter Engine from c602abdbae16 to 922c7b133bc2 (7 revisions)

https://github.com/flutter/engine/compare/c602abdbae16...922c7b133bc2
2024-03-28 skia-flutter-autoroll@skia.org Roll Fuchsia Linux SDK from Lk8KBU-c97ROj-YHm... to uzI3wnbEGlZ_dtO0Z... (flutter/engine#51737)
2024-03-28 skia-flutter-autoroll@skia.org Roll Skia from b6160ffc0b96 to 66241be7c81c (16 revisions) (flutter/engine#51733)
2024-03-28 bdero@google.com [Impeller] Reland: Use the scissor to limit all draws by clip coverage.  (flutter/engine#51731)
2024-03-27 30870216+gaaclarke@users.noreply.github.com [Impeller] adds a plus advanced blend for f16 pixel formats (flutter/engine#51589)
2024-03-27 maRci002@users.noreply.github.com Platform channel for predictive back in route transitions on android (flutter/engine#49093)
2024-03-27 jonahwilliams@google.com [Impeller] render empty filled paths without crashing. (flutter/engine#51713)
2024-03-27 jonahwilliams@google.com [Impeller] use optimal depth attachment, remove useless barrier. (flutter/engine#51723)
Also rolling transitive DEPS:
fuchsia/sdk/core/linux-amd64 from Lk8KBU-c97RO to uzI3wnbEGlZ_
If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-engine-flutter-autoroll
Please CC jacksongardner@google.com,rmistry@google.com,zra@google.com on the revert to ensure that a human
is aware of the problem.
To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose
To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622
Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Reason for revert: https://github.com/flutter/flutter/issues/145899

authors: engine-flutter-autoroll zanderso


text:
Roll Flutter Engine from 6e722ae213bd to c0917b14fc36 (1 revision)

https://github.com/flutter/engine/compare/6e722ae213bd...c0917b14fc36
2024-05-09 jonahwilliams@google.com [Impeller] Size AHB swapchain based on vk surface properties. (flutter/engine#52692)
If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-engine-flutter-autoroll
Please CC rmistry@google.com,zra@google.com on the revert to ensure that a human
is aware of the problem.
To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose
To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622
Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

manually merging this while autosub is stuck

authors: engine-flutter-autoroll jonahwilliams


text:
Add cursorWidth and cursorRadius to TextField (Material) cursor

The cursor in TextField is currently unlike native iOS and Material cursors. This PR adds fields for cursor width and radius (how rounded the corners of the cursor RRect are) in the TextField class. The default values are configured to match native values.

Should the cursor be defined by a ShapeDecoration? Assuming that the simple cases are handled without any loss of efficiency, ShapeDecoration (which would have to plumbed all the way through to RenderEditable) would be much more flexible.

authors: HansMuller sandrasandeep


text:
Remove duplicated assets under /pkg/data

Require componentName to ensure assets are placed under /pkg/data/
TESTED=topaz tests with {fx set x64, fx set x64 --release}

@tvolkert


text:
Roll engine 6f459e2f10ca..12315736f9ca (3 commits)

https://github.com/flutter/engine/compare/6f459e2f10ca...12315736f9ca
git log 6f459e2f10ca..12315736f9ca --no-merges --oneline
12315736f Roll buildroot to c2764d3620d792e71301dff9a66866029ed200f0 (flutter/engine#6237)
1e622d24d Update to newer Skia font API (flutter/engine#6236)
87b4af095 Roll src/third_party/skia e70aed7066c6..44215505623b (1 commits) (flutter/engine#6235)
The AutoRoll server is located here: https://autoroll.skia.org/r/flutter-engine-flutter-autoroll
Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+/master/autoroll/README.md
If the roll is causing failures, please contact the current sheriff, who should
be CC'd on the roll, and stop the roller if necessary.

@rmistry @liyuqian : New roll has been created by https://autoroll.skia.org/r/flutter-engine-flutter-autoroll

Auto-roller completed checks. About to merge.


text:
Synchronizes dartdoc with dart:ui

Mostly just adds some examples to match the examples with use for
similar concepts in dart:ui.

@Hixie

lgtm

authors: Hixie abarth


text:
Roll engine ff49ca1c6e5b..4099cb14683f (25 commits)

git@github.com:flutter/engine.git/compare/ff49ca1c6e5b...4099cb14683f
git log ff49ca1c6e5b..4099cb14683f --no-merges --oneline
2019-08-11 skia-flutter-autoroll@skia.org Roll src/third_party/skia 5e7271a4598e..9c23a9e790b2 (1 commits) (flutter/engine#10838)
2019-08-11 skia-flutter-autoroll@skia.org Roll src/third_party/skia 3e7fa79f2c79..5e7271a4598e (1 commits) (flutter/engine#10827)
2019-08-10 skia-flutter-autoroll@skia.org Roll fuchsia/sdk/core/linux-amd64 from bvUCO... to xqsy5... (flutter/engine#10826)
2019-08-10 skia-flutter-autoroll@skia.org Roll src/third_party/skia 89e43889afd9..3e7fa79f2c79 (1 commits) (flutter/engine#10825)
2019-08-10 skia-flutter-autoroll@skia.org Roll src/third_party/skia fe19203eb7d7..89e43889afd9 (1 commits) (flutter/engine#10824)
2019-08-10 skia-flutter-autoroll@skia.org Roll fuchsia/sdk/core/linux-amd64 from HsuAH... to bvUCO... (flutter/engine#10822)
2019-08-10 bkonyi@google.com Roll src/third_party/dart ffefa124a7..e29d6d0ecb (4 commits)
2019-08-10 skia-flutter-autoroll@skia.org Roll src/third_party/skia af89d3972e0b..fe19203eb7d7 (5 commits) (flutter/engine#10819)
2019-08-10 bkonyi@google.com Roll src/third_party/dart 15a3bf82cb..ffefa124a7 (11 commits)
2019-08-09 chris@bracken.jp Roll Dart SDK 78ce916d82..15a3bf82cb (flutter/engine#10810)
2019-08-09 skia-flutter-autoroll@skia.org Roll src/third_party/skia b7b0b3ad538c..af89d3972e0b (7 commits) (flutter/engine#10812)
2019-08-09 jonahwilliams@google.com Revert "Remove flutter_kernel_sdk dart script (#10808)" (flutter/engine#10811)
2019-08-09 iska.kaushik@gmail.com [dart:zircon] Porting Cache re-usable handle wait objects (flutter/engine#10809)
2019-08-09 jonahwilliams@google.com Remove flutter_kernel_sdk dart script (flutter/engine#10808)
2019-08-09 cfontas@google.com change add part to add child (flutter/engine#10787)
2019-08-09 yjbanov@google.com rename stub_ui to web_ui (flutter/engine#10776)
2019-08-09 kpozin@google.com [fuchsia] Migrate from custom FuchsiaFontManager to SkFontMgr_fuchsia (flutter/engine#10700)
2019-08-09 skia-flutter-autoroll@skia.org Roll src/third_party/skia 26cedb4c603b..b7b0b3ad538c (11 commits) (flutter/engine#10807)
2019-08-09 egarciad@google.com Rename flutter_java.jar and flutter_engine.jar so they match the Maven comvention (flutter/engine#10797)
2019-08-09 skia-flutter-autoroll@skia.org Roll fuchsia/sdk/core/linux-amd64 from 9xVXx... to HsuAH... (flutter/engine#10806)
2019-08-09 bkonyi@google.com Roll src/third_party/dart 3d9a356f6e..78ce916d82 (7 commits)
2019-08-09 skia-flutter-autoroll@skia.org Roll src/third_party/skia b2151310068b..26cedb4c603b (1 commits) (flutter/engine#10804)
2019-08-09 skia-flutter-autoroll@skia.org Roll src/third_party/skia 059bf776c184..b2151310068b (3 commits) (flutter/engine#10803)
2019-08-09 bkonyi@google.com Roll src/third_party/dart f29f41f1a5..3d9a356f6e (65 commits)
2019-08-09 skia-flutter-autoroll@skia.org Roll src/third_party/skia 4d557e3df433..059bf776c184 (1 commits) (flutter/engine#10801)
The AutoRoll server is located here: https://autoroll.skia.org/r/flutter-engine-flutter-autoroll
Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+/master/autoroll/README.md
If the roll is causing failures, please contact the current sheriff (jimgraham@google.com), and stop
the roller if necessary.

Trybots failed. These were the failed builds: https://cirrus-ci.com/task/5471851566858240

Commit queue failed; closing this roll.


text:
Make it possible to create new text themes

Fixes #5916

@Hixie

LGTM but I feel that the documentation should frown on this more, given that it basically violates the material spec to do this.

Ok.  I'll add some more text that points to the spec.


text:
Revert "Update text goldens for CanvasKit 0.23"

Reverts flutter/goldens#158
Related: https://github.com/flutter/engine/pull/24461

wrong commit, need to revert https://github.com/flutter/goldens/pull/169

repo: flutter/goldens

license_source: bigquery


text:
Is it necessary to check _completer.isCompleted  when call cancelToken.cancel

* Calling [complete] or [completeError] must be done at most once.
CancelToken class
/// Cancel the request
void cancel([dynamic reason]) {
_cancelError = DioError(type: DioErrorType.CANCEL, error: reason);
_completer.complete();
}
is it necessary to check _completer.isCompleted
/// Cancel the request
void cancel([dynamic reason]) {
_cancelError = DioError(type: DioErrorType.CANCEL, error: reason);
if(!_completer.isCompleted){
_completer.complete();
}
}

i face this exception when cancel the download again download again    Bad state: Future already completed

repo: flutterchina/dio

license: MIT


text:
Cargo-flux check calls flux-driver incorrectly

I'm trying out flux. After installing (commit ce7386ce09711edf2bdc46e516aeb24b0190dbbb) I run cargo-flux check and get:
error: failed to run `rustc` to learn about target-specific information

Caused by:
  process didn't exit successfully: `/home/<user>/.cargo/bin/flux-driver /home/<user>/.rustup/toolchains/nightly-2023-06-06-x86_64-unknown-linux-gnu/bin/rustc - --crate-name ___ --print=file-names --crate-type bin --crate-type rlib --crate-type dylib --crate-type cdylib --crate-type staticlib --crate-type proc-macro --print=sysroot --print=split-debuginfo --print=crate-name --print=cfg` (exit status: 1)
  --- stderr
  error: multiple input filenames provided (first two filenames are `/home/<user>/.rustup/toolchains/nightly-2023-06-06-x86_64-unknown-linux-gnu/bin/rustc` and `-`)

I don't think the target repo matters, but I tried on tommd/toy-rust-symbolic-execution .

Hi, thanks for reporting. I also noticed this today. Apparently there was a change in the way cargo invokes rustc and it broke when I updated the tool chain here https://github.com/flux-rs/flux/commit/bae0076d8d3803138fda15429790c4d2d7a0927d

authors: TomMD nilehmann

repo: flux-rs/flux


text:
Add native python prediction service similar to java-based codegen

Explore Jython-based solution to bridge between NetflixOSS/JVM-based Microservices and Python

duplicate of https://github.com/fluxcapacitor/pipeline/issues/168

repo: fluxcapacitor/pipeline


text:
question: avoid removing chart on timeout

Scenario: I have a CRD in my chart that provisions a Cloud Database instance. Sometimes it can take 10+ minutes before the cloud provider database instance is ready. If there are many concurrent provisioning requests, it can sometimes take much longer. When a helm release timeout occurs, helm removes the resources installed by the chart. This removes the CRD that triggered the resource being created.
Question: Is there a way to prevent the controller from removing existing resources between reconciliation attempts?

Yes, there is!
Please see the section on configuring failure remediation here in the docs:
https://fluxcd.io/flux/components/helm/helmreleases/#configuring-failure-remediation
If you have configured retries, then you should also consider the remediation strategy.
See remediateLastFailure: false as explained in the doc. Hope this helps!

Hi!
The only robust way I found to install CRD is to put them into different helm chart (like linkerd did) or to put them into separate CRD kustomization which will be installed the first. Otherwise you will run many times in cyclic dependency issue - as I did. I can find better examples on GitHub but not now.

authors: daniel-garcia gaalw kingdonb

repo: fluxcd/helm-controller


text:
Import CRD docs into new site

We should potentially borrow https://github.com/fluxcd/flux2/blob/main/.github/workflows/docs.yaml and plug it into our Makefile somewhere, so we have all relevant CRD docs available too.
Potentially check if we need to add frontmatter?

3:54:23 PM: Error: Error building site: "/opt/build/repo/content/en/docs/components/helm/api.md:1:1": plain HTML documents not supported

hugo is not pleased.

Ok, issue is resolved.

This was fixed as part of #130

repo: fluxcd/website


text:
🛑 AOL is down

In 672b8fe, AOL (https://extranet.osam.org.ar/OSAM) was down:

HTTP code: 0
Response time: 0 ms

Resolved: AOL is back up in 77779ef.

repo: flvanney/OSAMuptime


text:
Documentation index is broken in HowTo-> Installation

Under How To -> Installation, the index is picking comments from the vagrant console examples as items, so it's showing lots of items which are confusing.
Also, the Contributing section feels a little bit burried under API-docs. This may not be an error but don't you think this info should be in it's own header?

This has been fixed.

authors: adrianmoya titanous

repo: flynn/flynn


text:
CLI updates with TUF

This removes the old distribution toolchain inherited from hk and replaces it with an updater that uses TUF. The same TUF repo that is used to distribute the rest of the container images and binaries is used.
script/export-components is updated to add the cross-compiled flynn CLI binaries to the repo tagged with their version. The CLI will be released and versioned as part of the nightly build process instead of using a separate version tag and build system.
Closes #1087
TODO

[x] Set User-Agent for flynn-host and flynn-cli TUF clients
[ ] Implement redirect server and replace CLI installation snippets in docs

LGTM

@lmars this should be good to go, please re-review, I've fixed a bunch of stuff and added the User-Agent.

LGTM

authors: lmars titanous


text:
SQLPlus Multiple set commands on same line

Which version and edition of Flyway are you using?
flyway-5.2.1 Enterprise
Which client are you using? (Command-line, Java API, Maven plugin, Gradle plugin)
command-line
Which database are you using (type & version)?
Oracle 12.1
Which operating system are you using?
Windows 10
What did you do?
sqlplus script with the initial line: set define off verify off feedback off
command: flyway -enterprise migrate
What did you expect to see?
That set define off would be processed and the &var placeholders ignored
What did you see instead?
The multiple set options on the same line means set define off is not processed.  As a result the &placeholders are attempted to be evaluated and script fails.
The script is an auto generated export of an Oracle Apex application, so editing the file is not encouraged.
In addition, the set verify and set feedback commands are ignored.

Thanks for the report. As part of the fix for this issue we're adding support for

[X] PROMPT without arguments
[ ] SET without arguments
[ ] SET with multiple arguments
[ ] SET VERIFY
[ ] SET FEEDBACK
[X] SHOW without arguments
[X] SHOW with multiple arguments
[X] SHOW DEFINE
[X] SHOW ESCAPE
[ ] SHOW FEEDBACK
[X] SHOW NULL
[ ] SHOW VERIFY

This has now been implemented and will be released in the next few days as part of 5.2.2.

authors: axelfontaine pjchester

repo: flyway/flyway


text:
Issue#3614 Use default database storage engine for flyway migration table

See #3641
Project builds, not sure how to run tests
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
[INFO] flyway-parent 9.16.1 ............................... SUCCESS [  0.481 s]
[INFO] flyway-core 9.16.1 ................................. SUCCESS [  9.087 s]
[INFO] flyway-mysql 9.16.1 ................................ SUCCESS [  0.526 s]
[INFO] flyway-community-db-support 9.16.1 ................. SUCCESS [  0.490 s]
[INFO] flyway-gradle-plugin 9.16.1 ........................ SUCCESS [  0.080 s]
[INFO] flyway-maven-plugin 9.16.1 ......................... SUCCESS [  1.581 s]
[INFO] flyway-gcp-bigquery 9.16.1 ......................... SUCCESS [  0.440 s]
[INFO] flyway-gcp-spanner 9.16.1-beta ..................... SUCCESS [  0.721 s]
[INFO] flyway-sqlserver 9.16.1 ............................ SUCCESS [  0.712 s]
[INFO] flyway-firebird 9.16.1 ............................. SUCCESS [  0.528 s]
[INFO] flyway-commandline 9.16.1 .......................... SUCCESS [  0.244 s]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  15.230 s
[INFO] Finished at: 2023-03-24T12:02:22-07:00
[INFO] ------------------------------------------------------------------------

 Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.You have signed the CLA already but the status is still pending? Let us recheck it.

Thank you for your contribution, this has been incorporated into Flyway 10.22.0 released yesterday


text:
Login with Evernote

Implement login with Evernote and show a greeting to the user.

Evernote integration guide: https://dev.evernote.com/doc/start/javascript.php
JavaScript SDK: https://github.com/evernote/evernote-sdk-js/tree/master/evernote-sdk-js/production
Looking for an alternative to OAuth module because we aren't using Cordova as in the examples.

repo: fmoliveira/tantalus

license: mit


text:
BucketSort.cpp

This solves #243

Thanks for contributing!

repo: fnplus/interview-techdev-guide


text:
create timer-component for fo0/ScrumTool#24

Implementation for: fo0/ScrumTool#24
Dark:

Light:

the component syncronized itself with other participants of the board that have the same id (as with the previous component)

looks fantastic, thanks for the PR