Forums

No such table: django_session - Starting a Pinax project

Hello, I'm implementing a starter project through pinax and I'm following their simple instructions at https://github.com/pinax/pinax-project-account . Unfortunately, my starter page isn't loading. I don't understand why because I'm just following their instructions! I've set my Allowed hosts and made sure the django stuff was uncommented in the wsgi file.

But I keep getting this no such table django_session error. I don't understand how to debug this! Any help?

Did you get any error messages when you ran any of the commands? In particular, when you ran the ./manage.py migrate?

i'm having the same problem. the database seem to be no accessible

Did you run an initial migration on your database?

I got this setting up Pinax wiki starter project. It is caused by the DB getting out of step with the models. The starter projects use a SQlite file. Usually if you delete that, AND delete the pycache folder then re-run migrate and loadata as per their instructions it will be fixed.

I have read online where the sync can get messed up enough that you have to also delete all the pre-generated migrations for each pinax module. Annoying and tedious but not hard.

In my case, I also had a problem because I forgot to set the virtualenv name to the one I created for Pinax....

Thanks for sharing that! Is everything working OK now, then?

Yes!

Although for the next Pinax test (team-wiki) I did have to delete all the existing migration folders for each pinax module. These are in the VM's folder for library files. And I discovered that the makemigrations command does NOT auto generate them. You have to specify the pinax app name for each module. So its more tedious than I thought!

And since team-wiki is still under heavy development, with no stable version released yet, there are a lot of little things you have to fix. But this did fix the db table name errors.