Tuesday, October 18, 2022

Re: PLEASE HELP ME KNOW HOW TO ARRANGE INSTALLED APPS.

Lets take App Directory name tiles.
So inthe installed app list it will be

'tiles.apps.TilesConfig',
Or put simply
'tiles',
Hope it helps .


On Tue, Oct 18, 2022, 06:16 regan opere <reganopere@gmail.com> wrote:
Hello, I am new to django and I am still learning.
I have created two apps core and store and I have registered them in the settings file of my root directory.
 This is the error I get:
django.core.exceptions.ImproperlyConfigured: Application labels aren't unique, duplicates: apps

my settings look like this
INSTALLED_APPS = [
    'django.contrib.admin',
    'django.contrib.auth',
    'django.contrib.contenttypes',
    'django.contrib.sessions',
    'django.contrib.messages',
    'django.contrib.staticfiles',
   
    'apps.core.apps',
   
    'apps.store.apps',


and their individual apps.py look like this:

class CoreConfig(AppConfig):
    default_auto_field = 'django.db.models.BigAutoField'
    name = 'core'
 

and 

class StoreConfig(AppConfig):
    default_auto_field = 'django.db.models.BigAutoField'
    name = 'store'
  


without the second app 'store" the server runs just fine

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/fab8949f-1012-4fad-8259-b63c67195f69n%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CAGoV8nnQ7giNodE94_Rma_asWGR2-%3DEVzjcH99zaAEx2_VCPnQ%40mail.gmail.com.

No comments:

Post a Comment