title: How to correctly parse to LocalDate from String in Java?
body: <p>I faced a strange issue. I can't parse String value to LocalDate. The problem is that in runtime I paused at breakpoint and execute parsing in evaluate expression tool and it works. But then I continue application and I get an exception with next clause: </p>
  
  <blockquote>
    <p>Caused by: java.time.format.DateTimeParseException: Text '-218906870-0-9088-15635' could not be parsed at index 11
        at java.time.format.DateTimeFormatter.parseResolved0(DateTimeFormatter.java:1949)
        at java.time.format.DateTimeFormatter.parse(DateTimeFormatter.java:1851)
        at java.time.LocalDate.parse(LocalDate.java:400)
        at com.library.controller.CrudController.returnBook(CrudController.java:96)
        ... 55 more</p>
  </blockquote>
  
  <p>My code is here</p>
  
  <pre><code>LocalDate date = returnDatePicker.getValue();
      Journal item = (Journal) tableView.getSelectionModel().getSelectedItem();
      if(date != null &amp;&amp; item != null) {
          LocalDate itemDate = LocalDate.parse(item.getStartDate().toString());
          if (date.isAfter(itemDate)) {
              journalDao.saveOrUpdate(item.withReturnDate(date));
              returnPanel.setDisable(true);
              fillJournal();
          }
      }
  </code></pre>
  
  <p>Date in String value looks like "2017-12-30".
  A few screenshots:
  <a href="https://i.stack.imgur.com/YMfwh.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/YMfwh.png" alt="When I evaluate expression I get correct result"></a></p>
  
  <p>How is it even possible? It works in evaluate, and doesn't in runtime.
  I would really appreciate if you give me a few hints.</p>