This website contains age-restricted materials including nudity and explicit depictions of sexual activity.
By entering, you affirm that you are at least 18 years of age or the age of majority in the jurisdiction you are accessing the website from and you consent to viewing sexually explicit content.
I feel like a lot of the complication of this story was from using rails to try and develop the implementation of adding a primary key to the database.
Initially testing via SQL would’ve quickly blown through the
null
anddefault
requirements, after which it’s just translating into whatever ORM you are using, testing and deploying.I know a lot of ORMs make it super easy to quicky add a migration in a language you already know well. But primary keys are pretty core to tables, and probably something assumed to be set up when first creating the table (ie rails did auto-magick with the new
id
column).