ara icon indicating copy to clipboard operation
ara copied to clipboard

(models.W042) Auto-created primary key used when not defining a primary key type, by default 'django.db.models.AutoField'.

Open dmsimard opened this issue 3 years ago • 1 comments

What is the issue ?

Spotted this warning in CI when generating a static report:

2022-01-18 14:59:07.432124 | TASK [Generate a static report]
2022-01-18 14:59:08.383679 | fedora-35 | [ara] Using settings file: /opt/ara/settings.yaml
2022-01-18 14:59:08.761752 | fedora-35 | System check identified some issues:
2022-01-18 14:59:08.761832 | fedora-35 |
2022-01-18 14:59:08.761999 | fedora-35 | WARNINGS:
2022-01-18 14:59:08.762099 | fedora-35 | db.TestModel: (models.W042) Auto-created primary key used when not defining a primary key type, by default 'django.db.models.AutoField'.
2022-01-18 14:59:08.762282 | fedora-35 |        HINT: Configure the DEFAULT_AUTO_FIELD setting or the HealthCheckConfig.default_auto_field attribute to point to a subclass of AutoField, e.g. 'django.db.models.BigAutoField'.

Looks related to the healthcheck plugin configuration.

What should be happening ?

It's a new warning. We should fix it.

dmsimard avatar Jan 18 '22 15:01 dmsimard

### WARNINGS: student_management_app.CustomUser: (models.W042) Auto-created primary key used when not defining a primary key type, by default 'django.db.models.AutoField'. HINT: Configure the DEFAULT_AUTO_FIELD setting or the StudentManagementAppConfig.default_auto_field attribute to point to a subclass of AutoField, e.g. 'django.db.models.BigAutoField'. No changes detected

HabibsCoders avatar Apr 27 '22 10:04 HabibsCoders