ensky / taiga-contrib-ldap-auth

Taiga plugin for LDAP authentication
http://taiga.io
GNU Affero General Public License v3.0
54 stars 37 forks source link

AttributeError: module 'django.db.models' has no attribute 'get_model' #38

Open rafamunozg opened 8 years ago

rafamunozg commented 8 years ago

Hi guys. I'm trying to setup ldap in my instance. I'm following the steps for CentOS to run it on RH7, but I got to a point that when I followed the steps you provided to install the LDAP contribution, I need to keep adding "Installed Apps" to my local.py to avoid errors, but not this one.

I have been adding apps to my local.py based on errors like the following, when trying to run "manage.py runserver"

_RuntimeError: Model class taiga.webhooks.models.Webhook doesn't declare an explicit app_label and isn't in an application in INSTALLEDAPPS.

But after adding the taiga.webhooks app, the following error is the one in the title of this post. Have you seen this problem?

The list of installed apps so far is the following: INSTALLED_APPS = [ "django.contrib.auth", "django.contrib.contenttypes", "django.db", "taiga.users", "taiga.userstorage", "taiga.projects", "taiga.projects.history", "taiga.projects.notifications", "taiga.timeline", "taiga.webhooks", "djmail", "easy_thumbnails", "taiga_contrib_ldap_auth", ]

Thanks in advance!

RMG


Edit: Searching a little more, I found this in the django's swappable models repo that I think is relevant to this discussion. It happens that .get_model was deprecated on django 9 and that's the version required by the current version of taiga-back.

Have you gone through that yet? Thanks again.

veox commented 7 years ago

You probably updated Django to 1.10. If so, try reverting to 1.9.

rafamunozg commented 7 years ago

You are right. I installed the docker image available from ipedrazas (https://github.com/ipedrazas/taiga-docker), it worked great that way and I was able to run Taiga, but not the LDAP plugin.

Then I did the manual install and that is also installing a newer version of Django, I'm concerned that the latest version of Taiga will not work on the previous version of Django, but I haven't tried.

Is there any plan to make the plugin compatible with 1.10?

Thanks!

veox commented 7 years ago

Django 1.9 is a dependency of taiga-back AFAIK. I guess once that starts using 1.10, so should this plugin, but not before - or it can be done as mentioned in your link on swappable models.