Remove support for Python 2.7
This commit is contained in:
1 parent
3723655fa3
commit
b79f8b30eb
13 files changed
+10
-62
No files matched your search
@@ -1,5 +1,3 @@
|
||||
from __future__ import print_function
|
||||
|
||||
from collections import deque
|
||||
from threading import RLock
|
||||
import zlib
|
||||
@@ -11,8 +9,6 @@ import sys
|
||||
import json
|
||||
import re
|
||||
|
||||
from future.utils import raise_
|
||||
|
||||
from .types import VarInt
|
||||
from .packets import clientbound, serverbound
|
||||
from . import packets
|
||||
@@ -491,7 +487,8 @@ class Connection(object):
|
||||
|
||||
# If allowed by the final exception handler, re-raise the exception.
|
||||
if self.handle_exception is None and not caught:
|
||||
raise_(*exc_info)
|
||||
exc_value, exc_tb = exc_info[1:]
|
||||
raise exc_value.with_traceback(exc_tb)
|
||||
|
||||
def _version_mismatch(self, server_protocol=None, server_version=None):
|
||||
if server_protocol is None:
|
||||
@@ -592,7 +589,8 @@ class NetworkingThread(threading.Thread):
|
||||
exc_info = None
|
||||
|
||||
if exc_info is not None:
|
||||
raise_(*exc_info)
|
||||
exc_value, exc_tb = exc_info[1:]
|
||||
raise exc_value.with_traceback(exc_tb)
|
||||
|
||||
|
||||
class PacketReactor(object):
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
Each type has a method which is used to read and write it.
|
||||
These definitions and methods are used by the packet definitions
|
||||
"""
|
||||
from __future__ import division
|
||||
import struct
|
||||
import uuid
|
||||
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
"""Minecraft data types that are used by packets, but don't have a specific
|
||||
network representation.
|
||||
"""
|
||||
from __future__ import division
|
||||
|
||||
from collections import namedtuple
|
||||
from itertools import chain
|
||||
|
||||
|
||||
Reference in new issue
Block a user