eregs / regulations-parser

Parser for U.S. federal regulations and other regulatory information
Creative Commons Zero v1.0 Universal
37 stars 39 forks source link

Django error #400

Open Alea4jacta6est opened 3 years ago

Alea4jacta6est commented 3 years ago

django.core.exceptions.ImproperlyConfigured: Cannot import 'jobs'. Check that 'regparser.web.jobs.apps.JobsConfig.name' is correct. when using cmd version of the app

johnnyporkchops commented 2 years ago

If you are using Django >= 3.2, there are changes that may cause this issue: https://docs.djangoproject.com/en/3.2/releases/3.2/#what-s-new-in-django-3-2

We fixed this in our instance of the app by : in settings/base.py in regulations-parser AND Eregulations:

DEFAULT_AUTO_FIELD = 'django.db.models.AutoField'

And in regparser/web/jobs/apps.py in regulations-parser, put full path to the app:

name = 'regparser.web.jobs'

Hope this helps.