Regardless of date format used (Symfony 3.3.14), the error in title appears on submitting a form with the following field definition:
use Symfony\Component\Form\Extension\Core\Type\DateType;
...
$builder
->add('sales', DateType::class, [
'widget' => 'single_text',
'html5' => false,
'attr' => ['class' => 'js-datepicker'],
'format' => 'mm-dd-yyyy',
])
and with the associated javascript
$('.js-datepicker').datepicker({
format: 'mm-dd-yyyy'
});
as called in the template with
{{ form_row(form.sales) }}
...
{% block javascripts %}
{{ parent() }}
<script src="/js/bootstrap-datepicker.js"></script>
<script src="/js/tickets.js"></script>
{% endblock javascripts %}
DOH!
The entity definition that included the sales field some how got
public function setSales(Sales $sales)
{
$this->sales = $sales;
return $this;
}
when it should have been
public function setSales($sales)
{
$this->sales = $sales;
return $this;
}