~kf5jwc/sms-printer

664f82c6b8dc4533e87cdda5bd27caaf3e7ad36a — Kyle Jones 2 years ago 158e508
Update to use Python 3.6

This allows us to use more type hinting
4 files changed, 25 insertions(+), 17 deletions(-)

M Pipfile
M Pipfile.lock
M sms_printer/sms/schemas/__init__.py
M sms_printer/sms/schemas/types.py
M Pipfile => Pipfile +1 -2
@@ 23,5 23,4 @@ mypy = "*"

[requires]


python_version = "3.5"
python_version = "3.6"

M Pipfile.lock => Pipfile.lock +20 -11
@@ 1,11 1,11 @@
{
    "_meta": {
        "hash": {
            "sha256": "8f1516fa624f8674026fd9cbe007802aa0480e14bc0346218ca441e4c64d7265"
            "sha256": "d3d9d2a887f020329d9691f227c06981a74b45b6a6b434b5c42368659ab574ae"
        },
        "pipfile-spec": 6,
        "requires": {
            "python_version": "3.5"
            "python_version": "3.6"
        },
        "sources": [
            {


@@ 81,10 81,10 @@
    "develop": {
        "astroid": {
            "hashes": [
                "sha256:032f6e09161e96f417ea7fad46d3fac7a9019c775f202182c22df0e4f714cb1c",
                "sha256:dea42ae6e0b789b543f728ddae7ddb6740ba33a49fb52c4a4d9cb7bb4aa6ec09"
                "sha256:0ef2bf9f07c3150929b25e8e61b5198c27b0dca195e156f0e4d5bdd89185ca1a",
                "sha256:fc9b582dba0366e63540982c3944a9230cbc6f303641c51483fa547dcc22393a"
            ],
            "version": "==1.6.4"
            "version": "==1.6.5"
        },
        "isort": {
            "hashes": [


@@ 137,17 137,17 @@
        },
        "mypy": {
            "hashes": [
                "sha256:01cf289838f266ae7c6550c813181ee77d21eac9459dbf067e7a95a0a2db9721",
                "sha256:bc251cb31bc236d9fe4bcc442c994c45fff2541f7161ee52dc949741fe9ca3dd"
                "sha256:1b899802a89b67bb68f30d788bba49b61b1f28779436f06b75c03495f9d6ea5c",
                "sha256:f472645347430282d62d1f97d12ccb8741f19f1572b7cf30b58280e4e0818739"
            ],
            "version": "==0.600"
            "version": "==0.610"
        },
        "pylint": {
            "hashes": [
                "sha256:aa519865f8890a5905fa34924fed0f3bfc7d84fc9f9142c16dac52ffecd25a39",
                "sha256:c353d8225195b37cc3aef18248b8f3fe94c5a6a95affaf885ae21a24ca31d8eb"
                "sha256:a48070545c12430cfc4e865bf62f5ad367784765681b3db442d8230f0960aa3c",
                "sha256:fff220bcb996b4f7e2b0f6812fd81507b72ca4d8c4d05daf2655c333800cb9b3"
            ],
            "version": "==1.9.1"
            "version": "==1.9.2"
        },
        "six": {
            "hashes": [


@@ 179,6 179,15 @@
            ],
            "version": "==1.1.0"
        },
        "typing": {
            "hashes": [
                "sha256:3a887b021a77b292e151afb75323dea88a7bc1b3dfa92176cff8e44c8b68bddf",
                "sha256:b2c689d54e1144bbcfd191b0832980a21c2dbcf7b5ff7a66248a60c90e951eb8",
                "sha256:d400a9344254803a2368533e4533a4200d21eb7b6b729c173bc38201a74db3f2"
            ],
            "markers": "python_version < '3.5'",
            "version": "==3.6.4"
        },
        "wrapt": {
            "hashes": [
                "sha256:d4d560d479f2c21e1b5443bbd15fe7ec4b37fe7e53d335d3b9b0a7b1226fe3c6"

M sms_printer/sms/schemas/__init__.py => sms_printer/sms/schemas/__init__.py +1 -1
@@ 22,7 22,7 @@ from . import bandwidth_v1
from . import bandwidth_v2


SCHEMAS = {} # type: Dict[str, Type[types.Parser_Base]]
SCHEMAS: Dict[str, Type[types.Parser_Base]] = {}

SCHEMAS[bandwidth_v1.SCHEMA] = bandwidth_v1.Parser
SCHEMAS[bandwidth_v2.SCHEMA] = bandwidth_v2.Parser

M sms_printer/sms/schemas/types.py => sms_printer/sms/schemas/types.py +3 -3
@@ 2,8 2,8 @@ from typing import List


class sms(object):
    sender = "" # type: str
    text = "" # type: str
    sender: str
    text: str

    def __init__(self, sender: str, text: str) -> None:
        self.sender = sender


@@ 11,7 11,7 @@ class sms(object):


class Parser_Base(object):
    messages = [] # type: List[sms]
    messages: List[sms]

    def __init__(self):
        self.messages = []