debugpy/ptvsd/compat.py
Pavel Minaev b47df51478
Test & infrastructure cleanup, stage 1 (#850)
* Add new JSON IPC implementation to be shared between the product and the tests.

Add pytest-based test support, and wire it up to setup.py and Travis.

Dial pylint down to complain about important things only.

Various minor fixes exposed by pylint.

Add basic .vscode/settings.json for linter settings (and anything else that's workspace-specific).

Fixes #831.
2018-09-27 00:36:48 -07:00

23 lines
458 B
Python

# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See LICENSE in the project root
# for license information.
# Python 2.x/3.x compatibility helpers
try:
import builtins
except:
import __builtin__ as builtins
try:
unicode = builtins.unicode
bytes = builtins.str
except:
unicode = builtins.str
bytes = builtins.bytes
try:
xrange = builtins.xrange
except:
xrange = builtins.range