From 7a2a363df13f35c1da9a48bfd4738380af319a62 Mon Sep 17 00:00:00 2001
From: Eliot Berriot <contact@eliotberriot.com>
Date: Thu, 7 Jun 2018 13:17:48 +0200
Subject: [PATCH] Fix #291: Added multiple warnings in the documentation that
 you should never run makemigrations yourself

---
 changes/changelog.d/291.enhancement | 13 +++++++++++++
 docs/installation/debian.rst        |  8 ++++++++
 docs/installation/docker.rst        |  9 +++++++++
 docs/upgrading.rst                  | 17 +++++++++++++++++
 4 files changed, 47 insertions(+)
 create mode 100644 changes/changelog.d/291.enhancement

diff --git a/changes/changelog.d/291.enhancement b/changes/changelog.d/291.enhancement
new file mode 100644
index 00000000..1107bb44
--- /dev/null
+++ b/changes/changelog.d/291.enhancement
@@ -0,0 +1,13 @@
+Added multiple warnings in the documentation that you should never
+run makemigrations yourself (#291)
+
+
+About the makemigrations warning
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+You may sometimes get the following warning while applying migrations::
+
+    "Your models have changes that are not yet reflected in a migration, and so won't be applied."
+
+This is a warning, not an error, and it can be safely ignored.
+Never run the ``makemigrations`` command yourself.
diff --git a/docs/installation/debian.rst b/docs/installation/debian.rst
index eb0c3f0e..2a9f39ea 100644
--- a/docs/installation/debian.rst
+++ b/docs/installation/debian.rst
@@ -240,6 +240,14 @@ This will create the required tables and rows.
     You can safely execute this command any time you want, this will only
     run unapplied migrations.
 
+.. warning::
+
+    You may sometimes get the following warning while applying migrations::
+
+        "Your models have changes that are not yet reflected in a migration, and so won't be applied."
+
+    This is a warning, not an error, and it can be safely ignored.
+    Never run the ``makemigrations`` command yourself.
 
 Create an admin account
 -----------------------
diff --git a/docs/installation/docker.rst b/docs/installation/docker.rst
index dc031cae..e0520180 100644
--- a/docs/installation/docker.rst
+++ b/docs/installation/docker.rst
@@ -36,6 +36,15 @@ Run the database container and the initial migrations:
     docker-compose up -d postgres
     docker-compose run --rm api python manage.py migrate
 
+.. warning::
+
+    You may sometimes get the following warning while applying migrations::
+
+        "Your models have changes that are not yet reflected in a migration, and so won't be applied."
+
+    This is a warning, not an error, and it can be safely ignored.
+    Never run the ``makemigrations`` command yourself.
+
 Create your admin user:
 
 .. code-block:: bash
diff --git a/docs/upgrading.rst b/docs/upgrading.rst
index bd3d5578..1b092d74 100644
--- a/docs/upgrading.rst
+++ b/docs/upgrading.rst
@@ -37,6 +37,14 @@ easy:
     # Relaunch the containers
     docker-compose up -d
 
+.. warning::
+
+    You may sometimes get the following warning while applying migrations::
+
+        "Your models have changes that are not yet reflected in a migration, and so won't be applied."
+
+    This is a warning, not an error, and it can be safely ignored.
+    Never run the ``makemigrations`` command yourself.
 
 
 Non-docker setup
@@ -95,3 +103,12 @@ match what is described in :doc:`debian`:
 
     # restart the services
     sudo systemctl restart funkwhale.target
+
+.. warning::
+
+    You may sometimes get the following warning while applying migrations::
+
+        "Your models have changes that are not yet reflected in a migration, and so won't be applied."
+
+    This is a warning, not an error, and it can be safely ignored.
+    Never run the ``makemigrations`` command yourself.
-- 
GitLab