Opened 2 years ago

Last modified 13 months ago

#5715 task new

Get rid of references and code specific to Python 2.5

Reported by: vperic Owned by:
Priority: lowest Milestone:
Component: core Keywords:
Cc: thijs Branch:
Author: Launchpad Bug:

Description (last modified by thijs)

After ticket #5553 officially drops Python 2.5 support, we should get rid of code referencing Python 2.5 specifically. This should probably only be done after #5386 (the same for Python 2.3) and #5387 (2.4).

Some of these comments can be removed, some might require the removal of code as well; grep gives the following mentions of Python 2.5:

./twisted/trial/test/test_assertions.py:724:            # Python 2.5 and earlier, stacklevel of 0 resulted in a warning
./twisted/web/_flatten.py:314:            # In Python 2.5, after an exception, a generator's gi_frame is
./twisted/python/util.py:873:    2.5's implementation of L{id} always returns positive values.
./twisted/python/filepath.py:333:            # Under Python 2.5 on Windows, WindowsError has a winerror
./twisted/python/filepath.py:348:            # ERROR_PATH_NOT_FOUND.  However, in Python 2.5,
./twisted/python/filepath.py:608:    precision, call C{os.stat_float_times(True)}, or use Python 2.5.
./twisted/python/filepath.py:609:    Greater-than-second precision is only available in Windows on Python2.5 and
./twisted/python/dist.py:422:    On 2.5, it will try to extract the implementation from sys.subversion. On
./twisted/python/dist.py:437:        # For 2.5:
./twisted/internet/selectreactor.py:119:            # subclass, but on Python 2.5 and earlier it is not.)
./twisted/conch/checkers.py:18:    # Python 2.5 got spwd to interface with shadow passwords
./twisted/test/test_failure.py:859:    Tests C{failure.Failure} support for generator features added in Python 2.5
./twisted/internet/unix.py:230:        if sys.version_info > (2, 5) or _inFilesystemNamespace(self.port):
./twisted/test/test_twisted.py:192:    unsupportedPythonVersion = (2, 5)

Change History (5)

comment:1 Changed 2 years ago by exarkun

  • Keywords easy removed
  • Priority changed from normal to lowest

comment:2 Changed 21 months ago by thijs

  • Cc thijs added

comment:3 Changed 13 months ago by thijs

  • Description modified (diff)

Update ticket description.

comment:4 in reply to: ↑ description ; follow-up: Changed 13 months ago by thijs

Replying to vperic:

./twisted/trial/test/test_assertions.py:724: # Python 2.5 and earlier, stacklevel of 0 resulted in a warning

This seems like a test worth to keep around.

./twisted/web/_flatten.py:314: # In Python 2.5, after an exception, a generator's gi_frame is
./twisted/python/util.py:873: 2.5's implementation of L{id} always returns positive values.

I've opened a new ticket for this so it can be deprecated at some later release (it's deprecated in 13.0 and 14+ seems a better time-frame to completely remove it).

./twisted/python/filepath.py:333: # Under Python 2.5 on Windows, WindowsError has a winerror
./twisted/python/filepath.py:348: # ERROR_PATH_NOT_FOUND. However, in Python 2.5,

These two are reported in #6627.

comment:5 in reply to: ↑ 4 Changed 13 months ago by thijs

Replying to thijs:

./twisted/python/util.py:873: 2.5's implementation of L{id} always returns positive values.

I've opened a new ticket for this so it can be deprecated at some later release (it's deprecated in 13.0 and 14+ seems a better time-frame to completely remove it).

That's ticket #6707.

Note: See TracTickets for help on using tickets.