From f5d65ecdb04c9ada63a5a90cf758321a1aa81ae6 Mon Sep 17 00:00:00 2001 From: Mikkel Munch Mortensen <3xm@detfalskested.dk> Date: Tue, 5 Nov 2024 13:23:33 +0100 Subject: [PATCH] Add deprecation warning about potential sunsetting --- README.md | 21 +++++++++++++++++++++ docs/index.rst | 8 +++++++- drf_haystack/__init__.py | 34 +++++++++++++++++++++++++++++++++- 3 files changed, 61 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 587f483..af4b6d9 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,24 @@ +🚨 Maintainers wanted 🚨 +======================== + +**This project urgently needs new maintainers!** + +The current maintainers are no longer actively using `drf-haystack` and would +like to [hand over the project to other developers](https://github.com/rhblind/drf-haystack/issues/146) who are using the package. + +We will still do the bare minimum maintenance of keeping dependency references +up to date with new releases of related packages **until January 1st 2026**. + +If by that time no new maintainers have joined to take over the project, we +will archive the project and make the repository read-only, with a final +release with whatever versions the dependencies have at that time. + +This gives everyone more than a year to either consider joining as maintainers +or switch to other packages for handling their search in DRF. + +_The `drf-haystack` maintainers, November 2024_ + + Haystack for Django REST Framework ================================== diff --git a/docs/index.rst b/docs/index.rst index dc0a687..8f62b74 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -105,9 +105,15 @@ Thanks guys! Changelog ========= +v1.9.1 +------ +*Release date: 2024-11-05* + + - Add deprecation warning about potential future sunsetting of the project, due to lack of active maintainers. + v1.9 ------ -*Release date: 2023-10-04* +*Release date: 2024-11-04* - Return an empty query object instead of an empty list when no filter is passed (:drf-issue:`202`). - add "id" as an optional value of the serializer fields returning the haystack internal id (:drf-issue:`193`). diff --git a/drf_haystack/__init__.py b/drf_haystack/__init__.py index 109041f..bcf5dbd 100644 --- a/drf_haystack/__init__.py +++ b/drf_haystack/__init__.py @@ -1,10 +1,42 @@ # -*- coding: utf-8 -*- from __future__ import unicode_literals +import warnings + __title__ = "drf-haystack" -__version__ = "1.9" +__version__ = "1.9.1" __author__ = "Rolf Haavard Blindheim" __license__ = "MIT License" VERSION = __version__ + + +def show_sunset_warning(): + """Show a warning about potential future sunsetting.""" + message = ( + "\n" + "==============================================================================\n" + "The `drf-haystack` project urgently needs new maintainers!\n" + "\n" + "The current maintainers are no longer actively using drf-haystack and would\n" + "like to hand over the project to other developers who are using the package.\n" + "\n" + "We will still do the bare minimum maintenance of keeping dependency references\n" + "up to date with new releases of related packages until January 1st 2026.\n" + "\n" + "If by that time no new maintainers have joined to take over the project, we\n" + "will archive the project and make the repository read-only, with a final\n" + "release with whatever versions the dependencies have at that time.\n" + "\n" + "This gives everyone more than a year to either consider joining as maintainers\n" + "or switch to other packages for handling their search in DRF.\n" + "\n" + "Do you want to join as a maintainer? Have a look at:\n" + "\n" + "==============================================================================\n" + ) + warnings.warn(message, UserWarning, stacklevel=2) + + +show_sunset_warning()