mirror of
https://github.com/python/cpython.git
synced 2025-08-03 16:39:00 +00:00
Deprecate Bastion and rexec for 3.0.
This commit is contained in:
parent
ccdf9081b7
commit
4c1f881f13
5 changed files with 17 additions and 2 deletions
|
@ -4,6 +4,11 @@
|
|||
|
||||
.. module:: Bastion
|
||||
:synopsis: Providing restricted access to objects.
|
||||
:deprecated:
|
||||
|
||||
.. deprecated:: 2.6
|
||||
The Bastion module has been removed in Python 3.0.
|
||||
|
||||
.. moduleauthor:: Barry Warsaw <bwarsaw@python.org>
|
||||
|
||||
|
||||
|
|
|
@ -4,7 +4,10 @@
|
|||
|
||||
.. module:: rexec
|
||||
:synopsis: Basic restricted execution framework.
|
||||
|
||||
:deprecated:
|
||||
|
||||
.. deprecated:: 2.6
|
||||
The rexec module has been removed in Python 3.0.
|
||||
|
||||
.. versionchanged:: 2.3
|
||||
Disabled module.
|
||||
|
|
|
@ -25,6 +25,9 @@ the repr() of the original object. This is precomputed when the
|
|||
bastion is created.
|
||||
|
||||
"""
|
||||
from warnings import warnpy3k
|
||||
warnpy3k("the Bastion module has been removed in Python 3.0", stacklevel=2)
|
||||
del warnpy3k
|
||||
|
||||
__all__ = ["BastionClass", "Bastion"]
|
||||
|
||||
|
|
|
@ -16,6 +16,9 @@ XXX To do:
|
|||
- r_exec etc. with explicit globals/locals? (Use rexec("exec ... in ...")?)
|
||||
|
||||
"""
|
||||
from warnings import warnpy3k
|
||||
warnpy3k("the rexec module has been removed in Python 3.0", stacklevel=2)
|
||||
del warnpy3k
|
||||
|
||||
|
||||
import sys
|
||||
|
|
|
@ -128,7 +128,8 @@ class TestStdlibRemovals(unittest.TestCase):
|
|||
|
||||
# test.testall not tested as it executes all unit tests as an
|
||||
# import side-effect.
|
||||
all_platforms = ('audiodev', 'imputil', 'mutex', 'user', 'new')
|
||||
all_platforms = ('audiodev', 'imputil', 'mutex', 'user', 'new', 'rexec',
|
||||
'Bastion')
|
||||
inclusive_platforms = {'irix':('pure',)}
|
||||
|
||||
def check_removal(self, module_name, optional=False):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue