From f209854e0458e9867b3ca09b76b1940849d663d7 Mon Sep 17 00:00:00 2001 From: Brian Armstrong Date: Fri, 16 Apr 2021 11:21:45 -0400 Subject: [PATCH 1/2] Remove changeReason and update CHANGES --- CHANGES.rst | 11 ++++++++--- simple_history/utils.py | 9 --------- 2 files changed, 8 insertions(+), 12 deletions(-) diff --git a/CHANGES.rst b/CHANGES.rst index 5ae818c11..2c11668d8 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -3,6 +3,9 @@ Changes Unreleased ---------- + +3.0.0 (2021-04-16) +---------- - Removed support for Django versions prior to 2.2 (gh-652) - Migrate from TravisCI to Github Actions (gh-739) - Add Python 3.9 support (gh-745) @@ -10,9 +13,11 @@ Unreleased - Use ``asgiref`` when available instead of thread locals (gh-747) - Sort imports with isort (gh-751) - Queryset ``history.as_of`` speed improvements by calculating in the DB (gh-758) -- Increase `black` and `isort` python version to 3.6 -- Remove Django 3.0 support -- Add Django 3.2 support +- Increase `black` and `isort` python version to 3.6 (gh-817) +- Remove Django 3.0 support (gh-817) +- Add Django 3.2 support (gh-817) +- Improve French translations (gh-811) +- Remove support for changeReason (gh-819) 2.12.0 (2020-10-14) ------------------- diff --git a/simple_history/utils.py b/simple_history/utils.py index f7290b4c5..d2106faa7 100644 --- a/simple_history/utils.py +++ b/simple_history/utils.py @@ -164,13 +164,4 @@ def get_change_reason_from_object(obj): if hasattr(obj, "_change_reason"): return getattr(obj, "_change_reason") - if hasattr(obj, "changeReason"): - warning_msg = ( - "Using the attr changeReason to populate history_change_reason is" - " deprecated in 2.10.0 and will be removed in 3.0.0. Use " - "_change_reason instead. " - ) - warnings.warn(warning_msg, DeprecationWarning) - return getattr(obj, "changeReason") - return None From 73dc35833e01114bc7cb45fa10cd94e767121857 Mon Sep 17 00:00:00 2001 From: Brian Armstrong Date: Fri, 16 Apr 2021 12:37:22 -0400 Subject: [PATCH 2/2] call out breaking changes --- CHANGES.rst | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/CHANGES.rst b/CHANGES.rst index 2c11668d8..94c74d798 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -6,6 +6,14 @@ Unreleased 3.0.0 (2021-04-16) ---------- + +Breaking changes: + +- Removed support for Django 3.0 +- Removed `changeReason` in favor of `_change_reason` (see 2.10.0) + +Full list of changes: + - Removed support for Django versions prior to 2.2 (gh-652) - Migrate from TravisCI to Github Actions (gh-739) - Add Python 3.9 support (gh-745)