Merge remote-tracking branch 'origin/six' into new_types

This commit is contained in:
Jeppe Klitgaard 2015-04-16 16:52:13 +02:00
commit 474aa5858a
5 changed files with 6 additions and 20 deletions

View File

@ -3,17 +3,4 @@ This module stores code used for making pyCraft compatible with
both Python2 and Python3 while using the same codebase.
"""
# Raw input -> input shenangians
# example
# > from minecraft.compat import input
# > input("asd")
# Hi, I'm pylint, and sometimes I act silly, at which point my programmer
# overlords need to correct me.
# pylint: disable=undefined-variable,redefined-builtin,invalid-name
try:
input = raw_input
except NameError:
input = input
# pylint: enable=undefined-variable,redefined-builtin,invalid-name
# Currently empty, this is sure to grow in time.

View File

@ -1,2 +1,3 @@
cryptography
requests
six

View File

@ -6,7 +6,7 @@ from minecraft import authentication
from minecraft.exceptions import YggdrasilError
from minecraft.networking.connection import Connection
from minecraft.networking.packets import ChatMessagePacket, ChatPacket
from minecraft.compat import input
from six.moves import input
def get_options():

View File

@ -1,8 +1,5 @@
from minecraft import compat # noqa unused-import
import unittest
import unittest # noqa unused-import
class TestCompatInput(unittest.TestCase):
def test_import_input(self):
from minecraft.compat import input # noqa unused-import
# Currently empty, eventually it should grow.

View File

@ -13,6 +13,7 @@ deps =
nose
requests
cryptography
six
[testenv:py27]
deps =