<blockquote>
<p>I'm certainly more convinced than ever by this that the <code>strong_migrations</code> advice to handle removing columns via two commits where you first deploy something to ignore them and then deploy a migration to remove them (which still needs to be marked as unsafe by the way!) is just crazy.</p>
</blockquote>
<p>OK, we're getting off topic slightly here, but it's not crazy. If you want to drop a column, you need to first ensure that no running copy of the codebase expects that column to be there. Since each copy reads the database when it boots, and caches the table structure in memory, and makes it part of every copy of that model that it handles, that causes a situation with a few options:</p>
<ul>
<li>Drop the column. Get lots of errors in production from the instances that are still trying to use that column. Restart all running app instances as quickly as possible.</li>
<li>Stop all running app instances. Drop the column. Restart all instances and live with the downtime that just happened.</li>
<li>Configure the models to ignore the column. Restart the instances with that code. Drop the column at your leisure.</li>
</ul>
<p>That's why strong_migrations suggests the third option.</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/openstreetmap/openstreetmap-website/pull/2320?email_source=notifications&email_token=AAK2OLJNUXQJS2IHTTUAF6TP73Z4HA5CNFSM4IEO2V72YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD2DZOOY#issuecomment-512202555">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AAK2OLK3F7OOEFPJC4EE75TP73Z4HANCNFSM4IEO2V7Q">mute the thread</a>.<img src="https://github.com/notifications/beacon/AAK2OLI6U4B3UP73UERJ25TP73Z4HA5CNFSM4IEO2V72YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD2DZOOY.gif" height="1" width="1" alt="" /></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/openstreetmap/openstreetmap-website/pull/2320?email_source=notifications\u0026email_token=AAK2OLJNUXQJS2IHTTUAF6TP73Z4HA5CNFSM4IEO2V72YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD2DZOOY#issuecomment-512202555",
"url": "https://github.com/openstreetmap/openstreetmap-website/pull/2320?email_source=notifications\u0026email_token=AAK2OLJNUXQJS2IHTTUAF6TP73Z4HA5CNFSM4IEO2V72YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD2DZOOY#issuecomment-512202555",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>