title: I can't solve 'Could not build the application for the simulator. '
body: <p>Yesterday, I created a flutter project named sample1.
  and I worked fine.
  but when I tried to open the file today and try to run it, I got an error.</p>
  <p>the log says</p>
  <pre><code>Running &quot;flutter pub get&quot; in sample1...                            603ms
  Launching lib/main.dart on iPhone 8 in debug mode...
  Running pod install...                                           1,313ms
  Running Xcode build...                                                  
  Xcode build done.                                           11.8s
  Failed to build iOS app
  Error output from Xcode build:
  ↳
      ** BUILD FAILED **
  
  
  Xcode's output:
  ↳
  
      Command PhaseScriptExecution failed with a nonzero exit code
      note: Using new build system
      note: Building targets in parallel
      note: Planning build
      note: Analyzing workspace
      note: Constructing build description
      note: Build preparation complete
      warning: Capabilities for Signing &amp; Capabilities may not function correctly because its entitlements use a placeholder team ID. To resolve
      this, select a development team in the Runner editor. (in target 'Runner' from project 'Runner')
  
  Could not build the application for the simulator.
  Error launching application on iPhone 8.
  </code></pre>
  <p>I think I have tried everything written here, except the ones like</p>
  <pre><code>pub upgrade
  pub run
  </code></pre>
  <p>because it says</p>
  <pre><code>zsh: command not found: pub
  </code></pre>
  <p><a href="https://stackoverflow.com/questions/59921997/could-not-build-the-application-for-the-simulator-error-launching-application-o">Could not build the application for the simulator. Error launching application on iPhone 11 Pro Max</a></p>
  <p>The android version is working fine.
  Please kindly help me.
  Thank you</p>
  <p>EDIT**
  I just created a new project and it seemed to be working fine but I am afraid it won't work next time I open it.</p>