jhuapl-boss / boss-oidc

Django Auth plugin specific to the Boss SSO Server
Apache License 2.0
13 stars 22 forks source link

Could not import 'path.to.function' for API setting 'LOAD_USER_ROLES'. ModuleNotFoundError: No module named 'path'. #35

Open rkpip3 opened 4 years ago

rkpip3 commented 4 years ago

Please help me with error:

Could not import 'path.to.function' for API setting 'LOAD_USER_ROLES'. ModuleNotFoundError: No module named 'path'.

LOAD_USER_ROLES = 'path.to.function'

movestill commented 4 years ago

You need to change path.to.function to an actual Python dotted path to the function you use to load user roles.

Note that what's in master is very old and integrates with django-oidc which is no longer maintained. We're switching to mozilla-django-oidc. Work for that is in the mozilla branch of this repo.

rkpip3 commented 4 years ago

@movestill any example project with mozilla-django-oidc, django rest api