Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

You have TENANT_APPS that are not in INSTALLED_APPS but their are.. #561

Closed
fellipeh opened this issue Aug 22, 2018 · 5 comments
Closed

Comments

@fellipeh
Copy link

I try to make migrate, but get these error:

SystemCheckError: System check identified some issues:

ERRORS:
?: (tenant_schemas.E002) You have TENANT_APPS that are not in INSTALLED_APPS
	HINT: ['account.apps.AccountConfig', 'core.apps.CoreConfig', 'cadastro.apps.CadastroConfig', 'financeiro.apps.FinanceiroConfig']
?: (tenant_schemas.E003) You have SHARED_APPS that are not in INSTALLED_APPS
	HINT: ['publico.apps.PublicoConfig']

Process finished with exit code 1

But I put all on INSTALLED_APPS:

SHARED_APPS = (
    'tenant_schemas',  # mandatory, should always be before any django app
    'publico.apps.PublicoConfig',  # you must list the app where your tenant model resides in
    'django.contrib.contenttypes',

    # everything below here is optional
    'django.contrib.admin',
    'django.contrib.auth',
    'django.contrib.sessions',
    'django.contrib.messages',
    'django.contrib.staticfiles',
    'django.contrib.sites',
)

TENANT_APPS = (
    'django.contrib.contenttypes',

    # your tenant-specific apps
    # 3rd apps
    'widget_tweaks',
    'bootstrap3',
    'crispy_forms',
    'password_reset',
    'rest_framework',
    'forms_builder.forms',

    # ERPbr apps
    'account.apps.AccountConfig',
    # 'api.apps.ApiConfig',
    'core.apps.CoreConfig',
    'cadastro.apps.CadastroConfig',
    'financeiro.apps.FinanceiroConfig',
)

INSTALLED_APPS = [
    'tenant_schemas',  # mandatory, should always be before any django app
    'publico.apps.PublicoConfig',  # you must list the app where your tenant model resides in
    'django.contrib.contenttypes',

    # everything below here is optional
    'django.contrib.admin',
    'django.contrib.auth',
    'django.contrib.sessions',
    'django.contrib.messages',
    'django.contrib.staticfiles',
    'django.contrib.sites',

    'widget_tweaks',
    'bootstrap3',
    'crispy_forms',
    'password_reset',
    'rest_framework',
    'forms_builder.forms',

    # ERPbr apps
    'account.apps.AccountConfig',
    # 'api.apps.ApiConfig',
    'core.apps.CoreConfig',
    'cadastro.apps.CadastroConfig',
    'financeiro.apps.FinanceiroConfig',

]

What's I doing wrong?

@jeroenbrouwer
Copy link

Your INSTALLED_APPS is mutable (list), are you sure you aren't mutating it later on by popping the list for example?

@fellipeh
Copy link
Author

There's a error inside apps.py from tenant-schemas.. I fix that, and send PR...

@pjdupreez
Copy link

@fellipeh what was the bug?

@ebram96
Copy link
Contributor

ebram96 commented Mar 9, 2022

@fellipeh
I'm using 1.11.0 and it doesn't seem to be fixed ??

@fellipeh
Copy link
Author

fellipeh commented Apr 7, 2022

@pjdupreez @ebram96 here is the PR: #569

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants