Skip to content

Commit

Permalink
python -m incremental.update Twisted --rc
Browse files Browse the repository at this point in the history
  • Loading branch information
adiroiban committed Oct 26, 2022
1 parent f2f5e81 commit 0a29d34
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion src/twisted/_version.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@

from incremental import Version

__version__ = Version("Twisted", 22, 8, 0, post=0)
__version__ = Version("Twisted", 22, 10, 0, release_candidate=1)
__all__ = ["__version__"]
10 changes: 5 additions & 5 deletions src/twisted/python/deprecate.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,14 @@
from incremental import Version
from twisted.python.deprecate import deprecated
@deprecated(Version("Twisted", "NEXT", 0, 0))
@deprecated(Version("Twisted", 22, 10, 0, release_candidate=1))
def badAPI(self, first, second):
'''
Docstring for badAPI.
'''
...
@deprecated(Version("Twisted", "NEXT", 0, 0))
@deprecated(Version("Twisted", 22, 10, 0, release_candidate=1))
class BadClass:
'''
Docstring for BadClass.
Expand All @@ -34,7 +34,7 @@ class BadClass:
class OtherwiseUndeprecatedClass:
@deprecatedProperty(Version("Twisted", "NEXT", 0, 0))
@deprecatedProperty(Version("Twisted", 22, 10, 0, release_candidate=1))
def badProperty(self):
'''
Docstring for badProperty.
Expand All @@ -54,7 +54,7 @@ def badProperty(self, value):
...
deprecatedModuleAttribute(
Version("Twisted", "NEXT", 0, 0),
Version("Twisted", 22, 10, 0, release_candidate=1),
"Use goodAttribute instead.",
"your.full.module.name",
"badAttribute")
Expand All @@ -68,7 +68,7 @@ def badProperty(self, value):
To mark an optional, keyword parameter of a function or method as deprecated
without deprecating the function itself, you can use::
@deprecatedKeywordParameter(Version("Twisted", "NEXT", 0, 0), "baz")
@deprecatedKeywordParameter(Version("Twisted", 22, 10, 0, release_candidate=1), "baz")
def someFunction(foo, bar=0, baz=None):
...
Expand Down
12 changes: 6 additions & 6 deletions src/twisted/web/resource.py
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,7 @@ class _UnsafeErrorPage(Resource):
(parameterized) status and a body consisting of HTML containing some
descriptive text. This is useful for rendering simple error pages.
Deprecated in Twisted NEXT because it permits HTML injection; use
Deprecated in Twisted 22.10.0.rc1 because it permits HTML injection; use
L{twisted.web.pages.errorPage} instead.
@ivar template: A native string which will have a dictionary interpolated
Expand Down Expand Up @@ -359,7 +359,7 @@ class _UnsafeNoResource(_UnsafeErrorPage):
C{NoResource}, is a specialization of L{_UnsafeErrorPage} which
returns the HTTP response code I{NOT FOUND}.
Deprecated in Twisted NEXT because it permits HTML injection; use
Deprecated in Twisted 22.10.0.rc1 because it permits HTML injection; use
L{twisted.web.pages.notFound} instead.
"""

Expand All @@ -373,7 +373,7 @@ class _UnsafeForbiddenResource(_UnsafeErrorPage):
C{ForbiddenResource} is a specialization of L{_UnsafeErrorPage} which
returns the I{FORBIDDEN} HTTP response code.
Deprecated in Twisted NEXT because it permits HTML injection; use
Deprecated in Twisted 22.10.0.rc1 because it permits HTML injection; use
L{twisted.web.pages.forbidden} instead.
"""

Expand All @@ -387,21 +387,21 @@ def __init__(self, message="Sorry, resource is forbidden."):
ForbiddenResource = _UnsafeForbiddenResource

deprecatedModuleAttribute(
Version("Twisted", "NEXT", 0, 0),
Version("Twisted", 22, 10, 0, release_candidate=1),
"Use twisted.web.pages.errorPage instead, which properly escapes HTML.",
__name__,
"ErrorPage",
)

deprecatedModuleAttribute(
Version("Twisted", "NEXT", 0, 0),
Version("Twisted", 22, 10, 0, release_candidate=1),
"Use twisted.web.pages.notFound instead, which properly escapes HTML.",
__name__,
"NoResource",
)

deprecatedModuleAttribute(
Version("Twisted", "NEXT", 0, 0),
Version("Twisted", 22, 10, 0, release_candidate=1),
"Use twisted.web.pages.forbidden instead, which properly escapes HTML.",
__name__,
"ForbiddenResource",
Expand Down

0 comments on commit 0a29d34

Please sign in to comment.