divio / aldryn-newsblog

A combined news/weblog application for Aldryn and django CMS – part of the Essential Addons.
https://marketplace.django-cms.org/en/addons/browse/aldryn-newsblog/
Other
67 stars 118 forks source link

mysql settings option error #421

Open abc101 opened 8 years ago

abc101 commented 8 years ago

Python 3.4 django 1.8 cms 3.3 aldryn-newblog current version

If I use mysql options on settings.py like

# settings.py
DATABASES = {
    'default': {
        'ENGINE': 'django.db.backends.mysql',
        'OPTIONS': {
            'read_default_file': '/path/to/my.cnf',
        },
    }
}

there are errors

   _mysql.connection.query(self, query)
django.db.utils.OperationalError: (1025, "Error on rename of './djangocms_tutorial/#sql-524_2852' to './djangocms_tutorial/aldryn_people_person' (errno: 150)")

If I use a normal database setting like

DATABASES = {
    'default': {
        'CONN_MAX_AGE': 0,
        'ENGINE': 'django.db.backends.mysql',
        'HOST': 'localhost',
        'NAME': 'djangcms',
        'PASSWORD': 'password',
        'PORT': '',
        'USER': 'djangcms'
    }
}

no error.