You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When running flutter packages pub run build_runner watch to generate model classes and keep the generated code up to date with the change I make. I can't build or install or hot reload the project I'm working on.
When I pressed the run button in intellij to compile and install the app I get the following error:
Waiting for another flutter command to release the startup lock...
When I kill the build_runner process it starts compiling and installing the project.
If I start the build_runner watch when the project is already running on a device or simulator/emulator
I get the follow error when I make a change to the code:
Initializing hot reload...
Your application could not be compiled, because its dependencies could not be established.
The following Dart file:
/Users/user/projects/project/lib/value_models/models.dart
...refers, in an import, to the following library:
/Users/user/projects/project/lib/value_models/models.g.dart
Unfortunately, that library does not appear to exist on your file system.
Is there a way to start a separate process for the code generation so we can keep compiling and running our apps during development?
changed the title [-]running build_runner watch locks execution of flutter builds and hot reload[/-][+]"packages pub" doesn't release flutter lock[/+]on May 30, 2018
This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.
Activity
maksimr commentedon Feb 28, 2018
@aegis123 I have faced this problem too.
As a workaround, you could set
FLUTTER_ROOTand then you can useflutter runandpub run build_runner watch(without flutter prefix) simultaneouslyHixie commentedon May 30, 2018
We need to release the lock before running pub.
[-]running build_runner watch locks execution of flutter builds and hot reload[/-][+]"packages pub" doesn't release flutter lock[/+]Hixie commentedon Aug 21, 2018
@lfkdsk fixed this! Thanks!
github-actions commentedon Aug 15, 2021
This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of
flutter doctor -vand a minimal reproduction of the issue.