forked from mitmproxy/mitmproxy
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
https://github.com/python-hyper/wsproto.git commit 5ea2da61266796666f5de6461aaae22e6b00deba
- Loading branch information
Showing
7 changed files
with
1,419 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# flake8: noqa | ||
|
||
import sys | ||
|
||
|
||
PY2 = sys.version_info.major == 2 | ||
PY3 = sys.version_info.major == 3 | ||
|
||
|
||
if PY3: | ||
unicode = str | ||
|
||
def Utf8Validator(): | ||
return None | ||
else: | ||
unicode = unicode | ||
try: | ||
from wsaccel.utf8validator import Utf8Validator | ||
except ImportError: | ||
from .utf8validator import Utf8Validator |
Oops, something went wrong.