title: Cannot convert from Spanish date string to LocalDate in Java
body: <p>Hello I'm here for a DateTimeFormatter problem with the Locale formatter language, let me introduce you:</p>
  <ul>
  <li>I'm reading a CSV file with this String Format: &quot;dd-MMM-yyyy&quot; &lt;--&gt; &quot;28-dic-2017&quot;</li>
  <li>Then I have to parse each string from a list to LocalDate to handle each with timeAPI methods.</li>
  <li>Notice that I have my months in spanish abrev. that's the mess!!</li>
  <li>When Executed it returns:</li>
  </ul>
  <p>Observed error with stack trace:</p>
  <pre><code>Exception in thread &quot;main&quot; java.time.format.DateTimeParseException: Text '28-dic-2017' could not be parsed at index 3
      at java.base/java.time.format.DateTimeFormatter.parseResolved0(DateTimeFormatter.java:2051)
      at java.base/java.time.format.DateTimeFormatter.parse(DateTimeFormatter.java:1953)
      at java.base/java.time.LocalDate.parse(LocalDate.java:429)
      at com.examen.Presentation.Principal.parseDate(Principal.java:28)
      at com.examen.Presentation.Principal.main(Principal.java:19)
  </code></pre>
  <p>Minimal, reproducible code example:</p>
  <pre><code>public static LocalDate parseDate(String fecha) {
  
      Locale loc = new Locale(&quot;es&quot;, &quot;ES&quot;);
      DateTimeFormatter formatter = DateTimeFormatter.ofPattern(&quot;dd-MMM-yyyy&quot;, loc);
      LocalDate date = LocalDate.parse(fecha, formatter);
  
      return date;
  }
  </code></pre>
  <p>I've got the same error trying different things and methods from locale and DateTimeFormatter don't even know what i was doing, but I think that this should work OBVIOUSLY NOT.</p>