Is Python going to adopt an official replacement for the cgi module such that a message will be included when the following message is generated (i.e., import this_module_as_replacement) when attempting to import the cgi?
I believe Python’s official stance is to stop using CGI and use a different framework/architecture. If you want to continue using CGI, your options are:
Don’t upgrade to Python 3.13
Rewrite your application to use something other than CGI
And nowhere is there a history of modules being deleted with recommendations for replacement?
I.e. not only for version 3.13 but also for previous ones, at least for python3.
And nowhere is there a history of modules being deleted with
recommendations for replacement? I.e. not only for version 3.13
but also for previous ones, at least for python3.
3.13 was fairly notable because it was a large batch, but PEP 594
did also cover some things that were removed in 3.12, and is AFAIK
essentially the first real cleanup since 3.0 (many of the removals
referenced were proposed for deprecation as early as the 2.0 and 3.0
release timeframes).
Any contemporary recommendations for replacement of older removals
decades ago are likely to be outdated now though, and increasingly
useless as time goes by.
I think maybe I can still suggest the idea of keeping a history of deleted modules, where it will be possible to at least quickly understand which modules were deleted earlier.
There will probably be such deletions in the future, and it will be easier to see the full list of deletions by python version than to run through the history of each version.
It was curious if there were original third-party CGI libraries for Python that were maintained and went looking. I didn’t find any, but I found a project called “legacy-cgi” (PyPI, GitHub). It packages cgi and cgitb for Python >= 3.10.