Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
remove ironpython python 2.x version check
  • Loading branch information
eendebakpt committed Mar 7, 2023
commit c8845bcddbc47b506298a250c18d86eaf11a0e13
13 changes: 1 addition & 12 deletions Lib/platform.py
Original file line number Diff line number Diff line change
Expand Up @@ -1046,14 +1046,6 @@ def processor():
r'(?: \(([\d\.]+)\))?'
r' on (.NET [\d\.]+)', re.ASCII)

# IronPython covering 2.6 and 2.7
_ironpython26_sys_version_parser = re.compile(
r'([\d.]+)\s*'
r'\(IronPython\s*'
r'[\d.]+\s*'
r'\(([\d.]+)\) on ([\w.]+ [\d.]+(?: \(\d+-bit\))?)\)'
)

_pypy_sys_version_parser = re.compile(
r'([\w.+]+)\s*'
r'\(#?([^,]+),\s*([\w ]+),\s*([\w :]+)\)\s*'
Expand Down Expand Up @@ -1094,10 +1086,7 @@ def _sys_version(sys_version=None):
if 'IronPython' in sys_version:
# IronPython
name = 'IronPython'
if sys_version.startswith('IronPython'):
match = _ironpython_sys_version_parser.match(sys_version)
else:
match = _ironpython26_sys_version_parser.match(sys_version)
match = _ironpython_sys_version_parser.match(sys_version)

if match is None:
raise ValueError(
Expand Down