python-irodsclient icon indicating copy to clipboard operation
python-irodsclient copied to clipboard

Eliminate all python2 compatibility concerns from the codebase

Open d-w-moore opened this issue 2 years ago • 2 comments

In a not-far-off future release, we plan to stop adhering to any sort of standard for Python2 compatibility.
More than than, we want to purge the code base of any signs the Python iRODS Client ever ran on Python 2.x : )

At the least, this means:

  • deleting all python2-isms esp. if they complicate or obfuscate otherwise clear, understandable code.
  • not having to use the six module or recast code to account for the possibility of running on Python2
  • not duplicating tests for the purpose of testing Python2 compatibility
  • removing atrocious former necessities such as MyIntEnum
  • using f""-strings as widely as possible, because they work better and make the code more succinct.
  • undoubtedly even more such changes as benefit developer sanity and decrease development overhead that seems pointless, since no use of Python2 with PRC has been evident for years

d-w-moore avatar Oct 27 '23 22:10 d-w-moore

Yes please. Only as part of a new 'major' release of this client library.

trel avatar Oct 31 '23 01:10 trel

Note the guidelines in the description here are to be applied only for source changes made after v3.0.0 has been released (projected to be our first Python3-only release). Format-strings (f"...") particularly should be disallowed til then, as the presence of even one of these in a source file prevents it from being parsed by the Python2 interpreter.

d-w-moore avatar Jul 30 '24 13:07 d-w-moore