title: Django template | safe filter behaving differently on different environments
body: <p>In the template I have <code>&lt;div&gt;{{ my_var | safe }}&lt;/div&gt;</code>,
  where <code>my_var</code> is being set as <code>my_var = format_html(&quot;&lt;p&gt;my variable&lt;/p&gt;&quot;)</code> and rendered using <code>render_to_string</code> function.</p>
  <p>In the production environment, the result is produced as <code>&amp;lt;p&amp;gt;my variable&amp;lt;/p&amp;gt;</code>. It works correctly in the local environment.</p>
  <p>I understand <code>format_html</code> produces safe string which shouldn't be escaped by the template, even providing <code>| safe</code> filter isn't solving the issue. The baffling thing is it behaves correctly on staging/local env but not on prod</p>