Error: the singular name "dpa" should be unique

System Information
  • Strapi Version:
  • Operating System:
  • Database:
  • Node Version:
  • NPM Version:
  • Yarn Version:

This error seems to have appeared from nowhere as it was working fine when I last worked on this project 4 days ago.

And this is my content-types\dpa schema.json

{
  "kind": "collectionType",
  "collectionName": "dpas",
  "info": {
    "singularName": "dpa",
    "pluralName": "dpas",
    "displayName": "DGTIT-Dpa",
    "description": ""
  },
  "options": {
    "draftAndPublish": true
  },
  "pluginOptions": {},
  "attributes": {
    "endereco": {
      "type": "string",
      "required": true,
      "maxLength": 300,
      "minLength": 15
    },
    "responsavel": {
      "type": "string",
      "required": true,
      "maxLength": 100,
      "minLength": 15
    },
    "telefone": {
      "type": "text",
      "required": false,
      "minLength": 8,
      "maxLength": 100
    },
    "categoria": {
      "type": "enumeration",
      "enum": [
        "Capital",
        "Baixada",
        "Interior",
        "Especializada",
        "Homicídios",
        "Polícia Técnica",
        "Atendimento à Mulher",
        "Lavagem de Dinheiro",
        "Acervo Cartorário"
      ],
      "required": true
    },
    "nome": {
      "type": "string",
      "unique": true,
      "required": true,
      "maxLength": 100,
      "minLength": 3
    },
    "link": {
      "type": "text",
      "required": false,
      "maxLength": 1000,
      "minLength": 4
    }
  }
}

Hey @Luiza_Rodrigues_de_S

I tried to recreate your issue by creating the same content type as yours but it seems to work normal with proper server restart.

Have you tried deleting the content type and recreate it again? If not give it a try :slight_smile: