0

Hello I hope you are well. I have a problem when compiling my Flutter application for the Windows platform. Indeed when I launch my Flutter application by pressing the "Run" button of VScode (or of any IDE compatible with Flutter) I have this error below:

C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Microsoft\VC\v160\Microsoft.CppCommon.targets(234,5): error MSB6006: Arrêt de "cmd.exe" avec le code 1. [C:\Users\Acer Aspire\VSCodeProjects\atlas_workspace\build\windows\flutter\flutter_assemble.vcxproj]
Exception: Build process failed.

But strangely by using the Powershell terminal, by being at the root of my project, by executing the command flutter run -d Windows the application compiles and launches without problem.

Can you tell me what the problem is? And how to solve it? Thanks

My version of Windows : windows 10 version 20H2 ( operating system verion 19042.884)

The output of the flutter doctor command:

Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable, 2.0.3, on Microsoft Windows [version 10.0.19042.844], locale fr-FR)
[√] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
[√] Chrome - develop for the web
[√] Visual Studio - develop for Windows (Visual Studio Community 2019 16.7.6)
[√] Android Studio (version 4.1.0)
[√] IntelliJ IDEA Community Edition (version 2020.2)
[√] VS Code (version 1.52.1)
[√] Connected device (3 available)

• No issues found!

The output of the flutter --version command:

Flutter 2.0.3 • channel stable • https://github.com/flutter/flutter.git
Framework • revision 4d7946a68d (2 weeks ago) • 2021-03-18 17:24:33 -0700
Engine • revision 3459eb2436
Tools • Dart 2.12.2

P.S: I have Visual Studio 2019 and C++ tools installed on my OS

4
  • 1
    Please provide complete error! Commented Apr 3, 2021 at 8:09
  • The error you show is just the final line stating that cmd.exe returned 1 and not zero as exxpected for successful builds. That error message isn't useful for any diagnosis, since it's the same for any failed build. You should provide the error messages, which are listed before that line. Commented Apr 3, 2021 at 8:22
  • That's all the console shows me @pritamparab Commented Apr 3, 2021 at 8:37
  • @Delucis What are you actually typing in? There should be some verbose mode, bor a separate error log in case. As mentioned, that specific console output is completely useless. Commented Apr 3, 2021 at 8:42

3 Answers 3

1

This seems to be a known bug, it's because you have spaces in your user name Acer Aspire :

https://github.com/flutter/flutter/issues/73644

https://github.com/flutter/flutter/issues/75611

Sign up to request clarification or add additional context in comments.

2 Comments

I checked the solutions proposed in the links you sent me. That said, the solution is that I can rename my folder ?
And why when i run flutter run -d windows directly in the terminal it works ?
1

Resolved!I had to change my user name so that it could not contain any space and the problem is solved

so C:\Users\Acer Aspire\VSCodeProjects\atlas_workspace\ is now C:\Users\AcerAspire\VSCodeProjects\atlas_workspace\

Comments

0

in my case,

  1. flutter clean 2) flutter pub get
    run in commmand panel. it solved my problem

1 Comment

Your answer could be improved with additional supporting information. Please edit to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers in the help center.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.