title: datetime-local time format does not conform to the required format
body: <p>I hope this question is not a duplicate - I was at least not able to fix the issue by looking at other similar Q&amp;As.</p>
  <p>I'm making a web application using Django 2.2, Postgresql 9.5 and Django template language with bootstrap for front end.</p>
  <p>In settings.py I have the following time settings:</p>
  <pre><code>TIME_ZONE = 'UTC'
  
  USE_I18N = True
  
  USE_L10N = True
  
  USE_TZ = True
  </code></pre>
  <p>In some of my forms I have datetime-local fields:</p>
  <pre><code>date = forms.CharField(required=False, widget=forms.DateTimeInput(
          attrs={
              'type':'datetime-local',
              'class':'form-control',
          }
      ))
  </code></pre>
  <p>In my Django template I render the date field as shown below:</p>
  <pre><code>&lt;input type=&quot;datetime-local&quot; id=&quot;id_date&quot; class=&quot;form-control&quot; value=&quot;{{ basic_form.date.value|date:&quot;c&quot;}}&quot;&gt;
  </code></pre>
  <p>I'm getting the following error when loading a page with date field having a date value retrieved from database. And I'm not able to display the date in the form date field:</p>
  <blockquote>
  <p>The specified value &quot;2020-10-28T09:28:00+00:00&quot; does not conform to the required format.  The format is &quot;yyyy-MM-ddThh:mm&quot; followed by optional &quot;:ss&quot; or &quot;:ss.SSS&quot;.</p>
  </blockquote>
  <p>I have also tried to 'render' the date field in the template directly from the form variable received by views.py:</p>
  <pre><code>{{ basic_form.date }}
  </code></pre>
  <p>...and then I get a same warning, however the date value does not contain the T 'separator':</p>
  <blockquote>
  <p>The specified value &quot;2020-10-28 09:28:00+00:00&quot; does not conform to the required format.  The format is &quot;yyyy-MM-ddThh:mm&quot; followed by optional &quot;:ss&quot; or &quot;:ss.SSS&quot;.</p>
  </blockquote>
  <p>Not sure how to interpret this warning message as to me it seems like the date is on the correct format.</p>
  <p>On the server side I get a Runtime warning:</p>
  <blockquote>
  <p>RuntimeWarning: DateTimeField Recipe.date received a naive datetime (2020-10-28 09:28:00) while time zone support is active.</p>
  </blockquote>
  <p>Does anyone know how to get the date displayed in the date field and the date value further utilized in the application by javascript? Any help is much appreciated. Thanks!</p>