Update error - django.db.migrations

Hi, I just recently updated our on-prem Sentry instance.

Here’s what I did so far:

sudo su -
cd /opt/sentry/onpremise/
git pull
./install.sh

At the end of the installation, there’s an error that was logged:

django.db.migrations.exceptions.InconsistentMigrationHistory: Migration social_auth.0001_initial is applied before its dependency sentry.0001_squashed_0200_release_indices on database 'default'.
An error occurred, caught SIGERR on line 12
Cleaning up...

I then did:

docker-compose up -d

So far everything looks fine other than when I click on Releases on the sidebar I get this error:


Oops! Something went wrong

It looks like you’ve hit an issue in our client application. Don’t worry though! We use Sentry to monitor Sentry and it’s likely we’re already looking into this!

If you’re daring, you may want to try the following:

  • Give it a few seconds and reload the page.
  • If all else fails, contact us with more details.

We’re not using the Releases feature yet so right now this error doesn’t really affect us but I’m not sure if this is something I can just ignore or is it going to break our installation of Sentry?

Please try upgrading to 21.6.3 which fixes some known migration issues in earlier 21.6.x issues. Then you’ll be able to move on to 21.7.0+.

Uhmm… our instance shows we have Sentry 21.8.0.dev0 (c23bfb9).

Doesn’t matter, you are probably following nightly builds, and they had issues related to migrations for a few days. You need to go back to 21.6.3 and then move forward.

Oh okay… do you have instructions on how to install a specific version? Also, when I update, how do I make sure that I’m only installing stable builds and not the nightly builds?

Sorry I’m kinda new to git.

No worries, you can check our docs for these:

Happy to fix/clarify these docs for the bits you find not as helpful btw.

No the documentation is fine, I just needed the git commands but that’s okay I found them, hopefully I did this one correctly:

cd /opt/sentry/onpremise/
git checkout master
git pull
git tag -l
git checkout tags/21.6.3
./install.sh
docker-compose up -d

And then did the same for 21.7.0.

Yup, looks right to me.

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.