Keyboard disappearing when focussing on TextFormField

Whenever I try to enter text into a TextFormField, the keyboard pops up for a brief second and hides away instantly.
I read up on this and tried setting GlobalKeys (_k1, _k2) for the fields, however the keyboard still disappears instantly.
class Login extends StatefulWidget {
  @override
  State createState() => new _LoginState();
}

class _LoginState extends State<Login> {
  GlobalKey<FormState> _formKey = new GlobalKey<FormState>();
  Key _k1 = new GlobalKey();
  Key _k2 = new GlobalKey();
  String _email, _password;

  @override
  Widget build(BuildContext context) {
    print("building login");
    double _screenHeight = MediaQuery.of(context).size.height;

    return new Padding(
      padding: new EdgeInsets.all(50.0),
      child: new Form(
        key: _formKey,
        child: new ListView(
          children: <Widget>[
            new TextFormField(
              key: _k1,
              decoration: new InputDecoration(labelText: 'E-Mail'),
            ),
            new TextFormField(
              key: _k2,
              decoration: new InputDecoration(labelText: 'Password'),
              obscureText: true,
            ),
            new Padding(
              padding: new EdgeInsets.only(top: _screenHeight * 0.04),
              child: new RaisedButton(
                onPressed: _submit,
                child: new Text('Login'),
              ),
            ),
          ],
          physics: new ClampingScrollPhysics(),
        ),
      ),
    );
  }
}

[✓] Flutter (Channel master, v0.5.8-pre.187, on Linux, locale en_US.UTF-8)
    • Flutter version 0.5.8-pre.187 at /home/tobi/Development/flutter
    • Framework revision 12eff1d5da (11 hours ago), 2018-07-31 08:05:24 +0100
    • Engine revision af855e063a
    • Dart version 2.0.0-dev.69.4.flutter-08f59e5de3

[✓] Android toolchain - develop for Android devices (Android SDK 27.0.3)
    • Android SDK at /home/tobi/Android/Sdk
    • Android NDK location not configured (optional; useful for native profiling support)
    • Platform android-27, build-tools 27.0.3
    • Java binary at: /home/tobi/Development/android-studio/jre/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1024-b01)
    • All Android licenses accepted.

[✓] Android Studio (version 3.1)
    • Android Studio at /home/tobi/Development/android-studio
    • Flutter plugin version 24.2.1
    • Dart plugin version 173.4700
    • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1024-b01)

[✓] VS Code (version 1.25.1)
    • VS Code at /usr/share/code
    • Flutter extension version 2.16.0

[✓] Connected devices (1 available)
    • Pixel • FA69V0308230 • android-arm64 • Android 9 (API 28)

• No issues found!

Try with static ... _formKey ...
static GlobalKey<FormState> _formKey = new GlobalKey<FormState>();

Currently the key is recreated every time _LoginState is rebuilt, which defeats it's purpose.

After making the key static, once I click on an input field, the app gets stuck in a render-loop, constantly calling the build-Method of the state.
The following error get's thrown:
I/flutter ( 2025): The following assertion was thrown building Login(state: _LoginState#aec0f):
I/flutter ( 2025): Multiple widgets used the same GlobalKey.
I/flutter ( 2025): The key [LabeledGlobalKey<FormState>#11740] was used by multiple widgets. The parents of those
I/flutter ( 2025): widgets were:
I/flutter ( 2025): - Padding(padding: EdgeInsets.all(50.0), renderObject: RenderPadding#51170 NEEDS-LAYOUT NEEDS-PAINT)
I/flutter ( 2025): - Padding(padding: EdgeInsets.all(50.0), renderObject: RenderPadding#3d72d relayoutBoundary=up3
I/flutter ( 2025):   NEEDS-LAYOUT)
I/flutter ( 2025): A GlobalKey can only be specified on one widget at a time in the widget tree.

To me, it looks like the Widget is somehow rendered twice at the same time, given that the parent (in the error message) is the Padding I'm using both times.

Looks like this is not an issue with flutter in my case.
I followed up on the problem over here: theyakka/fluro#57

This happens when you put GlobalKey in your build function

I was having the same problem, after changing every GlobalKey to static final it worked flawlessly.
Notice, if you have multiple FocusNode() they have to be static final too.

This happens when you put GlobalKey<FormState> in your build function

Yes, exactly. Thanks!

@jeen0404, yes, this is the solution Thanks!

tente usar resizeToAvoidBottomPadding: false,  em seu Scaffold

I/art     (31941): Do partial code cache collection, code=28KB, data=30KB
I/art     (31941): After code cache collection, code=27KB, data=29KB
I/art     (31941): Increasing code cache capacity to 128KB
I/SurfaceView(31941): updateWindow -- setFrame, this = io.flutter.view.FlutterView{5ddbdbf VFE...... .F....I. 0,0-1080,2016}
I/SurfaceView(31941): updateWindow -- setFrame, this = io.flutter.view.FlutterView{5ddbdbf VFE...... .F....I. 0,0-1080,2016}
I/SurfaceView(31941): updateWindow -- setFrame, this = io.flutter.view.FlutterView{5ddbdbf VFE...... .F....I. 0,0-1080,2016}
I/SurfaceView(31941): updateWindow -- setFrame, this = io.flutter.view.FlutterView{5ddbdbf VFE...... .F....I. 0,0-1080,2016}
I/SurfaceView(31941): updateWindow -- setFrame, this = io.flutter.view.FlutterView{5ddbdbf VFE...... .F....I. 0,0-1080,2016}
I/SurfaceView(31941): updateWindow -- setFrame, this = io.flutter.view.FlutterView{5ddbdbf VFE...... .F....I. 0,0-1080,2016}
I/SurfaceView(31941): updateWindow -- setFrame, this = io.flutter.view.FlutterView{5ddbdbf VFE...... .F....I. 0,0-1080,2016}
I/SurfaceView(31941): updateWindow -- setFrame, this = io.flutter.view.FlutterView{5ddbdbf VFE...... .F....I. 0,0-1080,2016}
I/SurfaceView(31941): updateWindow -- setFrame, this = io.flutter.view.FlutterView{5ddbdbf VFE...... .F....I. 0,0-1080,2016}
I/SurfaceView(31941): updateWindow -- setFrame, this = io.flutter.view.FlutterView{5ddbdbf VFE...... .F....I. 0,0-1080,2016}
I/SurfaceView(31941): updateWindow -- setFrame, this = io.flutter.view.FlutterView{5ddbdbf VFE...... .F....I. 0,0-1080,2016}
I/SurfaceView(31941): updateWindow -- setFrame, this = io.flutter.view.FlutterView{5ddbdbf VFE...... .F....I. 0,0-1080,2016}
I/SurfaceView(31941): updateWindow -- setFrame, this = io.flutter.view.FlutterView{5ddbdbf VFE...... .F....I. 0,0-1080,2016}
I/SurfaceView(31941): updateWindow -- setFrame, this = io.flutter.view.FlutterView{5ddbdbf VFE...... .F....I. 0,0-1080,2016}
I/SurfaceView(31941): updateWindow -- setFrame, this = io.flutter.view.FlutterView{5ddbdbf VFE...... .F....I. 0,0-1080,2016}
I/SurfaceView(31941): updateWindow -- setFrame, this = io.flutter.view.FlutterView{5ddbdbf VFE...... .F....I. 0,0-1080,2016}

I was having the same problem, after changing every GlobalKey to static final it worked flawlessly.
Notice, if you have multiple FocusNode() they have to be static final too.

I had the same problem and then I added static before the final and it worked like magic!

I was having the same problem, after changing every GlobalKey to static final it worked flawlessly.
Notice, if you have multiple FocusNode() they have to be static final too.

I had the same problem and then I added static before the final and it worked like magic!

Static key did not fix it for me.
I had this problem because of my Navigator... when home was not defined on the MainApp it was closing the keyboard automatically for all my inputs. Basically I was manually using the routes key and setting / manually.

@codymoorhouse Damn, I was struggle with exactly the issue for days, Until saw your answer. Thank you very much.  but, I'm just wondering, How do you know that was the issue and why that was the case ?

Hey @CharlesCCC, glad to hear it helped! I only discovered it through some experimentation, and it was the last thing I worked on before it started getting glitchy. I tried a few things that I found online, but in the end I just played with routes and discovered that was the issue for me. Hope that helps!

class Login extends StatefulWidget {
  @override
  State createState() => new _LoginState();
}

class _LoginState extends State<Login> {

  static final _formKey = new GlobalKey<FormState>();   /// just  define _formkey with static final

  Key _k1 = new GlobalKey();
  Key _k2 = new GlobalKey();
  String _email, _password;

  @override
  Widget build(BuildContext context) {
    print("building login");
    double _screenHeight = MediaQuery.of(context).size.height;

    return new Padding(
      padding: new EdgeInsets.all(50.0),
      child: new Form(
        key: _formKey,
        child: new ListView(
          children: <Widget>[
            new TextFormField(
              key: _k1,
              decoration: new InputDecoration(labelText: 'E-Mail'),
            ),
            new TextFormField(
              key: _k2,
              decoration: new InputDecoration(labelText: 'Password'),
              obscureText: true,
            ),
            new Padding(
              padding: new EdgeInsets.only(top: _screenHeight * 0.04),
              child: new RaisedButton(
                onPressed: _submit,
                child: new Text('Login'),
              ),
            ),
          ],
          physics: new ClampingScrollPhysics(),
        ),
      ),
    );
  }
}

define _formkey with static final ...
and if it's not work remove k1 and k2 key form TextFormField
after that if you want to validate and save form you can use
   void validate(){
      final form=_formKey.currentState;
     if(form.validate()){
       form.save()
       print(_username);
       print(_password);
     }
    }

It is solved my probelm.

static GlobalKey _formKey = new GlobalKey();

My Form is inside a loop, as I am rendering multiple different forms, hence i need seperate _formKey . How can i solve that ? If i use the same static formKey i get:
Multiple widgets used the same GlobalKey.

I was having the same problem, after changing every GlobalKey to static final it worked flawlessly.
Notice, if you have multiple FocusNode() they have to be static final too.

yes this has solved my problem too

I was having the same problem, after changing every GlobalKey to static final it worked flawlessly.
Notice, if you have multiple FocusNode() they have to be static final too.

yes this has solved my problem too

when i use static final , it shows me this error
type 'int' is not a subtype of type 'GlobalKey<FormState>' of 'function result'
i am using a stateless class with changenotifierprovider and the key is defined outside the build function, any clue?

I was having the same problem, after changing every GlobalKey to static final it worked flawlessly.
Notice, if you have multiple FocusNode() they have to be static final too.

yes this has solved my problem too

when i use static final , it shows me this error
type 'int' is not a subtype of type 'GlobalKey<FormState>' of 'function result'
i am using a stateless class with changenotifierprovider and the key is defined outside the build function, any clue?

Can you please elaborate

I wouldn't use static final. Lets say you build two of the same widget, they will be sharing the same global key.

tente usar
resizeToAvoidBottomPadding: false,
em seu Scaffold

You saved my day, Thanks

okay my problem is solved but i don't know why i had to make it static final or get the global out of the build method can any one of you tell me what is the reason for this problem and why doing that solved it

I am facing the same problem, the code "resizeToAvoidBottomPadding: true" causes it in my case. But I need this code, because without it keyboard will cover my TextField.
So how to resolve this issue?

Same for me, but the fun thing is switching to another TextField seems to fix the jumping.

I am having the same issue with the keyboard, so I changed the key to static and it works. But I have a page with many tabs, each tab have a form generated by a class. If I change the key to static, the forms stop working because they share the same static key... What can I do to solve this?

I'm having this problem too : (
My Widget TextField() out of nowhere it started to be a problem. Open and close the keyboard im miliseconds.
import 'package:agricultura/src/data.dart';
import 'package:flutter/material.dart';

class ChatPV extends StatefulWidget {
  ChatPV({Key key, this.name, this.messages, this.image}) : super(key: key);
  final String name;
  final List messages;
  final String image;
  @override
  _ChatPVState createState() => _ChatPVState();
}

class _ChatPVState extends State<ChatPV> {
  List messages;
  String _text;
  @override
  void initState() {
    // TODO: implement initState
    messages = widget.messages;
    super.initState();
  }

  @override
  Widget build(BuildContext context) {
    Size size = MediaQuery.of(context).size;
    return Scaffold(
        body: SingleChildScrollView(
          child: Column(children: [
            ClipRRect(
              borderRadius: BorderRadius.only(
                  bottomLeft: Radius.circular(60),
                  bottomRight: Radius.circular(60)),
              child: Container(
                  color: Colors.green,
                  height: size.height * 0.2,
                  child: Column(
                    children: [
                      Padding(
                          padding: EdgeInsets.only(top: 40),
                          child: Row(
                            mainAxisAlignment: MainAxisAlignment.center,
                            children: [
                              Padding(
                                padding: EdgeInsets.only(right: 3),
                                child: BackButton(
                                  color: Colors.white,
                                ),
                              ),
                              Padding(
                                padding: EdgeInsets.only(right: 5),
                                child: ClipRRect(
                                  borderRadius: BorderRadius.circular(60),
                                  child: Container(
                                    height: size.height * 0.09,
                                    width: size.width * 0.65,
                                    color: Colors.white,
                                    child: Row(
                                      children: [
                                        Padding(
                                          padding: EdgeInsets.all(2),
                                          child: ClipRRect(
                                            child: Image.asset(widget.image),
                                            borderRadius:
                                                BorderRadius.circular(40),
                                          ),
                                        ),
                                        Text(
                                          widget.name,
                                          style: TextStyle(fontSize: 16),
                                        ),
                                      ],
                                    ),
                                  ),
                                ),
                              ),
                              ClipRRect(
                                borderRadius: BorderRadius.circular(60),
                                child: Container(
                                    height: 60,
                                    width: 60,
                                    color: Colors.white,
                                    child: IconButton(
                                      icon: Icon(
                                        Icons.dehaze,
                                        color: Colors.black,
                                      ),
                                      onPressed: () {},
                                      tooltip: "Menu usuário",
                                    )),
                              ),
                            ],
                          )),
                      Divider(
                        height: 8,
                        color: Colors.green,
                      ),
                      Text(
                        "On-line",
                        style: TextStyle(color: Colors.white, fontSize: 16),
                      )
                    ],
                  )),
            ),
            Container(
                width: 1000,
                height: 200,
                child: ListView.builder(
                  itemBuilder: (context, index) {
                    return ClipRRect(
                      child: GestureDetector(
                          onLongPress: () {},
                          child: Card(
                            child: Padding(
                              padding: EdgeInsets.all(10),
                              child: Text(messages[index]),
                            ),
                          )),
                      borderRadius: BorderRadius.circular(40),
                    );
                  },
                  itemCount: messages.length,
                ))
          ]),
        ),
        /*floatingActionButtonAnimator: FloatingActionButtonAnimator.scaling,
        floatingActionButtonLocation:
            FloatingActionButtonLocation.miniEndDocked,
        floatingActionButton: FloatingActionButton(
          backgroundColor: Colors.green,
          onPressed: () {},
          child: Icon(Icons.chat_bubble_outline),
        ),*/
        bottomSheet: Row(
          children: [
            Padding(
              padding: EdgeInsets.only(bottom: 5, left: 5, right: 5),
              child: ClipRRect(
                  borderRadius: BorderRadius.circular(40),
                  child: Container(
                    width: 50,
                    height: 50,
                    color: Colors.green,
                    child: IconButton(
                        tooltip: "Arquivos",
                        icon: Icon(
                          Icons.attachment,
                          color: Colors.white,
                        ),
                        onPressed: () {}),
                  )),
            ),
            Padding(
              padding: EdgeInsets.only(bottom: 10),
              child: ClipRRect(
                  borderRadius: BorderRadius.circular(40),
                  child: Container(
                    padding: EdgeInsets.only(left: 20, right: 15),
                    color: Colors.green[100],
                    width: size.width * 0.8,
                    height: size.height * 0.07,
                    child: TextField(
                      onChanged: (value) {
                        setState(() {
                          _text = value;
                        });
                      },
                      autocorrect: true,
                      autofocus: false,
                      onSubmitted: (value) => messages.add(_text),
                      maxLines: 60,
                      keyboardType: TextInputType.text,
                      cursorColor: Colors.green[900],
                      textCapitalization: TextCapitalization.sentences,
                      decoration: InputDecoration(
                          border: InputBorder.none,
                          enabledBorder: InputBorder.none,
                          hintText: "Digite sua mensagem aqui..."),
                    ),
                  )),
            )
          ],
        ));
  }
}

Just create the form key out of the builder method. Try initState() instead.
Em seg, 28 de set de 2020 20:48, Ramon Paolo Maran<EMAIL_ADDRESS>escreveu:

I'm having this problem too : (
My Widget TextField() out of nowhere it started to be a problem. Open and
close the keyboard im miliseconds.
import 'package:agricultura/src/data.dart';
import 'package:flutter/material.dart';
class ChatPV extends StatefulWidget {
ChatPV({Key key, this.name, this.messages, this.image}) : super(key: key);
final String name;
final List messages;
final String image;
@override
_ChatPVState createState() => _ChatPVState();
}
class _ChatPVState extends State {
List messages;
String _text;
@override
void initState() {
// TODO: implement initState

messages = widget.messages;

super.initState();

}
@override
Widget build(BuildContext context) {
Size size = MediaQuery.of(context).size;

return Scaffold(

    body: SingleChildScrollView(

      child: Column(children: [

        ClipRRect(

          borderRadius: BorderRadius.only(

              bottomLeft: Radius.circular(60),

              bottomRight: Radius.circular(60)),

          child: Container(

              color: Colors.green,

              height: size.height * 0.2,

              child: Column(

                children: [

                  Padding(

                      padding: EdgeInsets.only(top: 40),

                      child: Row(

                        mainAxisAlignment: MainAxisAlignment.center,

                        children: [

                          Padding(

                            padding: EdgeInsets.only(right: 3),

                            child: BackButton(

                              color: Colors.white,

                            ),

                          ),

                          Padding(

                            padding: EdgeInsets.only(right: 5),

                            child: ClipRRect(

                              borderRadius: BorderRadius.circular(60),

                              child: Container(

                                height: size.height * 0.09,

                                width: size.width * 0.65,

                                color: Colors.white,

                                child: Row(

                                  children: [

                                    Padding(

                                      padding: EdgeInsets.all(2),

                                      child: ClipRRect(

                                        child: Image.asset(widget.image),

                                        borderRadius:

                                            BorderRadius.circular(40),

                                      ),

                                    ),

                                    Text(

                                      widget.name,

                                      style: TextStyle(fontSize: 16),

                                    ),

                                  ],

                                ),

                              ),

                            ),

                          ),

                          ClipRRect(

                            borderRadius: BorderRadius.circular(60),

                            child: Container(

                                height: 60,

                                width: 60,

                                color: Colors.white,

                                child: IconButton(

                                  icon: Icon(

                                    Icons.dehaze,

                                    color: Colors.black,

                                  ),

                                  onPressed: () {},

                                  tooltip: "Menu usuário",

                                )),

                          ),

                        ],

                      )),

                  Divider(

                    height: 8,

                    color: Colors.green,

                  ),

                  Text(

                    "On-line",

                    style: TextStyle(color: Colors.white, fontSize: 16),

                  )

                ],

              )),

        ),

        Container(

            width: 1000,

            height: 200,

            child: ListView.builder(

              itemBuilder: (context, index) {

                return ClipRRect(

                  child: GestureDetector(

                      onLongPress: () {},

                      child: Card(

                        child: Padding(

                          padding: EdgeInsets.all(10),

                          child: Text(messages[index]),

                        ),

                      )),

                  borderRadius: BorderRadius.circular(40),

                );

              },

              itemCount: messages.length,

            ))

      ]),

    ),

    /*floatingActionButtonAnimator: FloatingActionButtonAnimator.scaling,

    floatingActionButtonLocation:

        FloatingActionButtonLocation.miniEndDocked,

    floatingActionButton: FloatingActionButton(

      backgroundColor: Colors.green,

      onPressed: () {},

      child: Icon(Icons.chat_bubble_outline),

    ),*/

    bottomSheet: Row(

      children: [

        Padding(

          padding: EdgeInsets.only(bottom: 5, left: 5, right: 5),

          child: ClipRRect(

              borderRadius: BorderRadius.circular(40),

              child: Container(

                width: 50,

                height: 50,

                color: Colors.green,

                child: IconButton(

                    tooltip: "Arquivos",

                    icon: Icon(

                      Icons.attachment,

                      color: Colors.white,

                    ),

                    onPressed: () {}),

              )),

        ),

        Padding(

          padding: EdgeInsets.only(bottom: 10),

          child: ClipRRect(

              borderRadius: BorderRadius.circular(40),

              child: Container(

                padding: EdgeInsets.only(left: 20, right: 15),

                color: Colors.green[100],

                width: size.width * 0.8,

                height: size.height * 0.07,

                child: TextField(

                  onChanged: (value) {

                    setState(() {

                      _text = value;

                    });

                  },

                  autocorrect: true,

                  autofocus: false,

                  onSubmitted: (value) => messages.add(_text),

                  maxLines: 60,

                  keyboardType: TextInputType.text,

                  cursorColor: Colors.green[900],

                  textCapitalization: TextCapitalization.sentences,

                  decoration: InputDecoration(

                      border: InputBorder.none,

                      enabledBorder: InputBorder.none,

                      hintText: "Digite sua mensagem aqui..."),

                ),

              )),

        )

      ],

    ));

}
}
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/flutter/flutter/issues/20042#issuecomment-700341228,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAJ7N2F5VFIPTQTYY2K2AJDSIEOE5ANCNFSM4FNDALMA
.

Just create the form key out of the builder method. Try initState() instead. Em seg, 28 de set de 2020 20:48, Ramon Paolo Maran<EMAIL_ADDRESS>escreveu:
…
I'm having this problem too : ( My Widget TextField() out of nowhere it started to be a problem. Open and close the keyboard im miliseconds. import 'package:agricultura/src/data.dart'; import 'package:flutter/material.dart'; class ChatPV extends StatefulWidget { ChatPV({Key key, this.name, this.messages, this.image}) : super(key: key); final String name; final List messages; final String image; @override _ChatPVState createState() => _ChatPVState(); } class _ChatPVState extends State { List messages; String _text; @override void initState() { // TODO: implement initState messages = widget.messages; super.initState(); } @override Widget build(BuildContext context) { Size size = MediaQuery.of(context).size; return Scaffold( body: SingleChildScrollView( child: Column(children: [ ClipRRect( borderRadius: BorderRadius.only( bottomLeft: Radius.circular(60), bottomRight: Radius.circular(60)), child: Container( color: Colors.green, height: size.height * 0.2, child: Column( children: [ Padding( padding: EdgeInsets.only(top: 40), child: Row( mainAxisAlignment: MainAxisAlignment.center, children: [ Padding( padding: EdgeInsets.only(right: 3), child: BackButton( color: Colors.white, ), ), Padding( padding: EdgeInsets.only(right: 5), child: ClipRRect( borderRadius: BorderRadius.circular(60), child: Container( height: size.height * 0.09, width: size.width * 0.65, color: Colors.white, child: Row( children: [ Padding( padding: EdgeInsets.all(2), child: ClipRRect( child: Image.asset(widget.image), borderRadius: BorderRadius.circular(40), ), ), Text( widget.name, style: TextStyle(fontSize: 16), ), ], ), ), ), ), ClipRRect( borderRadius: BorderRadius.circular(60), child: Container( height: 60, width: 60, color: Colors.white, child: IconButton( icon: Icon( Icons.dehaze, color: Colors.black, ), onPressed: () {}, tooltip: "Menu usuário", )), ), ], )), Divider( height: 8, color: Colors.green, ), Text( "On-line", style: TextStyle(color: Colors.white, fontSize: 16), ) ], )), ), Container( width: 1000, height: 200, child: ListView.builder( itemBuilder: (context, index) { return ClipRRect( child: GestureDetector( onLongPress: () {}, child: Card( child: Padding( padding: EdgeInsets.all(10), child: Text(messages[index]), ), )), borderRadius: BorderRadius.circular(40), ); }, itemCount: messages.length, )) ]), ), /floatingActionButtonAnimator: FloatingActionButtonAnimator.scaling, floatingActionButtonLocation: FloatingActionButtonLocation.miniEndDocked, floatingActionButton: FloatingActionButton( backgroundColor: Colors.green, onPressed: () {}, child: Icon(Icons.chat_bubble_outline), ),/ bottomSheet: Row( children: [ Padding( padding: EdgeInsets.only(bottom: 5, left: 5, right: 5), child: ClipRRect( borderRadius: BorderRadius.circular(40), child: Container( width: 50, height: 50, color: Colors.green, child: IconButton( tooltip: "Arquivos", icon: Icon( Icons.attachment, color: Colors.white, ), onPressed: () {}), )), ), Padding( padding: EdgeInsets.only(bottom: 10), child: ClipRRect( borderRadius: BorderRadius.circular(40), child: Container( padding: EdgeInsets.only(left: 20, right: 15), color: Colors.green[100], width: size.width * 0.8, height: size.height * 0.07, child: TextField( onChanged: (value) { setState(() { _text = value; }); }, autocorrect: true, autofocus: false, onSubmitted: (value) => messages.add(_text), maxLines: 60, keyboardType: TextInputType.text, cursorColor: Colors.green[900], textCapitalization: TextCapitalization.sentences, decoration: InputDecoration( border: InputBorder.none, enabledBorder: InputBorder.none, hintText: "Digite sua mensagem aqui..."), ), )), ) ], )); } } — You are receiving this because you commented. Reply to this email directly, view it on GitHub <#20042 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAJ7N2F5VFIPTQTYY2K2AJDSIEOE5ANCNFSM4FNDALMA .

Sorry, did not work

I discovered the error of my app. I just removed the line: Size size = MediaQuery.of(context).size; that returned to normal operation. But I don't know why only one variable made it happen

I had a key: UniqueKey(), in my CustomScrollView(), which caused the keyboard to close automatically on focus, removing this line fixed it. (CupertinoTextField)

This happens when you put GlobalKey<FormState> in your build function

This solved it for me.  Thanks a lot.

I have the same issue till now ...  i tried every single way mentioned over here....
here my fresh code .... please help me !
class ResetEmail extends StatefulWidget {
@override
_ResetEmailState createState() => _ResetEmailState();
}
class _ResetEmailState extends State {
bool isLoading = false;
static final _formKey = GlobalKey();
var emailController = TextEditingController();
@override
Widget build(BuildContext context) {
var _width = MediaQuery.of(context).size.width;
var _height = MediaQuery.of(context).size.height;
return Scaffold(
  appBar: AppBar(
    leading: IconButton(
      icon: Icon(Icons.arrow_back, color: colorBlack),
      onPressed: () => Navigator.of(context).pop(),
    ),
    elevation: 0,
    backgroundColor: colorWhite,
  ),
  body: SingleChildScrollView(
    child: Container(
      padding: EdgeInsets.all(20),
      child: Form(
        key: _formKey,
        child: Column(
          children: [
            SizedBox(
              height: _height * 0.04,
            ),
            Align(
                alignment: Alignment.centerLeft,
                child: Text(
                  "Enter Your Email",
                  style: TextStyle(
                      fontSize: 28,
                      color: colorBlack,
                      fontWeight: FontWeight.w800),
                  // style: TextStyle(color: colorBlack, fontSize: 28),
                )),
            SizedBox(height: 4),
            Align(
                alignment: Alignment.centerLeft,
                child: Text(
                  "Check registered E-mail Address for\nReseting Password",
                  style: TextStyle(fontSize: 15),
                )),
            SizedBox(
              height: 35,
            ),
            Align(
                alignment: Alignment.centerLeft,
                child: Text(
                  "E-mail",
                  style: TextStyle(fontSize: fontSizeEighteen),
                )),
            SizedBox(
              height: _height * 0.02,
            ),
            TextFormField(
              controller: emailController,
              validator: (value) {
                if (value.isEmpty) {
                  return "Enter Valid Email name";
                } else if (value.trim().isEmpty) {
                  return "Enter Valid Password name";
                }
              },
              decoration: new InputDecoration(
                border: new OutlineInputBorder(
                  borderRadius: const BorderRadius.all(
                    const Radius.circular(6.0),
                  ),
                ),
                filled: true,
              ),
            ),
            SizedBox(
              height: _height * 0.05,
            ),
            isLoading
                ? Align(
                    alignment: Alignment.center, child: CircularLoader())
                : SizedBox(
                    width: _width * 0.9,
                    height: _height * 0.08,
                    child: RaisedButton(
                      color: colorBlack,
                      shape: RoundedRectangleBorder(
                        borderRadius: BorderRadius.circular(10.0),
                      ),
                      onPressed: () {
                        if (_formKey.currentState.validate()) {
                          _formKey.currentState.save();

                          _resetPassword(emailController.text);
                          //print(emailController.text);
                          // here forgotPassword method call
                        }
                      },
                      child: Text(
                        'Continue',
                        style: TextStyle(
                            color: colorWhite, fontSize: fontSizeEighteen),
                      ),
                    ),
                  ),
          ],
        ),
      ),
    ),
  ),
);

}

I discovered the error of my app. I just removed the line: Size size = MediaQuery.of(context).size; that returned to normal operation. But I don't know why only one variable made it happen

I also went through something similar. Thanks for the tip.

I was having the same problem, after changing every GlobalKey to static final it worked flawlessly.
Notice, if you have multiple FocusNode() they have to be static final too.

I had the same problem and then I added static before the final and it worked like magic!

Static key did not fix it for me.
I had this problem because of my Navigator... when home was not defined on the MainApp it was closing the keyboard automatically for all my inputs. Basically I was manually using the routes key and setting / manually.

Hi, can you describe what you did? Preferably with some sample codes. I've been bugged with this for weeks now..

I'm facing this issue where on Android my keyboard doesn't show up from times to time, mostly when the app goes into background and comes back. also when route changes let's say from home to this sign up route.
`class _SignUpState extends State {
static final GlobalKey _formState = new GlobalKey();
GlobalKey _scaffoldKey = new GlobalKey();
TextEditingController _phoneTextEditController = new TextEditingController();
String phoneCode = "250";
bool isLoading = false;
@override
void initState() {
super.initState();
}
@override
Widget build(BuildContext context) {
return Scaffold(
resizeToAvoidBottomInset: true,
key: _scaffoldKey,
backgroundColor: Colors.white,
appBar: AppBar(
actions: [ChangeLanguage()],
automaticallyImplyLeading: false,
),
body: Column(
crossAxisAlignment: CrossAxisAlignment.center,
mainAxisSize: MainAxisSize.max,
children: [
Expanded(
child: SingleChildScrollView(
child: ListView(
shrinkWrap: false,
children: [
Column(
crossAxisAlignment: CrossAxisAlignment.center,
children: [
SizedBox(
height: 25.0,
),
Container(
padding: EdgeInsets.all(10.0),
child: Center(
child: Image.asset(
'assets/on_time.png',
width: MediaQuery.of(context).size.width * 0.35,
),
),
),
SizedBox(height: 10.0),
Container(
padding: EdgeInsets.symmetric(horizontal: 35.0),
child: Form(
key: _formState,
child: Center(
child: Column(
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
mainAxisSize: MainAxisSize.min,
children: [
Center(
child: Text(
getTranslated(context, "get_started"),
style: GoogleFonts.lato(
textStyle: TextStyle(
fontSize: 16,
fontWeight: FontWeight.bold))),
),
Center(
child: Text(
getTranslated(
context, "sign_in_to_continue"),
style: GoogleFonts.lato(
textStyle: TextStyle(
fontWeight: FontWeight.bold,
fontSize: 18.0,
color: Colors.black.withOpacity(0.4),
),
)),
),
Padding(
padding: EdgeInsets.only(
left: 1.0,
right: 1.0,
top: 20.0,
),
child: Text(
getTranslated(context, "phone_number"),
textAlign: TextAlign.left,
style:
Theme.of(context).textTheme.bodyText1,
),
),
Card(
elevation: 0.0,
margin: EdgeInsets.only(top: 10.0),
shape: RoundedRectangleBorder(
side: BorderSide(
color: Colors.black.withOpacity(0.15),
width: 1.0,
),
borderRadius: BorderRadius.all(
Radius.circular(5.0))),
child: Padding(
padding: EdgeInsets.symmetric(
horizontal: 10.0, vertical: 0.0),
child: Row(
mainAxisSize: MainAxisSize.max,
children: [
CountryCodePicker(
onChanged: print,
initialSelection: 'RW',
// optional. Shows only country name and flag
showFlagDialog: true,
// optional. Shows only country name and flag when popup is closed.
showOnlyCountryWhenClosed: false,
// optional. aligns the flag and the Text left
alignLeft: false,
textStyle: TextStyle(
fontWeight: FontWeight.bold),
),
Expanded(
child: Padding(
padding: const EdgeInsets.only(
left: 4.0),
child: TextFormField(
autofocus: true,
controller:
_phoneTextEditController,
keyboardType:
TextInputType.number,
style: TextStyle(
fontWeight: FontWeight.bold),
textInputAction:
TextInputAction.done,
validator: (v) => v.isEmpty
? getTranslated(context,
"phone_number_is_required")
: null,
decoration: InputDecoration(
enabledBorder:
UnderlineInputBorder(
borderSide: BorderSide(
style: BorderStyle
.none)),
border: UnderlineInputBorder(
borderSide: BorderSide(
style:
BorderStyle.none)),
disabledBorder:
UnderlineInputBorder(
borderSide: BorderSide(
style: BorderStyle
.none)),
errorBorder:
UnderlineInputBorder(
borderSide: BorderSide(
style: BorderStyle
.none)),
focusedBorder:
UnderlineInputBorder(
borderSide: BorderSide(
style: BorderStyle
.none)),
focusedErrorBorder:
UnderlineInputBorder(
borderSide: BorderSide(
style: BorderStyle
.none)),
),
inputFormatters: [
new FilteringTextInputFormatter
.deny(
new RegExp(
'[\.|\,|\-|\ ]'),
),
],
),
),
),
],
),
),
),
Container(
margin: EdgeInsets.symmetric(vertical: 25.0),
child: ButtonTheme(
minWidth: MediaQuery.of(context).size.width,
child: RaisedButton(
elevation: 0.0,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.all(
Radius.circular(5.0),
),
),
padding:
EdgeInsets.symmetric(vertical: 10.0),
color: Theme.of(context).primaryColor,
onPressed: () {
if (!isLoading) {
setState(() {
isLoading = true;
});
_sendVerificationCode();
}
},
child: !isLoading
? Text(
getTranslated(context, "next"),
style: TextStyle(
color: Colors.white,
fontSize: 18.0,
),
)
: SpinKitThreeBounce(
color: Colors.white,
size: 15.0,
),
),
),
),
],
),
),
),
),
],
),
],
),
),
),
],
),
);
}
_sendVerificationCode() async {
try {
var code = phoneCode;
//TODO: remember to remove hardcoded 250 phone code
var tel = _phoneTextEditController.text;
if (code != null && tel != null && tel != "") {
var _tel = "$code${int.parse(tel)}";
var rsp = await studentVerifyNumber(_tel);
// check if request was accepted by server!
if (rsp['status'] == 200) {
// flip next btn loading state
setState(() {
isLoading = false;
});
widget.prefs.setString("logged_number", _tel);
      return Navigator.pushReplacement(
        context,
        MaterialPageRoute(
          builder: (context) =>
              CodeVerification(phoneNumber: _tel, prefs: widget.prefs),
        ),
      );
    } else {
      // flip next btn loading state
      setState(() {
        isLoading = false;
      });
      if (kDebugMode)
        print('error happened here is the srv rsp -> ${rsp.toString()}');

      if (rsp['status'] == 403 && rsp['message'] != null) {
        _scaffoldKey.currentState.showSnackBar(
          new SnackBar(
            backgroundColor: Colors.redAccent.shade200,
            duration: Duration(seconds: 3),
            content:
                Text(getTranslated(context, "not_allowed_to_use_shuri")),
          ),
        );
      } else {
        _scaffoldKey.currentState.showSnackBar(
          new SnackBar(
            backgroundColor: Colors.redAccent.shade200,
            duration: Duration(seconds: 3),
            content:
                Text(getTranslated(context, "oops_something_happened")),
          ),
        );
      }
    }
    // retry if failed!
  } else {
    _scaffoldKey.currentState.showSnackBar(
      new SnackBar(
        backgroundColor: Colors.redAccent.shade200,
        duration: Duration(seconds: 3),
        content: Text(
          getTranslated(context, "please_provide_phone_code_and_num"),
        ),
      ),
    );
    setState(() {
      isLoading = false;
    });
  }
} catch (e) {
  _scaffoldKey.currentState.showSnackBar(
    new SnackBar(
      backgroundColor: Colors.redAccent.shade200,
      duration: Duration(seconds: 3),
      content: Text(e.toString()),
    ),
  );
}

}
@override
void dispose() {
_phoneTextEditController.dispose();
super.dispose();
}
}`
Please I've been stuck on this for 2 months now, Any help from you would be appreciated.

I'm facing this issue where on Android my keyboard doesn't show up from times to time, mostly when the app goes into background and comes back. also when route changes let's say from home to this sign up route.
Please I've been stuck on this for 2 months now, Any help from you would be appreciated.

Creating the form key outside the build function is enough for the most cases, but in some cases the only solution is to create the form key outside the form widget and pass to it. Everytime the widget state is changed, the form key is recreated and this the keyboard goes crazy. So create the form key in the parent widget and then pass it as a parameter to the widget where the form is. This will solve the issue.

I'm facing this issue where on Android my keyboard doesn't show up from times to time, mostly when the app goes into background and comes back. also when route changes let's say from home to this sign up route.
  static final GlobalKey<FormState> _formState = new GlobalKey<FormState>();
  GlobalKey<ScaffoldState> _scaffoldKey = new GlobalKey<ScaffoldState>();
  TextEditingController _phoneTextEditController = new TextEditingController();
  String phoneCode = "250";
  bool isLoading = false;

  @override
  void initState() {
    super.initState();
  }

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      resizeToAvoidBottomInset: true,
      key: _scaffoldKey,
      backgroundColor: Colors.white,
      appBar: AppBar(
        actions: [ChangeLanguage()],
        automaticallyImplyLeading: false,
      ),
      body: Column(
        crossAxisAlignment: CrossAxisAlignment.center,
        mainAxisSize: MainAxisSize.max,
        children: [
          Expanded(
            child: SingleChildScrollView(
              child: ListView(
                shrinkWrap: false,
                children: <Widget>[
                  Column(
                    crossAxisAlignment: CrossAxisAlignment.center,
                    children: <Widget>[
                      SizedBox(
                        height: 25.0,
                      ),
                      Container(
                        padding: EdgeInsets.all(10.0),
                        child: Center(
                          child: Image.asset(
                            'assets/on_time.png',
                            width: MediaQuery.of(context).size.width * 0.35,
                          ),
                        ),
                      ),
                      SizedBox(height: 10.0),
                      Container(
                        padding: EdgeInsets.symmetric(horizontal: 35.0),
                        child: Form(
                          key: _formState,
                          child: Center(
                            child: Column(
                              mainAxisAlignment: MainAxisAlignment.start,
                              crossAxisAlignment: CrossAxisAlignment.start,
                              mainAxisSize: MainAxisSize.min,
                              children: <Widget>[
                                Center(
                                  child: Text(
                                      getTranslated(context, "get_started"),
                                      style: GoogleFonts.lato(
                                          textStyle: TextStyle(
                                              fontSize: 16,
                                              fontWeight: FontWeight.bold))),
                                ),
                                Center(
                                  child: Text(
                                      getTranslated(
                                          context, "sign_in_to_continue"),
                                      style: GoogleFonts.lato(
                                        textStyle: TextStyle(
                                          fontWeight: FontWeight.bold,
                                          fontSize: 18.0,
                                          color: Colors.black.withOpacity(0.4),
                                        ),
                                      )),
                                ),
                                Padding(
                                  padding: EdgeInsets.only(
                                    left: 1.0,
                                    right: 1.0,
                                    top: 20.0,
                                  ),
                                  child: Text(
                                    getTranslated(context, "phone_number"),
                                    textAlign: TextAlign.left,
                                    style:
                                        Theme.of(context).textTheme.bodyText1,
                                  ),
                                ),
                                Card(
                                  elevation: 0.0,
                                  margin: EdgeInsets.only(top: 10.0),
                                  shape: RoundedRectangleBorder(
                                      side: BorderSide(
                                        color: Colors.black.withOpacity(0.15),
                                        width: 1.0,
                                      ),
                                      borderRadius: BorderRadius.all(
                                          Radius.circular(5.0))),
                                  child: Padding(
                                    padding: EdgeInsets.symmetric(
                                        horizontal: 10.0, vertical: 0.0),
                                    child: Row(
                                      mainAxisSize: MainAxisSize.max,
                                      children: [
                                        CountryCodePicker(
                                          onChanged: print,
                                          initialSelection: 'RW',
                                          // optional. Shows only country name and flag
                                          showFlagDialog: true,
                                          // optional. Shows only country name and flag when popup is closed.
                                          showOnlyCountryWhenClosed: false,
                                          // optional. aligns the flag and the Text left
                                          alignLeft: false,
                                          textStyle: TextStyle(
                                              fontWeight: FontWeight.bold),
                                        ),
                                        Expanded(
                                          child: Padding(
                                            padding: const EdgeInsets.only(
                                                left: 4.0),
                                            child: TextFormField(
                                              autofocus: true,
                                              controller:
                                                  _phoneTextEditController,
                                              keyboardType:
                                                  TextInputType.number,
                                              style: TextStyle(
                                                  fontWeight: FontWeight.bold),
                                              textInputAction:
                                                  TextInputAction.done,
                                              validator: (v) => v.isEmpty
                                                  ? getTranslated(context,
                                                      "phone_number_is_required")
                                                  : null,
                                              decoration: InputDecoration(
                                                enabledBorder:
                                                    UnderlineInputBorder(
                                                        borderSide: BorderSide(
                                                            style: BorderStyle
                                                                .none)),
                                                border: UnderlineInputBorder(
                                                    borderSide: BorderSide(
                                                        style:
                                                            BorderStyle.none)),
                                                disabledBorder:
                                                    UnderlineInputBorder(
                                                        borderSide: BorderSide(
                                                            style: BorderStyle
                                                                .none)),
                                                errorBorder:
                                                    UnderlineInputBorder(
                                                        borderSide: BorderSide(
                                                            style: BorderStyle
                                                                .none)),
                                                focusedBorder:
                                                    UnderlineInputBorder(
                                                        borderSide: BorderSide(
                                                            style: BorderStyle
                                                                .none)),
                                                focusedErrorBorder:
                                                    UnderlineInputBorder(
                                                        borderSide: BorderSide(
                                                            style: BorderStyle
                                                                .none)),
                                              ),
                                              inputFormatters: [
                                                new FilteringTextInputFormatter
                                                    .deny(
                                                  new RegExp(
                                                      '[\\.|\\,|\\-|\\ ]'),
                                                ),
                                              ],
                                            ),
                                          ),
                                        ),
                                      ],
                                    ),
                                  ),
                                ),
                                Container(
                                  margin: EdgeInsets.symmetric(vertical: 25.0),
                                  child: ButtonTheme(
                                    minWidth: MediaQuery.of(context).size.width,
                                    child: RaisedButton(
                                      elevation: 0.0,
                                      shape: RoundedRectangleBorder(
                                        borderRadius: BorderRadius.all(
                                          Radius.circular(5.0),
                                        ),
                                      ),
                                      padding:
                                          EdgeInsets.symmetric(vertical: 10.0),
                                      color: Theme.of(context).primaryColor,
                                      onPressed: () {
                                        if (!isLoading) {
                                          setState(() {
                                            isLoading = true;
                                          });
                                          _sendVerificationCode();
                                        }
                                      },
                                      child: !isLoading
                                          ? Text(
                                              getTranslated(context, "next"),
                                              style: TextStyle(
                                                color: Colors.white,
                                                fontSize: 18.0,
                                              ),
                                            )
                                          : SpinKitThreeBounce(
                                              color: Colors.white,
                                              size: 15.0,
                                            ),
                                    ),
                                  ),
                                ),
                              ],
                            ),
                          ),
                        ),
                      ),
                    ],
                  ),
                ],
              ),
            ),
          ),
        ],
      ),
    );
  }

  _sendVerificationCode() async {
    try {
      var code = phoneCode;
      //TODO: remember to remove hardcoded 250 phone code
      var tel = _phoneTextEditController.text;
      if (code != null && tel != null && tel != "") {
        var _tel = "$code${int.parse(tel)}";
        var rsp = await studentVerifyNumber(_tel);
        // check if request was accepted by server!
        if (rsp['status'] == 200) {
          // flip next btn loading state
          setState(() {
            isLoading = false;
          });
          widget.prefs.setString("logged_number", _tel);

          return Navigator.pushReplacement(
            context,
            MaterialPageRoute(
              builder: (context) =>
                  CodeVerification(phoneNumber: _tel, prefs: widget.prefs),
            ),
          );
        } else {
          // flip next btn loading state
          setState(() {
            isLoading = false;
          });
          if (kDebugMode)
            print('error happened here is the srv rsp -> ${rsp.toString()}');

          if (rsp['status'] == 403 && rsp['message'] != null) {
            _scaffoldKey.currentState.showSnackBar(
              new SnackBar(
                backgroundColor: Colors.redAccent.shade200,
                duration: Duration(seconds: 3),
                content:
                    Text(getTranslated(context, "not_allowed_to_use_shuri")),
              ),
            );
          } else {
            _scaffoldKey.currentState.showSnackBar(
              new SnackBar(
                backgroundColor: Colors.redAccent.shade200,
                duration: Duration(seconds: 3),
                content:
                    Text(getTranslated(context, "oops_something_happened")),
              ),
            );
          }
        }
        // retry if failed!
      } else {
        _scaffoldKey.currentState.showSnackBar(
          new SnackBar(
            backgroundColor: Colors.redAccent.shade200,
            duration: Duration(seconds: 3),
            content: Text(
              getTranslated(context, "please_provide_phone_code_and_num"),
            ),
          ),
        );
        setState(() {
          isLoading = false;
        });
      }
    } catch (e) {
      _scaffoldKey.currentState.showSnackBar(
        new SnackBar(
          backgroundColor: Colors.redAccent.shade200,
          duration: Duration(seconds: 3),
          content: Text(e.toString()),
        ),
      );
    }
  }

  @override
  void dispose() {
    _phoneTextEditController.dispose();
    super.dispose();
  }
}```

Please I've been stuck on this for 2 months now, Any help from you would be appreciated.

I think I figured out what's was wrong, android:showWhenLocked="true" android:turnScreenOn="true" removing both these line in androidManifest.xml on activity segment Fixed it for me. Now I can move on, :). Thanks @pulstar , your solution didn't work for me but I appreciate the effort.

I'm also facing the same issue .when tapping on textfield keyboard opens and closes instantly.But in my case nothing works .probably because it's not the key that's causing the issue.I'm using a ListView builder to show some comments and when there is only comment or no comment keyboard works fine. I recently changed structure of ListView item .initially we were fetching data related to each comment (username etc) from backend now we keep it in a list directly with comment and just display with the comment without anymore fetching.Earlier we were not experiencing this issue ,now suddenly it happens.
So far i've tried making globalkeys static ,static final for forms but still no luck.
static final GlobalKey<FormState> formKey = new GlobalKey<FormState>();
 static final Key k1 = new GlobalKey();
 @override
 void initState() {

ListView.builder(
                      reverse: true,
                      controller: scrollController,
                      physics: BouncingScrollPhysics(),
                      itemCount: widget.comments.length,
                      itemBuilder: (BuildContext context, int index) {

                        var snap = widget.comments[index];

                        return commentContainer(
                            text: snap['text'],
                            uid: snap['uid'],
                            colour1: snap['color1'],
                            colour2: snap['color2'],
                            nickname: snap['nickname'],
                            imageUrl: snap['imageUrl']);}

earlier we this was commentContainer and we only had 2 arguments in commentContainer text and uid
return FutureBuilder(
    future: FirebaseFirestore.instance.collection('users').doc(uid).get(),
    builder: (context, AsyncSnapshot<DocumentSnapshot> snap) {

and then using snap for colors etc.
It worked perfectly then

I was having the same problem, after changing every GlobalKey to static final it worked flawlessly.
Notice, if you have multiple FocusNode() they have to be static final too.

Thank you for this. I was trying to figure this one out forever. I had set resizeToAvoidBottomInset: false to get rid of RenderFlex errors but the only thing that kept the keyboard from disappearing was setting adding the 'static final' to the GlobalKey

I've been battling with this problem for the last few days and finally solved it this morning. Like others in this thread, it was only happening when using MediaQuery.of. However, I didn't want to not use MediaQuery.of because it's useful for creating layouts relative the the screen size. I also really didn't like the idea of using static because it limits you to only one instance of the widget type where you use it.
What I found out is that using MediaQuery.of causes a widget to become dependent on MediaQueryData such that when MediaQueryData changes, the widget build method will be called again. This is a problem because if you created a focus node in a widget within that build method, that focus node will be re-created. What happens is that a user taps the textfield and it gains focus, MediaQueryData changes which in turn causes the build method to be called again and the textfield then looses focus, which then causes the keyboard to retract.
The solution in my case was to put the TextFields' FocusNodes outside of the build method as final instance fields. This guarantees that they will survive the build method being called and therefore preserves their focus.


(Colored) transparency

Hello,
Not sure this is the best place to ask, if there is a better place, please let me know.
Is there a document describing how a renderer should generate weights for
a) transparent objects (i.e. does the weight include the transparency of the object) - my guess is "yes", but I'd like to confirm;
b) objects behind other transparent objects (i.e. should the weight take into account any attenuation by transparent objects in front of the selected one) - my guess is "yes", but I'd like to confirm;
c)  if the answer to b) is "yes", how is colored transparency handled?
Best regards,
Vlado

Hi Vlado! I think this is a perfectly good place to discuss this. Another option would be the Cryptomatte Committee e-mail list, though that's not being used very much.

Is there a document describing how a renderer should generate weights

The specification in this repo is really only about how the EXR file is encoded and less what the renderer does, but our poster does describe what happens in the renderer (though the specification is newer and supersedes it).

a) transparent objects (i.e. does the weight include the transparency of the object) - my guess is "yes", but I'd like to confirm;

That is correct. Once encoded, transparency is treated as just another case of multiple IDs in a pixel, so the weight does have to include the transparency. This has to happen in the renderer because once encoded, we don't store any information about how there came to be multiple IDs in a pixel.

b) objects behind other transparent objects (i.e. should the weight take into account any attenuation by transparent objects in front of the selected one) - my guess is "yes", but I'd like to confirm;

Also correct. In our implementation we iterate through the depth samples for a camera sample front to back in the filter, attenuating the available opacity as we go.

c) if the answer to b) is "yes", how is colored transparency handled?

We just use an average of the three channels. If we did something else we'd still just be encoding a monochrome matte anyway, so I don't have a better idea. If there's something better to do here, we're definitely interested.

Perfect, then I'm done in that regard :) I have one more question about naming conventions for objects, but I will post another issue.
Best regards,
Vlado

Glad to hear it!


[SP-4930] Backport of PDI-17585 - Variable Replacement Is Not Working…

… in Connection Pool Configuration (8.2 Suite)
@bantonio82 @pentaho-lmartins

Build Completed
:fire: This pull request has some issues. It would be preferable to fix them in order for it to be just perfect. See below for more details. Some links are also available below for further assistance in addressing those issues.
Build Commands
mvn -B -f 'pom.xml' -pl 'dbdialog,core' -P '!assemblies' -Dsurefire.runOrder=alphabetical -Daudit -amd clean install

Cleanup Commands
mvn -B -f 'pom.xml' -pl 'dbdialog,core' -P '!assemblies' -amd build-helper:remove-project-artifact

Changed files
  core/src/main/java/org/pentaho/di/core/database/BaseDatabaseMeta.java
  core/src/main/java/org/pentaho/di/core/database/DatabaseInterface.java
  core/src/main/java/org/pentaho/di/core/database/DatabaseMeta.java
  core/src/test/java/org/pentaho/di/core/database/ConnectionPoolUtilTest.java
  dbdialog/src/main/java/org/pentaho/ui/database/event/DataHandler.java

Unit Test Coverage
These statistics help you identify how your changes have affected the coverage of the following files. If a file is not in this list, then its coverage was not affected by your changes. To get some help interpreting these metrics, please refer to Jacoco's documentation.

:warning: Coverage Changes (click to expand)
org.pentaho.di.core.database.BaseDatabaseMeta

Complexity Change: -1.1% :small_red_triangle_down:
Instruction Change: -0.9% :small_red_triangle_down:
Line Change: -1% :small_red_triangle_down:
Method Change: -2.1% :small_red_triangle_down:

org.pentaho.di.job.entries.sql.JobEntrySQL

Instruction Change: -3.4% :small_red_triangle_down:
Line Change: -3.8% :small_red_triangle_down:

org.pentaho.di.trans.steps.singlethreader.SingleThreaderMeta

Instruction Change: -0.1% :small_red_triangle_down:

org.pentaho.di.trans.steps.sortedmerge.SortedMergeMeta

Instruction Change: -0.2% :small_red_triangle_down:

org.pentaho.di.trans.steps.textfileinput.TextFileInputMeta

Branch Change: -0.5% :small_red_triangle_down:

org.pentaho.di.trans.steps.salesforceinsert.SalesforceInsertMeta

Instruction Change: -0.1% :small_red_triangle_down:

org.pentaho.di.trans.steps.salesforceupsert.SalesforceUpsertMeta

Instruction Change: -0.1% :small_red_triangle_down:


Fabrication integration

Purpose of this pull request:
Add Fabrication gem support for FactoryProf #22
What changes did you make? (overview):

extracted FactoryGirl patching method to separate class, alongside with newly created Fabrication patch;

unified FactoryProf#track method so it does not rely on arguments passed from FactoryGirl;

changed integration specs so they mimick factories created both by FactoryGirl and Fabrication;

changed FactoryProf's unit specs and refactored similar expectations logic;

added Fabrication fixtures;

Is there anything you'd like reviewers to focus on?
I assumed that one app may have bundled with both FactoryGirl and Fabrication. Respective integration spec reflects this case.
I did not include neither readme updates, nor changelog entries yet. I can get them ready if the reviewers would find this PR worthy to merge.

@palkan Thanks for the review! I updated the PR according to your comments. Also readme and changelog entries added.

Thank you!
I need your full name (in Russian) for CultOfMartians (if you don't mind)

Full name in Russian is Руслан Гафуров

@Shkrt http://cultofmartians.com/tasks/test-prof-fabrication.html
btw, how can I found on Twitter?
Could you please send me your actual email address to<EMAIL_ADDRESS>We plan to send some goodies to the Cult participants)


fix: Fixes Batching with Scene Messages

Fixes #2651
Client must not process any more messages after SceneMessage while it has transport suspended and is loading the scene, so this ensures the scene message is the last one in the batch.
Subsequent messages will go into the next batch and will be processed by client after it unsuspends the transport.

better than the last PR.
still not living it though. too many edge cases.
need some more time to think about batching..

better than the last PR.
a bit of an edge case handling though. there must be an easier way.
need some more time to think about batching..

Since most games have multiple scenes, I don't see how you can call this an edge case.
If you want to overhaul batching over the next months, fine, but in the meantime, batching is broken for everyone with multiple scenes and has to be disabled.  This is a dead simple fix that works and gives you plenty of time for whatever refactor you have in mind.

closed in favor of https://github.com/vis2k/Mirror/pull/2774


arm/gicv3: set routing affinity before enable IRQ

Summary
arm/gicv3: set routing affinity before enable IRQ
In corner case, the pending ISR will be triggered immediately
after enable the IRQ, this PR will setting CPU affinity first
to avoid routing the unexpected IRQ to other CPUs.
Signed-off-by: chao an<EMAIL_ADDRESS>Impact
N/A
Testing
ci-check

Zephyr community:
https://github.com/zephyrproject-rtos/zephyr/pull/77862


Faker::Color.color_name => undefined method

faker (1.6.1)
Faker::Color.rgb_color
=> [81, 191, 238]
Faker::Color.hex_color
=> "#9b35e0"
Faker::Color.color_name
NoMethodError: undefined method color_name' for Faker::Color:Class from /home/chris/.rbenv/versions/2.2.4/lib/ruby/gems/2.2.0/gems/faker-1.6.1/lib/faker.rb:144:in method_missing'

@ChrisCPO
Hi, I think that Faker::Color.color_name is not supported to faker-1.6.1.
Because, this method was added on "8 Dec 2015" by PR below, and faker-1.6.1 was released on "23 Nov 2015".
Maybe, faker-1.6.2 feature?

1.6.1 - November 23, 2015 (220 KB)
1.6.0 - November 23, 2015 (220 KB)

Faker::Color documentation and a color name method by efexen · Pull Request #479 · stympy/faker
faker | RubyGems.org | your community gem host

So, if you use code in master branch, it can be.
irb(main):001:0> require 'faker'
=> true
irb(main):002:0> Faker::Color.color_name
=> "silver"
irb(main):003:0> Faker::Color.color_name
=> "lime"
irb(main):004:0> Faker::Color.color_name
=> "orange"

Thanks :+1:


PanelContainer does not auto-resize to smaller size when inner RichTextLabel text gets shorter

Tested versions
Tested in Godot 4.3.stable (Linux). Also tested in 4.4 Dev 7.
System information
Godot v4.4.dev7 - Manjaro Linux #1 SMP PREEMPT_DYNAMIC Mon, 09 Dec 2024 11:58:37 +0000 on X11 - X11 display driver, Multi-window, 2 monitors - Vulkan (Forward+) - integrated AMD Radeon Graphics (RADV RENOIR) - AMD Ryzen 7 4800H with Radeon Graphics (16 threads)
Issue description
A PanelContainer fits its size to a containting RichTextLabel (Fit Content ON, AutoWrap Smart) but does NOT fit its size once the richtextlabel text gets smaller.
Both the PanelContainer and the RichTextLabel have a custom minimum size set (though behaviour is the same without a custom minimum size).
Looking at the remote view, the RichTextLabel has a ScrollBar child even if "scroll active" is set to false (RichtTextLabel) and the scrollbar takes up the whole height of the PanelContainer (not sure if this is relevant).
https://github.com/user-attachments/assets/f7b87601-2aa4-484d-91a8-0a63af3a92ed
Having something like a VBoxContainer between the PanelContainer and the RichTextLabel will properly resize the VBoxContainer but will still not resize the PanelContainer. (Video Example has the following setup: PanelContainer (Grey) -> VBoxContainer -> MarginContainer -> PanelContainer (Red) -> RichTextLabel). Issue persists even without the MarginContainer...
https://github.com/user-attachments/assets/9ff68c0b-fa0c-4fa6-b355-bbc2432cc50c
I have a proper project with a more complex issue (probably related to this one) where upon instantiating a scene with RichTextLabel has wrong dimensions for the first frame after add_child().
Steps to reproduce
Create a PanelContainer, add child RichTextLabel, set "fit content" to ON.
In-game set RichTextLabel.text to something larger, then set it back to something smaller. The PanelContainer does not resize back.
Minimal reproduction project (MRP)
Not quite MRP (there is some variants on the issue I did to narrow down the issue): PanelContainerResize.zip
Files are now for 4.4 Dev 7 (auto converted)

Changing the outer PanelContainer to be a normal Panel-Node fixes the behaviour.
As of now I am unsure if its still a bug and I just misunderstood how PanelContainer and Panel are supposed to work...


[TACHYON-935] Added the usage of links in the documentation in the tachyon.metrics and tachyon.web packages

https://tachyon.atlassian.net/browse/TACHYON-935

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/Tachyon-Pull-Request-Builder/7164/
Test PASSed.

LGTM. Thanks for the doc improvement.


network: support interface binding on Android

Description: SO_BINDTODEVICE will generally only be useable by an Android app running as root, so the present interface-binding approach on Android is mostly a non-starter. Instead, this change binds the interface indirectly by finding the local IP of the interface and setting that as the source IP of the socket.
To do so, it passes a "synthetic" socket option through to the internal connection API. When applied, instead of setting an actual socket option on the socket, this object sets the source IP property on the connection before bind() is called.
Risk Level: Moderate
Testing: Local & On Device
Signed-off-by: Mike Schore<EMAIL_ADDRESS>

Thanks @snowp!


Using export-as emits __importStar and related helpers when importHelpers: true

TypeScript Version:  Version 3.9.0-dev.20200228

Search Terms:
export as importhelpers
export as importstar
export as helper
Code
export * as _ from 'lodash-es';

compiled with the following configuration:
{
  "compilerOptions": {
    "target": "es2020",
    "module": "commonjs",
    "importHelpers": true,
    "esModuleInterop": true
  }
}

Expected behavior:
The output should be the same as if compiling the equivalent older TS:
import * as _ from 'lodash-es';
export {_}

i.e. the compiled Javascript should be:
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const tslib_1 = require("tslib");
// export * as _ from 'lodash-es';
const _ = tslib_1.__importStar(require("lodash-es"));
exports._ = _;

Actual behavior:
The helper functions are emitted:
"use strict";
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
    if (k2 === undefined) k2 = k;
    Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
}) : (function(o, m, k, k2) {
    if (k2 === undefined) k2 = k;
    o[k2] = m[k];
}));
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
    Object.defineProperty(o, "default", { enumerable: true, value: v });
}) : function(o, v) {
    o["default"] = v;
});
var __importStar = (this && this.__importStar) || function (mod) {
    if (mod && mod.__esModule) return mod;
    var result = {};
    if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
    __setModuleDefault(result, mod);
    return result;
};
Object.defineProperty(exports, "__esModule", { value: true });
exports._ = __importStar(require("lodash-es"));

Playground Link:
The Typescript Playground doesn't support importHelpers, and the analogue noEmitHelpers doesn't cause this behaviour; I don't believe it's possible to reproduce this issue using the Playground.
Related Issues:
The similar issues search pointed me at #21560 and #27415 which also mention import helpers being inlined in different edge cases. Seeing as export-as isn't a dynamic import, and the older issue related to regular imports is closed, this seems to be a different, possibly related issue.

The "__setModuleDefault" helper is causing this error for me:

TypeError: Cannot redefine property: default

I did not encounter this under 3.8.

@lotz same for me with the module cross-fetch
Started with 3.9.2
I fixed it by named importing fetch as it is also named exported not only default exported.

We should be treating export * as ns from ... the same as import * as ns from ... in collectExternalModuleInfo. I should have a fix up shortly.
@lotz: I'm not certain whether your issue is related, and may have been fixed by #38808. Can you verify whether that is the case, and if not, can you provide a specific repro for your case?


updates for CRAN in case sciencebase is down

I got pinged when Sciencebase was offline that the CRAN build was failing.
CRAN tests now pass with internet completely off.

Coverage decreased (-0.2%) to 10.035% when pulling d4c682078f01b4e590b96def920436358a5e1aeb on dblodgett-usgs:master into 5195e3989879a1ef40050c3aa3156106f72e030c on USGS-R:master.


Fix incorrect review comment diffs

Fixes #13683.
The diff snippet that provides context for a code review comment on the pull request timeline page used to be calculated based on the headCommitID. But in 1.13, with PR #13448, this changed to the commitID from the blame for the commented line, which seems to cause these incorrect review comment diff snippets.
This PR reverts back to using the headCommitID for obtaining the diff.

Codecov Report

Merging #14002 (60ce620) into master (b8c58ed) will decrease coverage by 0.13%.
The diff coverage is 33.33%.

@@            Coverage Diff             @@
##           master   #14002      +/-   ##
==========================================
- Coverage   42.23%   42.09%   -0.14%
==========================================
  Files         710      710
  Lines       77261    77262       +1
==========================================
- Hits        32629    32524     -105
- Misses      39266    39382     +116
+ Partials     5366     5356      -10

Impacted Files
Coverage Δ

services/pull/review.go
51.07% <33.33%> (+0.35%)
:arrow_up:

modules/notification/ui/ui.go
84.72% <0.00%> (-11.12%)
:arrow_down:

models/issue_comment.go
43.50% <0.00%> (-9.22%)
:arrow_down:

modules/notification/mail/mail.go
33.33% <0.00%> (-5.75%)
:arrow_down:

modules/git/commit.go
49.67% <0.00%> (-3.95%)
:arrow_down:

modules/notification/base/null.go
74.28% <0.00%> (-2.86%)
:arrow_down:

modules/notification/notification.go
83.92% <0.00%> (-2.68%)
:arrow_down:

modules/process/manager.go
72.50% <0.00%> (-2.50%)
:arrow_down:

services/pull/check.go
49.63% <0.00%> (-2.19%)
:arrow_down:

models/notification.go
66.25% <0.00%> (-0.99%)
:arrow_down:

... and 3 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update b8c58ed...60ce620. Read the comment docs.


Update index.html

@yegor256/z please, pay attention to this pull request

Job #21 is now in scope, role is REV

@ashtonhogan thanks!

Job gh:yegor256/elegantobjects.github.io#21 is not assigned, can't get start time

The job #21 is now out of scope


[Improvement] [UI] improve hhe bar width of the process definition statistics

Brief change log
close #10088
Verify this pull request
Manually verified the change by testing locally.

Codecov Report

Merging #10089 (2d6ec61) into dev (537c206) will decrease coverage by 0.01%.
The diff coverage is 27.27%.

:exclamation: Current head 2d6ec61 differs from pull request most recent head 167943e. Consider uploading reports for the commit 167943e to get more accurate results

@@             Coverage Diff              @@
##                dev   #10089      +/-   ##
============================================
- Coverage     40.87%   40.86%   -0.02%
+ Complexity     4638     4636       -2
============================================
  Files           839      839
  Lines         34015    34022       +7
  Branches       3772     3773       +1
============================================
- Hits          13904    13902       -2
- Misses        18782    18792      +10
+ Partials       1329     1328       -1

Impacted Files
Coverage Δ

...g/apache/dolphinscheduler/dao/entity/Resource.java
45.88% <0.00%> (-1.68%)
:arrow_down:

...er/server/master/runner/WorkflowExecuteThread.java
8.01% <0.00%> (-0.02%)
:arrow_down:

...ver/master/runner/task/ConditionTaskProcessor.java
5.33% <0.00%> (+0.07%)
:arrow_up:

...rg/apache/dolphinscheduler/dao/entity/UdfFunc.java
81.66% <100.00%> (+0.96%)
:arrow_up:

...org/apache/dolphinscheduler/remote/utils/Host.java
37.77% <0.00%> (-2.23%)
:arrow_down:

...dolphinscheduler/remote/future/ResponseFuture.java
81.96% <0.00%> (-1.64%)
:arrow_down:

...e/dolphinscheduler/remote/NettyRemotingClient.java
52.11% <0.00%> (-1.41%)
:arrow_down:

...r/plugin/task/sqoop/parameter/SqoopParameters.java
53.33% <0.00%> (-1.34%)
:arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 537c206...167943e. Read the comment docs.


datecheck function period fix

Fixed period for datecheck function so it is everyday at midnight, rather than every 20 seconds.

@Lu-Devenny can you squash and merge this please?


subsequents Sign In does not add new tokens and return 401

Hi, I'm using this gem in Rails 5.2.2 and the /sign_in method is just working the 1st time, after trying to call it again from postman, the application return this
Started POST "/api/v1/auth/sign_in" for <IP_ADDRESS> at 2018-12-13 16:04:03 -0300
Processing by DeviseTokenAuth::SessionsController#create as */*
  Parameters<EMAIL_ADDRESS>"password"=>"[FILTERED]"}
  User Load (0.5ms)  SELECT  "users".* FROM "users" WHERE (email =<EMAIL_ADDRESS>AND provider='email') ORDER BY "users"."id" ASC LIMIT $1  [["LIMIT", 1]]
  ↳ /home/nnodes/.rvm/gems/ruby-2.4.1/gems/activerecord-5.2.2/lib/active_record/log_subscriber.rb:98
Completed 401 Unauthorized in 230ms (Views: 0.3ms | ActiveRecord: 2.9ms)

Also after /sign_out and try to re-sign_in it gives the same error.
My devise_token_auth.rb file looks like this
DeviseTokenAuth.setup do |config|
  config.change_headers_on_each_request = false
  config.token_lifespan = 4.weeks
  config.enable_standard_devise_support = true
end

The api_controller.rb
class Api::ApiController < ApplicationController
  skip_before_action :verify_authenticity_token
  include DeviseTokenAuth::Concerns::SetUserByToken
  respond_to :json
end

Any idea?
PS. if i go to the Rails console and update the user password, then save it, the sign_in work again, but just like i said, i can only sign in one time.

I'll close this, because the error was in my User model :cry: a validation that rewrites the password and i didn't see it till a coworker noticed after a very large review.
Cheers.


Mouse Scroll

[x] Windows Supported
[x] Mac Supported
[x] Linux Supported

Mouse scroll forward n backward should work on all system as for left and right I've only tested and confirmed to work on Windows.


Workaround aws issue with doubled ending slash

Workaround since the aws SDK doesn't actually recognize this situation as an error, is just confusing

[x] Check that you pass the basic style checks and unit tests by running mvn clean install

Coverage increased (+0.004%) to 70.557% when pulling 616a60375bb4e5166da4201fa16e66fb11eabbf2 on feature/s3_annoying_issue into 11bd09282d2f62f79f8c785229d75f9994f7f88b on develop.

Coverage increased (+0.004%) to 70.557% when pulling 616a60375bb4e5166da4201fa16e66fb11eabbf2 on feature/s3_annoying_issue into 11bd09282d2f62f79f8c785229d75f9994f7f88b on develop.


Windows build instructions

Hi! I'm trying to use this library on Windows, but the build instructions are written for a Linux machine. I can see that the project is supposed to work on Windows, as cmake <repo dir> generates a bunch of Visual Studio projects and a .sln file, but attempting to  build any of those fails (usually because something that doesn't exist on Windows is defined).
Can this project be built on Windows?

I think we need some work to be able to build it under Windows. There was an old version, maybe 1.2 which was windows compatible. Do you have the list of all the errors you are having? This way I could fix it and then we could provide a Windows version. Thanks!

There's a bunch, and I'm not sure how many of them are just a result of some build flags not quite working correctly. I'll try to summarize:

There seems to be an issue with the MINIZ_EXPORT macro used by the miniz headers. Usage of the macro triggers an expected a type specifier error, and the token after it triggers an expected '{' error. This triggers tons of compilation errors in most of the projects.
unistd.h doesn't exist on windows, and it's used in a few places, like snapshot-file.c or utils.c.
Same for dirent.h.
Same for ftw.h.
bsd-snprintf.c reports that function 'int snprintf(char *const ,const size_t,const char *const ,...)' already has a body. I think snprintf one may be part of Microsoft's C runtime, and CMake just doesn't set the #define correctly, so it gets defined again here.


Add coroutine mutex

I assume this waits for a mutex to be available? Can you help me understand what this is doing?

I assume this waits for a mutex to be available? Can you help me understand what this is doing?

thread won't block when wait for this lock.

I assume this waits for a mutex to be available? Can you help me understand what this is doing?

co_await mutex.lock(); If the lock is not acquired, it hangs and does not block the current thread

I'm gonna use it in my code for testing. Hold on.

It works fine. But I don't have large concurrency.
We need a volunteer to check the CAS implementation 🤪

It works fine. But I don't have large concurrency.
We need a volunteer to check the CAS implementation 🤪

Including the tasks queue in EventLoop？

It works fine. But I don't have large concurrency.
We need a volunteer to check the CAS implementation 🤪

So should we merge this PR?


Effect Behavior Demo is not showing the expected shadow

Link to article:
https://docs.microsoft.com/en-us/samples/xamarin/xamarin-forms-samples/behaviors-effectbehavior/
Problem:
The demo application has two issues:

When built and deployed to a physical device (Google Pixel 3XL) running Android 9 the following error is received - “Blocked by Play Protect – This app was built for an older version of Android and doesn’t include the latest privacy protections”.

Manually updating the project to target Android 8 solved this issue.

When running (on the Pixel 3XL) the label does not show a shadow as described in the docs.

I do not have any Apple devices so I can only comment on the Android experience.

@mjfreelancing Please move this issue to https://github.com/xamarin/xamarin-forms-samples/issues


Bring freeform governance proposal in line with other proposals

Task Overview
The data-node expects a particular form for a governance proposal which the freeform goverance protos does not follow. It messes with the graphql <-> bindings if it doesn't.
The ticket changes the freeform proposal proto message to include a "changes" field.

related to: https://github.com/vegaprotocol/data-node/issues/313


Add support for handling multiple arguments

This PR adds support for subscribing to events that pass in multiple arguments. It also fixes handles not being removed on disposal.

@galvesribeiro Any update on this PR? I was going to use this library for a SignalR demo, but I needed support for multiple args as well.

Sorry folks. I'll look at it later today as soon as I have time and will release the package. Sorry about the delay, busy days.


Run outside angular

Please check if the PR fulfills these requirements

[x] The commit message follows our guidelines: https://github.com/HackedByChinese/ng2-idle/blob/master/CONTRIBUTING.md#pr
[x] Tests for the changes have been added (for bug fixes / features)
[ ] Docs have been added / updated (for bug fixes / features)

What kind of change does this PR introduce? (check one with "x")
[x] Bugfix
[ ] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Build related changes
[ ] CI related changes
[ ] Other... Please describe:

What is the current behavior? (You can also link to an open issue here)
Angular spies on every event handler that is attached to the document root element and processes change detection whenever an event is dispatched by the browser. That's pretty bad for performance.
What is the new behavior?
This PR changes InterruptSource to attach event handlers outside the Angular zone so that no change detection is processed for each event.
Does this PR introduce a breaking change? (check one with "x")
[ ] Yes
[x] No

If this PR contains a breaking change, please describe the impact and migration path for existing applications: ...
Other information:

Coverage increased (+0.004%) to 99.358% when pulling c94fc9a93a27a716b3598bcdb4fca7df083bf6ee on StevenLiekens:feature/run-outside-angular into 2e1aaaf5dfa380844a2b5a2aeec47981fd7f9826 on HackedByChinese:master.

I just tested this with mine, and it looks to fix the issue I have in #78 with the (click) event not firing. Very awesome!

Sweet. :)

Thanks!


RFC: termination_by?

By default, when you write a recursive definition and Lean doesn’t recognize it as structurally recursive, it will attempt well-founded recursion and try to guess a termination argument for you, if you don’t specify it using termination_by. Right now it tries each argument; I am working to extend this to guessing arbitrary lexicographic orderings.
This guessing is potentially expensive, because it runs tactics on a variety of goals where it is not needed; an explicit termination_by annotation avoids that. Furthermore, even if it is fast, some users might prefer to be explicit in the termination argument.
To be consistent with existing idioms, I suggest that
termination_by?`

will tell the user which termination relation is used.
Ideally in a way that they can click on and automatically insert.
Community Feedback
(None yet)
Impact
Add :+1: to issues you consider important. If others benefit from the changes in this proposal being added, please ask them to add :+1: to it.

Open question: Can we actually support Try This:-style interaction in core? (I think the widget for that is in std).
If not, can we somehow make it so that with just core, the message is logged but inert, and once std is loaded, it becomes clickable?

There is precedent for this: simp? is actually implemented in core, there is a rudimentary frontend using set_option tactic.simp.trace true which causes simp to act like simp? and produce a fake "try this" output.

What an oddly named option for this task, simp.trace sounds like a detailed debugging output.
Adding such an option to termination_by is clear. What I do not know: How will std be able to extend that behavior? Based on the simp? example, it would have to override the whole zoo of commands that contain a termination_by element, which seems tricky. (NB: termination_by isn’t a command of its own)
Or could core somehow call an initially undefined or trivial “hook” that could be set by std later?

Can we just write
Widget.saveWidgetInfo ``terminationByWidget (.ofRange stxRange) (props := json% { ... })

in Lean, and only define the
@[widget] def terminationByWidget : Widget.UserWidgetDefinition where

in Std? I'm not sure what happens when the widget definition is missing. If it just fails silently that might be fine.

I don’t know much about widgets yet… If that works, that would be great!
I’ll try it at some point and report back.

Closing this issue since PR implementing this feature has already been merged.


Module design clean-up

Tasks:

[x] Properly round corners on imported (copy/pasted) rectangle shapes that were resized and lots their good ratios
[x] Make right and left edges (white and grey) completely symmetrical (too narrow on the right)
[ ] TBD

DONE.


NTR: 'DNA barcode assay' and two variables

protocol term
Yet again a legacy VB term with no definition... https://legacy.vectorbase.org/popbio/REST/cvterm/VBcv:0001025
barcoding can mean at least two things to people

assaying a smallish panel of SNPs by whatever appropriate technology
sequencing a small (~600) defined region of genome (usually mitochondrial, usually in COI gene) amplified by PCR

Here we mean the second meaning.
variables
'barcode target locus' | VBcv:0001016 | no definition in VBcv
'oligonucleotide primer set' | VBcv:0001024 | has a definition! "oligonucleotide primer set used in a PCR reaction, e.g. amplification of a DNA barcode sequence"
Values for these terms in the dry run 2 missed terms sheet
https://docs.google.com/spreadsheets/d/1vlj-4NTpKJNjj-eU-JgJr6d2OHXiGwiK14InUeNmA7c/edit#gid=1723653757
Questions? Sarah, Bob or Sam

For 'barcode assay' does 'taxonomic diversity assessment by targeted gene survey' http://purl.obolibrary.org/obo/OBI_0001960 work for this?

Sounds perfect, thanks!

Great. I updated the popbio-term-usage spreadsheet with this term. Will work on the others.

Some thoughts on the other requested terms:

'barcode target locus' is a role. Could be an evaluant role (http://purl.obolibrary.org/obo/OBI_0000067) that is realized in a 'taxonomic diversity assessment by targeted gene survey'
'oligonucleotide primer set' a processed material (http://purl.obolibrary.org/obo/OBI_0000047) that consists of oligonucleotides (http://purl.obolibrary.org/obo/CHEBI_7754) in which a primer role (http://purl.obolibrary.org/obo/OBI_0000405) inheres.

DIscussed with ontology team and are OK with these definitions.
@bobular do these work for you?

Discussed and agreed OK - will submit to OBI.

Added to obi-edit.owl and made PR https://github.com/obi-ontology/obi/pull/1335

In obi-dev now.

@johnwjudkins Please import this for the next release. Thanks.

Two new terms from  obi-ontology/obi#1335 added to popbio term mapping master sheet


Mypy and tests failures for Google provider 8.4.0rc2

We deployed the Google provider 8.4.0rc2 on our team Astro Cloud deployment. DAGs seem to run fine but we're observing few mypy and tests failures. The failures can be observed in the checks on PR: https://github.com/astronomer/astronomer-providers/pull/701

As soon as  the stable version of new providers is released will fix this mypy and unit test