title: flutter build error: Execution failed for task ':firebase_core:compileDebugJavaWithJavac'
body: <p>I am using flutter version 2.2.2 and the latest android studio for the moment.
  I have a Flutter project that worked fine few months ago, but now - after upgrading flutter and dart - it does not run.</p>
  <p>I tried downgrading flutter and dart, but kept getting the same error when running:</p>
  <pre><code>FAILURE: Build failed with an exception.
  
  * What went wrong:
  Execution failed for task ':firebase_core:compileDebugJavaWithJavac'.
  &gt; java.time.DateTimeException: Invalid value for MonthOfYear (valid values 1 - 12): 0
  
  * Try:
  Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
  
  * Get more help at https://help.gradle.org
  
  BUILD FAILED in 18s
  Exception: Gradle task assembleDebug failed with exit code 1
  </code></pre>
  <p>I have this pubspec.yaml dependencies:</p>
  <pre><code>environment:
    sdk: &quot;&gt;=2.7.0 &lt;3.0.0&quot;
  
  dependencies:
    flutter:
      sdk: flutter
    http: ^0.12.2
    email_validator: '^1.0.5'
    path_provider: ^1.6.18
    social_share: ^2.0.5
    firebase_admob: ^0.10.2
  </code></pre>
  <p>I tried changing <code>firebase_admob</code> to <code>google_mobile_ads</code> but that did not solve the problem either.</p>
  <p>I am already using AndroidX.</p>
  <p>Can any body see a problem? Does anybody have a possible solution?
  Thanks!</p>