diff --git a/.flake8 b/.flake8 index 56091ca..ad648a0 100644 --- a/.flake8 +++ b/.flake8 @@ -1,22 +1,22 @@ -[flake8] -exclude = - tests/* - -extend-ignore = - Q0, E501, C812, E203, W503, # These default to arguing with Black. We might configure some of them eventually - ANN1, # Ignore self and cls annotations - ANN204, ANN206, # return annotations for special methods and class methods - D105, D107, # Missing Docstrings in magic method and __init__ - S311, # Standard pseudo-random generators are not suitable for security/cryptographic purposes. - D401, # First line should be in imperative mood; try rephrasing - D400, # First line should end with a period - D101, # Missing docstring in public class - D106, # Missing docstring in public nested class - - # Plugins we don't currently include: flake8-return - R503, # missing explicit return at the end of function ableto return non-None value. - -max-line-length=100 - -per-file-ignores = - jarvis_core/db/models/__init__.py:F401 +[flake8] +exclude = + tests/* + +extend-ignore = + Q0, E501, C812, E203, W503, # These default to arguing with Black. We might configure some of them eventually + ANN1, # Ignore self and cls annotations + ANN204, ANN206, # return annotations for special methods and class methods + D105, D107, # Missing Docstrings in magic method and __init__ + S311, # Standard pseudo-random generators are not suitable for security/cryptographic purposes. + D401, # First line should be in imperative mood; try rephrasing + D400, # First line should end with a period + D101, # Missing docstring in public class + D106, # Missing docstring in public nested class + + # Plugins we don't currently include: flake8-return + R503, # missing explicit return at the end of function ableto return non-None value. + +max-line-length=100 + +per-file-ignores = + jarvis_core/db/models/__init__.py:F401 diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index b88c6fe..8a4457f 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,49 +1,49 @@ -repos: - - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v4.1.0 - hooks: - - id: check-toml - - id: check-yaml - args: [--unsafe] - - id: check-merge-conflict - - id: requirements-txt-fixer - - id: end-of-file-fixer - - id: debug-statements - language_version: python3.10 - - id: trailing-whitespace - args: [--markdown-linebreak-ext=md] - - - repo: https://github.com/pre-commit/pygrep-hooks - rev: v1.9.0 - hooks: - - id: python-check-blanket-noqa - - - repo: https://github.com/psf/black - rev: 22.1.0 - hooks: - - id: black - args: [--line-length=100, --target-version=py310] - language_version: python3.10 - - - repo: https://github.com/pre-commit/mirrors-isort - rev: V5.10.1 - hooks: - - id: isort - args: ["--profile", "black"] - - - repo: https://github.com/pycqa/flake8 - rev: 4.0.1 - hooks: - - id: flake8 - additional_dependencies: - - flake8-annotations~=2.0 - - flake8-bandit~=2.1 - - flake8-docstrings~=1.5 - - flake8-bugbear - - flake8-comprehensions - - flake8-quotes - - flake8-raise - - flake8-deprecated - - flake8-print - - flake8-return - language_version: python3.10 +repos: + - repo: https://github.com/pre-commit/pre-commit-hooks + rev: v4.1.0 + hooks: + - id: check-toml + - id: check-yaml + args: [--unsafe] + - id: check-merge-conflict + - id: requirements-txt-fixer + - id: end-of-file-fixer + - id: debug-statements + language_version: python3.10 + - id: trailing-whitespace + args: [--markdown-linebreak-ext=md] + + - repo: https://github.com/pre-commit/pygrep-hooks + rev: v1.9.0 + hooks: + - id: python-check-blanket-noqa + + - repo: https://github.com/psf/black + rev: 22.1.0 + hooks: + - id: black + args: [--line-length=100, --target-version=py310] + language_version: python3.10 + + - repo: https://github.com/pre-commit/mirrors-isort + rev: v5.10.1 + hooks: + - id: isort + args: ["--profile", "black"] + + - repo: https://github.com/pycqa/flake8 + rev: 4.0.1 + hooks: + - id: flake8 + additional_dependencies: + - flake8-annotations~=2.0 + #- flake8-bandit # Uncomment once works again + - flake8-docstrings~=1.5 + - flake8-bugbear + - flake8-comprehensions + - flake8-quotes + - flake8-raise + - flake8-deprecated + - flake8-print + - flake8-return + language_version: python3.10 diff --git a/jarvis_core/__init__.py b/jarvis_core/__init__.py index 80f2df5..8201733 100644 --- a/jarvis_core/__init__.py +++ b/jarvis_core/__init__.py @@ -1,2 +1,2 @@ -"""JARVIS core shared functionalities.""" -__version__ = "0.3.0" +"""JARVIS core shared functionalities.""" +__version__ = "0.3.0" diff --git a/jarvis_core/config.py b/jarvis_core/config.py index 8290a57..994a6bb 100644 --- a/jarvis_core/config.py +++ b/jarvis_core/config.py @@ -1,40 +1,40 @@ -"""Load global config.""" -from pathlib import Path -from typing import Union - -from yaml import load - -from jarvis_core.util import Singleton - -try: - from yaml import CLoader as Loader -except ImportError: - from yaml import Loader - - -DEFAULT_PATH = Path("config.yaml") - - -class Config(Singleton): - REQUIRED = [] - OPTIONAL = {} - - @classmethod - def from_yaml(cls, filepath: Union[Path, str] = DEFAULT_PATH) -> "Config": - """Load the yaml config file.""" - if inst := cls.__dict__.get("inst"): - return inst - - if isinstance(filepath, str): - filepath = Path(filepath) - - with filepath.open() as f: - raw = f.read() - - y = load(raw, Loader=Loader) - return cls(**y) - - @classmethod - def reload(cls) -> bool: - """Reload the config.""" - return cls.__dict__.pop("inst", None) is None +"""Load global config.""" +from pathlib import Path +from typing import Union + +from yaml import load + +from jarvis_core.util import Singleton + +try: + from yaml import CLoader as Loader +except ImportError: + from yaml import Loader + + +DEFAULT_PATH = Path("config.yaml") + + +class Config(Singleton): + REQUIRED = [] + OPTIONAL = {} + + @classmethod + def from_yaml(cls, filepath: Union[Path, str] = DEFAULT_PATH) -> "Config": + """Load the yaml config file.""" + if inst := cls.__dict__.get("inst"): + return inst + + if isinstance(filepath, str): + filepath = Path(filepath) + + with filepath.open() as f: + raw = f.read() + + y = load(raw, Loader=Loader) + return cls(**y) + + @classmethod + def reload(cls) -> bool: + """Reload the config.""" + return cls.__dict__.pop("inst", None) is None diff --git a/jarvis_core/db/__init__.py b/jarvis_core/db/__init__.py index 2eef157..9f4e4ae 100644 --- a/jarvis_core/db/__init__.py +++ b/jarvis_core/db/__init__.py @@ -1,86 +1,86 @@ -"""JARVIS database models and utilities.""" -from bson import ObjectId -from motor.motor_asyncio import AsyncIOMotorClient -from umongo.frameworks import MotorAsyncIOInstance - -from jarvis_core.util import find - -CLIENT = None -JARVISDB = None -CTC2DB = None -JARVIS_INST = MotorAsyncIOInstance() -CTC2_INST = MotorAsyncIOInstance() - - -def connect( - host: str, username: str, password: str, port: int = 27017, testing: bool = False -) -> None: - """ - Connect to MongoDB. - - Args: - host: Hostname/IP - username: Username - password: Password - port: Port - """ - global CLIENT, JARVISDB, CTC2DB, JARVIS_INST, CTC2_INST - CLIENT = AsyncIOMotorClient(host=host, username=username, password=password, port=port) - JARVISDB = CLIENT.narvis if testing else CLIENT.jarvis - CTC2DB = CLIENT.ctc2 - - JARVIS_INST.set_db(JARVISDB) - CTC2_INST.set_db(CTC2DB) - - -QUERY_OPS = ["ne", "lt", "lte", "gt", "gte", "not", "in", "nin", "mod", "all", "size"] -STRING_OPS = [ - "exact", - "iexact", - "contains", - "icontains", - "startswith", - "istartswith", - "endswith", - "iendswith", - "wholeword", - "iwholeword", - "regex", - "iregex" "match", -] -GEO_OPS = [ - "get_within", - "geo_within_box", - "geo_within_polygon", - "geo_within_center", - "geo_within_sphere", - "geo_intersects", - "near", - "within_distance", - "within_spherical_distance", - "near_sphere", - "within_box", - "within_polygon", - "max_distance", - "min_distance", -] - -ALL_OPS = QUERY_OPS + STRING_OPS + GEO_OPS - - -def q(**kwargs: dict) -> dict: - """uMongo query wrapper.""" # noqa: D403 - query = {} - for key, value in kwargs.items(): - if key == "_id": - value = ObjectId(value) - elif "__" in key: - args = key.split("__") - if not any(x in ALL_OPS for x in args): - key = ".".join(args) - else: - idx = args.index(find(lambda x: x in ALL_OPS, args)) - key = ".".join(args[:idx]) - value = {f"${args[idx]}": value} - query[key] = value - return query +"""JARVIS database models and utilities.""" +from bson import ObjectId +from motor.motor_asyncio import AsyncIOMotorClient +from umongo.frameworks import MotorAsyncIOInstance + +from jarvis_core.util import find + +CLIENT = None +JARVISDB = None +CTC2DB = None +JARVIS_INST = MotorAsyncIOInstance() +CTC2_INST = MotorAsyncIOInstance() + + +def connect( + host: str, username: str, password: str, port: int = 27017, testing: bool = False +) -> None: + """ + Connect to MongoDB. + + Args: + host: Hostname/IP + username: Username + password: Password + port: Port + """ + global CLIENT, JARVISDB, CTC2DB, JARVIS_INST, CTC2_INST + CLIENT = AsyncIOMotorClient(host=host, username=username, password=password, port=port) + JARVISDB = CLIENT.narvis if testing else CLIENT.jarvis + CTC2DB = CLIENT.ctc2 + + JARVIS_INST.set_db(JARVISDB) + CTC2_INST.set_db(CTC2DB) + + +QUERY_OPS = ["ne", "lt", "lte", "gt", "gte", "not", "in", "nin", "mod", "all", "size"] +STRING_OPS = [ + "exact", + "iexact", + "contains", + "icontains", + "startswith", + "istartswith", + "endswith", + "iendswith", + "wholeword", + "iwholeword", + "regex", + "iregex" "match", +] +GEO_OPS = [ + "get_within", + "geo_within_box", + "geo_within_polygon", + "geo_within_center", + "geo_within_sphere", + "geo_intersects", + "near", + "within_distance", + "within_spherical_distance", + "near_sphere", + "within_box", + "within_polygon", + "max_distance", + "min_distance", +] + +ALL_OPS = QUERY_OPS + STRING_OPS + GEO_OPS + + +def q(**kwargs: dict) -> dict: + """uMongo query wrapper.""" # noqa: D403 + query = {} + for key, value in kwargs.items(): + if key == "_id": + value = ObjectId(value) + elif "__" in key: + args = key.split("__") + if not any(x in ALL_OPS for x in args): + key = ".".join(args) + else: + idx = args.index(find(lambda x: x in ALL_OPS, args)) + key = ".".join(args[:idx]) + value = {f"${args[idx]}": value} + query[key] = value + return query diff --git a/jarvis_core/db/models/__init__.py b/jarvis_core/db/models/__init__.py index 260dd51..0826893 100644 --- a/jarvis_core/db/models/__init__.py +++ b/jarvis_core/db/models/__init__.py @@ -1,141 +1,141 @@ -"""JARVIS database models.""" -from datetime import datetime - -import marshmallow as ma -from umongo import Document, fields - -from jarvis_core.db import JARVIS_INST -from jarvis_core.db.models.actions import Ban, Kick, Mute, Unban, Warning -from jarvis_core.db.models.modlog import Action, Modlog, Note -from jarvis_core.db.models.twitter import TwitterAccount, TwitterFollow - - -class RawField(fields.BaseField, ma.fields.Raw): - pass - - -@JARVIS_INST.register -class Autopurge(Document): - guild = fields.IntegerField(required=True) - channel = fields.IntegerField(required=True) - delay = fields.IntegerField(default=30) - admin = fields.IntegerField(required=True) - created_at = fields.DateTimeField(default=datetime.now) - - -@JARVIS_INST.register -class Autoreact(Document): - guild = fields.IntegerField(required=True) - channel = fields.IntegerField(required=True) - reactions = fields.ListField(fields.StringField()) - admin = fields.IntegerField(required=True) - created_at = fields.DateTimeField(default=datetime.now) - - -@JARVIS_INST.register -class Config(Document): - """Config database object.""" - - key = fields.StringField(required=True) - value = RawField(required=True) - - -@JARVIS_INST.register -class Guess(Document): - """Guess database object.""" - - correct = fields.BooleanField(default=False) - guess = fields.StringField(required=True) - user = fields.IntegerField(required=True) - - -@JARVIS_INST.register -class Lock(Document): - """Lock database object.""" - - active = fields.BooleanField(default=True) - admin = fields.IntegerField(required=True) - channel = fields.IntegerField(required=True) - duration = fields.IntegerField(default=10) - guild = fields.IntegerField(required=True) - reason = fields.StringField(required=True) - created_at = fields.DateTimeField(default=datetime.utcnow) - - -@JARVIS_INST.register -class Purge(Document): - """Purge database object.""" - - admin = fields.IntegerField(required=True) - channel = fields.IntegerField(required=True) - guild = fields.IntegerField(required=True) - count = fields.IntegerField(default=10) - created_at = fields.DateTimeField(default=datetime.utcnow) - - -@JARVIS_INST.register -class Reminder(Document): - """Reminder database object.""" - - active = fields.BooleanField(default=True) - user = fields.IntegerField(required=True) - guild = fields.IntegerField(required=True) - channel = fields.IntegerField(required=True) - message = fields.StringField(required=True) - remind_at = fields.DateTimeField(required=True) - created_at = fields.DateTimeField(default=datetime.utcnow) - private = fields.BooleanField(default=False) - - -@JARVIS_INST.register -class Rolegiver(Document): - """Rolegiver database object.""" - - guild = fields.IntegerField(required=True) - roles = fields.ListField(fields.IntegerField()) - - -@JARVIS_INST.register -class Roleping(Document): - """Roleping database object.""" - - active = fields.BooleanField(default=True) - role = fields.IntegerField(required=True) - guild = fields.IntegerField(required=True) - admin = fields.IntegerField(required=True) - bypass = fields.DictField() - created_at = fields.DateTimeField(default=datetime.utcnow) - - -@JARVIS_INST.register -class Setting(Document): - """Setting database object.""" - - guild = fields.IntegerField(required=True) - setting = fields.StringField(required=True) - value = RawField() - - -@JARVIS_INST.register -class Star(Document): - """Star database object.""" - - active = fields.BooleanField(default=True) - index = fields.IntegerField(required=True) - message = fields.IntegerField(required=True) - channel = fields.IntegerField(required=True) - starboard = fields.IntegerField(required=True) - guild = fields.IntegerField(required=True) - admin = fields.IntegerField(required=True) - star = fields.IntegerField(required=True) - created_at = fields.DateTimeField(default=datetime.utcnow) - - -@JARVIS_INST.register -class Starboard(Document): - """Starboard database object.""" - - channel = fields.IntegerField(required=True) - guild = fields.IntegerField(required=True) - admin = fields.IntegerField(required=True) - created_at = fields.DateTimeField(default=datetime.utcnow) +"""JARVIS database models.""" +from datetime import datetime + +import marshmallow as ma +from umongo import Document, fields + +from jarvis_core.db import JARVIS_INST +from jarvis_core.db.models.actions import Ban, Kick, Mute, Unban, Warning +from jarvis_core.db.models.modlog import Action, Modlog, Note +from jarvis_core.db.models.twitter import TwitterAccount, TwitterFollow + + +class RawField(fields.BaseField, ma.fields.Raw): + pass + + +@JARVIS_INST.register +class Autopurge(Document): + guild = fields.IntegerField(required=True) + channel = fields.IntegerField(required=True) + delay = fields.IntegerField(default=30) + admin = fields.IntegerField(required=True) + created_at = fields.DateTimeField(default=datetime.now) + + +@JARVIS_INST.register +class Autoreact(Document): + guild = fields.IntegerField(required=True) + channel = fields.IntegerField(required=True) + reactions = fields.ListField(fields.StringField()) + admin = fields.IntegerField(required=True) + created_at = fields.DateTimeField(default=datetime.now) + + +@JARVIS_INST.register +class Config(Document): + """Config database object.""" + + key = fields.StringField(required=True) + value = RawField(required=True) + + +@JARVIS_INST.register +class Guess(Document): + """Guess database object.""" + + correct = fields.BooleanField(default=False) + guess = fields.StringField(required=True) + user = fields.IntegerField(required=True) + + +@JARVIS_INST.register +class Lock(Document): + """Lock database object.""" + + active = fields.BooleanField(default=True) + admin = fields.IntegerField(required=True) + channel = fields.IntegerField(required=True) + duration = fields.IntegerField(default=10) + guild = fields.IntegerField(required=True) + reason = fields.StringField(required=True) + created_at = fields.DateTimeField(default=datetime.utcnow) + + +@JARVIS_INST.register +class Purge(Document): + """Purge database object.""" + + admin = fields.IntegerField(required=True) + channel = fields.IntegerField(required=True) + guild = fields.IntegerField(required=True) + count = fields.IntegerField(default=10) + created_at = fields.DateTimeField(default=datetime.utcnow) + + +@JARVIS_INST.register +class Reminder(Document): + """Reminder database object.""" + + active = fields.BooleanField(default=True) + user = fields.IntegerField(required=True) + guild = fields.IntegerField(required=True) + channel = fields.IntegerField(required=True) + message = fields.StringField(required=True) + remind_at = fields.DateTimeField(required=True) + created_at = fields.DateTimeField(default=datetime.utcnow) + private = fields.BooleanField(default=False) + + +@JARVIS_INST.register +class Rolegiver(Document): + """Rolegiver database object.""" + + guild = fields.IntegerField(required=True) + roles = fields.ListField(fields.IntegerField()) + + +@JARVIS_INST.register +class Roleping(Document): + """Roleping database object.""" + + active = fields.BooleanField(default=True) + role = fields.IntegerField(required=True) + guild = fields.IntegerField(required=True) + admin = fields.IntegerField(required=True) + bypass = fields.DictField() + created_at = fields.DateTimeField(default=datetime.utcnow) + + +@JARVIS_INST.register +class Setting(Document): + """Setting database object.""" + + guild = fields.IntegerField(required=True) + setting = fields.StringField(required=True) + value = RawField() + + +@JARVIS_INST.register +class Star(Document): + """Star database object.""" + + active = fields.BooleanField(default=True) + index = fields.IntegerField(required=True) + message = fields.IntegerField(required=True) + channel = fields.IntegerField(required=True) + starboard = fields.IntegerField(required=True) + guild = fields.IntegerField(required=True) + admin = fields.IntegerField(required=True) + star = fields.IntegerField(required=True) + created_at = fields.DateTimeField(default=datetime.utcnow) + + +@JARVIS_INST.register +class Starboard(Document): + """Starboard database object.""" + + channel = fields.IntegerField(required=True) + guild = fields.IntegerField(required=True) + admin = fields.IntegerField(required=True) + created_at = fields.DateTimeField(default=datetime.utcnow) diff --git a/jarvis_core/db/models/actions.py b/jarvis_core/db/models/actions.py index f5aa351..89af740 100644 --- a/jarvis_core/db/models/actions.py +++ b/jarvis_core/db/models/actions.py @@ -1,70 +1,70 @@ -"""User action models.""" -from datetime import datetime - -from umongo import Document, fields - -from jarvis_core.db import JARVIS_INST - - -@JARVIS_INST.register -class Ban(Document): - active = fields.BooleanField(default=True) - admin = fields.IntegerField(required=True) - user = fields.IntegerField(required=True) - username = fields.StringField(required=True) - discrim = fields.IntegerField(required=True) - duration = fields.IntegerField(required=False) - guild = fields.IntegerField(required=True) - type = fields.StringField(default="perm") - reason = fields.StringField(required=True) - created_at = fields.DateTimeField(default=datetime.utcnow) - - -@JARVIS_INST.register -class Kick(Document): - """Kick database object.""" - - admin = fields.IntegerField(required=True) - guild = fields.IntegerField(required=True) - reason = fields.StringField(required=True) - user = fields.IntegerField(required=True) - created_at = fields.DateTimeField(default=datetime.utcnow) - - -@JARVIS_INST.register -class Mute(Document): - """Mute database object.""" - - active = fields.BooleanField(default=True) - user = fields.IntegerField(required=True) - admin = fields.IntegerField(required=True) - duration = fields.IntegerField(default=10) - guild = fields.IntegerField(required=True) - reason = fields.StringField(required=True) - created_at = fields.DateTimeField(default=datetime.utcnow) - - -@JARVIS_INST.register -class Unban(Document): - """Unban database object.""" - - user = fields.IntegerField(required=True) - username = fields.StringField(required=True) - discrim = fields.IntegerField(required=True) - guild = fields.IntegerField(required=True) - admin = fields.IntegerField(required=True) - reason = fields.StringField(required=True) - created_at = fields.DateTimeField(default=datetime.utcnow) - - -@JARVIS_INST.register -class Warning(Document): - """Warning database object.""" - - active = fields.BooleanField(default=True) - admin = fields.IntegerField(required=True) - user = fields.IntegerField(required=True) - guild = fields.IntegerField(required=True) - duration = fields.IntegerField(default=24) - reason = fields.StringField(required=True) - created_at = fields.DateTimeField(default=datetime.utcnow) +"""User action models.""" +from datetime import datetime + +from umongo import Document, fields + +from jarvis_core.db import JARVIS_INST + + +@JARVIS_INST.register +class Ban(Document): + active = fields.BooleanField(default=True) + admin = fields.IntegerField(required=True) + user = fields.IntegerField(required=True) + username = fields.StringField(required=True) + discrim = fields.IntegerField(required=True) + duration = fields.IntegerField(required=False) + guild = fields.IntegerField(required=True) + type = fields.StringField(default="perm") + reason = fields.StringField(required=True) + created_at = fields.DateTimeField(default=datetime.utcnow) + + +@JARVIS_INST.register +class Kick(Document): + """Kick database object.""" + + admin = fields.IntegerField(required=True) + guild = fields.IntegerField(required=True) + reason = fields.StringField(required=True) + user = fields.IntegerField(required=True) + created_at = fields.DateTimeField(default=datetime.utcnow) + + +@JARVIS_INST.register +class Mute(Document): + """Mute database object.""" + + active = fields.BooleanField(default=True) + user = fields.IntegerField(required=True) + admin = fields.IntegerField(required=True) + duration = fields.IntegerField(default=10) + guild = fields.IntegerField(required=True) + reason = fields.StringField(required=True) + created_at = fields.DateTimeField(default=datetime.utcnow) + + +@JARVIS_INST.register +class Unban(Document): + """Unban database object.""" + + user = fields.IntegerField(required=True) + username = fields.StringField(required=True) + discrim = fields.IntegerField(required=True) + guild = fields.IntegerField(required=True) + admin = fields.IntegerField(required=True) + reason = fields.StringField(required=True) + created_at = fields.DateTimeField(default=datetime.utcnow) + + +@JARVIS_INST.register +class Warning(Document): + """Warning database object.""" + + active = fields.BooleanField(default=True) + admin = fields.IntegerField(required=True) + user = fields.IntegerField(required=True) + guild = fields.IntegerField(required=True) + duration = fields.IntegerField(default=24) + reason = fields.StringField(required=True) + created_at = fields.DateTimeField(default=datetime.utcnow) diff --git a/jarvis_core/db/models/modlog.py b/jarvis_core/db/models/modlog.py index 1592a98..cde56d1 100644 --- a/jarvis_core/db/models/modlog.py +++ b/jarvis_core/db/models/modlog.py @@ -1,37 +1,37 @@ -"""Modlog database models.""" -from datetime import datetime -from typing import List - -from bson import ObjectId -from umongo import Document, EmbeddedDocument, fields - -from jarvis_core.db import JARVIS_INST - - -@JARVIS_INST.register -class Action(EmbeddedDocument): - """Modlog embedded action document.""" - - action_type: str = fields.StringField(required=True) - parent: ObjectId = fields.ObjectIdField(required=True) - - -@JARVIS_INST.register -class Note(EmbeddedDocument): - """Modlog embedded note document.""" - - admin: int = fields.IntegerField(required=True) - content: str = fields.StrField(required=True) - created_at: datetime = fields.DateTimeField(default=datetime.utcnow) - - -@JARVIS_INST.register -class Modlog(Document): - """Modlog database object.""" - - user: int = fields.IntegerField(required=True) - admin: int = fields.IntegerField(required=True) - actions: List[Action] = fields.ListField(fields.EmbeddedField(Action), factory=list) - open: bool = fields.BoolField(default=True) - created_at: datetime = fields.DateTimeField(default=datetime.utcnow) - notes: List[Note] = fields.ListField(fields.EmbeddedField(Note), factory=list) +"""Modlog database models.""" +from datetime import datetime +from typing import List + +from bson import ObjectId +from umongo import Document, EmbeddedDocument, fields + +from jarvis_core.db import JARVIS_INST + + +@JARVIS_INST.register +class Action(EmbeddedDocument): + """Modlog embedded action document.""" + + action_type: str = fields.StringField(required=True) + parent: ObjectId = fields.ObjectIdField(required=True) + + +@JARVIS_INST.register +class Note(EmbeddedDocument): + """Modlog embedded note document.""" + + admin: int = fields.IntegerField(required=True) + content: str = fields.StrField(required=True) + created_at: datetime = fields.DateTimeField(default=datetime.utcnow) + + +@JARVIS_INST.register +class Modlog(Document): + """Modlog database object.""" + + user: int = fields.IntegerField(required=True) + admin: int = fields.IntegerField(required=True) + actions: List[Action] = fields.ListField(fields.EmbeddedField(Action), factory=list) + open: bool = fields.BoolField(default=True) + created_at: datetime = fields.DateTimeField(default=datetime.utcnow) + notes: List[Note] = fields.ListField(fields.EmbeddedField(Note), factory=list) diff --git a/jarvis_core/db/models/twitter.py b/jarvis_core/db/models/twitter.py index 68958b6..4782950 100644 --- a/jarvis_core/db/models/twitter.py +++ b/jarvis_core/db/models/twitter.py @@ -1,35 +1,35 @@ -"""Twitter database models.""" -from datetime import datetime - -from umongo import Document, fields - -from jarvis_core.db import JARVIS_INST - - -@JARVIS_INST.register -class TwitterAccount(Document): - """Twitter Account object.""" - - handle = fields.StringField(required=True) - twitter_id = fields.IntegerField(required=True) - last_tweet = fields.IntegerField(required=True) - last_sync = fields.DateTimeField(default=datetime.utcnow) - - class Meta: - collection_name = "twitteraccount" - - -@JARVIS_INST.register -class TwitterFollow(Document): - """Twitter Follow object.""" - - active = fields.BooleanField(default=True) - twitter_id = fields.IntegerField(required=True) - channel = fields.IntegerField(required=True) - guild = fields.IntegerField(required=True) - retweets = fields.BooleanField(default=True) - admin = fields.IntegerField(required=True) - created_at = fields.DateTimeField(default=datetime.utcnow) - - class Meta: - collection_name = "twitterfollow" +"""Twitter database models.""" +from datetime import datetime + +from umongo import Document, fields + +from jarvis_core.db import JARVIS_INST + + +@JARVIS_INST.register +class TwitterAccount(Document): + """Twitter Account object.""" + + handle = fields.StringField(required=True) + twitter_id = fields.IntegerField(required=True) + last_tweet = fields.IntegerField(required=True) + last_sync = fields.DateTimeField(default=datetime.utcnow) + + class Meta: + collection_name = "twitteraccount" + + +@JARVIS_INST.register +class TwitterFollow(Document): + """Twitter Follow object.""" + + active = fields.BooleanField(default=True) + twitter_id = fields.IntegerField(required=True) + channel = fields.IntegerField(required=True) + guild = fields.IntegerField(required=True) + retweets = fields.BooleanField(default=True) + admin = fields.IntegerField(required=True) + created_at = fields.DateTimeField(default=datetime.utcnow) + + class Meta: + collection_name = "twitterfollow" diff --git a/jarvis_core/filters.py b/jarvis_core/filters.py index e57c2c1..0da0546 100644 --- a/jarvis_core/filters.py +++ b/jarvis_core/filters.py @@ -1,37 +1,37 @@ -"""Regex filters for various content types.""" -import re - -invites = re.compile( - r"(?:discord.?(?:gg|io|me|li)|discord(?:app)?.?com/(?:invite))/([^\s/]+?)(?=\b)", - flags=re.IGNORECASE, -) - -custom_emote = re.compile(r"<:\w+:(\d+)>$", flags=re.IGNORECASE) - -valid_text = re.compile(r"[\w\s\-\\/.!@#$%^*()+=<>,\u0080-\U000E0FFF]*", flags=re.IGNORECASE) - -url = re.compile( - r"https?:\/\/(www\.)?[-a-z0-9@:%._\+~#=]{1,256}\.[a-z0-9()]{1,6}\b([-a-z0-9()@:%_\+.~#?&//=]*)", - flags=re.IGNORECASE, -) - -email = re.compile( - r"(?:[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*|\"" - r"(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21\x23-\x5b\x5d-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])*\"" - r")@(?:(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?|\[(?:(?:25[0-5]|2[0-4][0-9]|[01]?" - r"[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?|[a-z0-9-]*[a-z0-9]:" - r"(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21-\x5a\x53-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])+)\])" -) - -ipv4 = re.compile(r"((25[0-5]|(2[0-4]|1\d|[1-9]|)\d)(\.(?!$)|$)){4}") -ipv6 = re.compile( - r"(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:" - r"|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|" - r"([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}" - r"|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|" - r":((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}" - r"((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|" - r"([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}" - r"(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))", - re.IGNORECASE, -) +"""Regex filters for various content types.""" +import re + +invites = re.compile( + r"(?:discord.?(?:gg|io|me|li)|discord(?:app)?.?com/(?:invite))/([^\s/]+?)(?=\b)", + flags=re.IGNORECASE, +) + +custom_emote = re.compile(r"<:\w+:(\d+)>$", flags=re.IGNORECASE) + +valid_text = re.compile(r"[\w\s\-\\/.!@#$%^*()+=<>,\u0080-\U000E0FFF]*", flags=re.IGNORECASE) + +url = re.compile( + r"https?:\/\/(www\.)?[-a-z0-9@:%._\+~#=]{1,256}\.[a-z0-9()]{1,6}\b([-a-z0-9()@:%_\+.~#?&//=]*)", + flags=re.IGNORECASE, +) + +email = re.compile( + r"(?:[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*|\"" + r"(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21\x23-\x5b\x5d-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])*\"" + r")@(?:(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?|\[(?:(?:25[0-5]|2[0-4][0-9]|[01]?" + r"[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?|[a-z0-9-]*[a-z0-9]:" + r"(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21-\x5a\x53-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])+)\])" +) + +ipv4 = re.compile(r"((25[0-5]|(2[0-4]|1\d|[1-9]|)\d)(\.(?!$)|$)){4}") +ipv6 = re.compile( + r"(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:" + r"|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|" + r"([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}" + r"|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|" + r":((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}" + r"((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|" + r"([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}" + r"(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))", + re.IGNORECASE, +) diff --git a/jarvis_core/log.py b/jarvis_core/log.py index 84e7528..b3b5862 100644 --- a/jarvis_core/log.py +++ b/jarvis_core/log.py @@ -1,21 +1,21 @@ -"""JARVIS logging helper.""" -import logging -from typing import Optional - -FORMAT = "[%(asctime)s] [%(name)s] [%(levelname)8s] %(message)s" - -handler = logging.StreamHandler() - - -def get_logger(name: str, fmt: Optional[str] = FORMAT) -> logging.Logger: - """ - Get a pre-configured logger - - Args: - name: Name of the logger - """ - logger = logging.getLogger(name) - formatter = logging.Formatter(fmt) - handler.setFormatter(formatter) - logger.addHandler(handler) - return logger +"""JARVIS logging helper.""" +import logging +from typing import Optional + +FORMAT = "[%(asctime)s] [%(name)s] [%(levelname)8s] %(message)s" + +handler = logging.StreamHandler() + + +def get_logger(name: str, fmt: Optional[str] = FORMAT) -> logging.Logger: + """ + Get a pre-configured logger + + Args: + name: Name of the logger + """ + logger = logging.getLogger(name) + formatter = logging.Formatter(fmt) + handler.setFormatter(formatter) + logger.addHandler(handler) + return logger diff --git a/jarvis_core/util/ansi.py b/jarvis_core/util/ansi.py index 7602b2a..aaf484c 100644 --- a/jarvis_core/util/ansi.py +++ b/jarvis_core/util/ansi.py @@ -1,75 +1,75 @@ -"""ANSI color helper.""" -from enum import Enum, EnumMeta -from typing import Any, List - -ESCAPE = "\u001b" -RESET = ESCAPE + "[0m" - - -class SearchableEnum(EnumMeta): - def __contains__(cls, item: Any): - return item in [v.value for v in cls.__members__.values()] - - -class Format(Enum, metaclass=SearchableEnum): - NORMAL = 0 - BOLD = 1 - UNDERLINE = 4 - - -class Fore(Enum, metaclass=SearchableEnum): - GRAY = 30 - RED = 31 - GREEN = 32 - YELLOW = 33 - BLUE = 34 - PINK = 35 - CYAN = 36 - WHITE = 37 - - -class Back(Enum, metaclass=SearchableEnum): - DARK_BLUE = 40 - ORANGE = 41 - DARK_GRAY = 42 - GRAY = 43 - LIGHT_GRAY = 44 - INDIGO = 45 - LIGHTER_GRAY = 46 - WHITE = 47 - - -def fmt(*formats: List[Format | Fore | Back] | int) -> str: - """ - Get format string. - - Args: - formats: List of format modifiers - - Return: - Format string - """ - fore = "" - back = "" - fmt = "" - block_fmt = False - for f in formats: - if isinstance(f, Enum): - f = f.value - if f == 0: - fmt = "0;" - elif f in [1, 4]: - if str(f) not in fmt and not block_fmt: - fmt += f"{f};" - elif 30 <= f <= 37: - fore = f"{f};" - elif 40 <= f <= 47: - back = f"{f};" - - ret = fmt + fore + back - if not any([ret, fore, back]): - ret = RESET - if ret[-1] == ";": - ret = ret[:-1] - - return ESCAPE + "[" + ret + "m" +"""ANSI color helper.""" +from enum import Enum, EnumMeta +from typing import Any, List + +ESCAPE = "\u001b" +RESET = ESCAPE + "[0m" + + +class SearchableEnum(EnumMeta): + def __contains__(cls, item: Any): + return item in [v.value for v in cls.__members__.values()] + + +class Format(Enum, metaclass=SearchableEnum): + NORMAL = 0 + BOLD = 1 + UNDERLINE = 4 + + +class Fore(Enum, metaclass=SearchableEnum): + GRAY = 30 + RED = 31 + GREEN = 32 + YELLOW = 33 + BLUE = 34 + PINK = 35 + CYAN = 36 + WHITE = 37 + + +class Back(Enum, metaclass=SearchableEnum): + DARK_BLUE = 40 + ORANGE = 41 + DARK_GRAY = 42 + GRAY = 43 + LIGHT_GRAY = 44 + INDIGO = 45 + LIGHTER_GRAY = 46 + WHITE = 47 + + +def fmt(*formats: List[Format | Fore | Back] | int) -> str: + """ + Get format string. + + Args: + formats: List of format modifiers + + Return: + Format string + """ + fore = "" + back = "" + fmt = "" + block_fmt = False + for f in formats: + if isinstance(f, Enum): + f = f.value + if f == 0: + fmt = "0;" + elif f in [1, 4]: + if str(f) not in fmt and not block_fmt: + fmt += f"{f};" + elif 30 <= f <= 37: + fore = f"{f};" + elif 40 <= f <= 47: + back = f"{f};" + + ret = fmt + fore + back + if not any([ret, fore, back]): + ret = RESET + if ret[-1] == ";": + ret = ret[:-1] + + return ESCAPE + "[" + ret + "m" diff --git a/jarvis_core/util/http.py b/jarvis_core/util/http.py index 2a798b7..d127c8f 100644 --- a/jarvis_core/util/http.py +++ b/jarvis_core/util/http.py @@ -1,27 +1,27 @@ -"""HTTP helper methods.""" -from aiohttp import ClientSession - -from jarvis_core.filters import url - - -async def get_size(link: str) -> int: - """ - Get the url filesize. - - Args: - link: URL to get - - Returns: - Size in bytes - - Raises: - Exception: On status code - ValueError: On bad URL - """ - if not url.match(link): - raise ValueError("Invalid URL.") - - async with ClientSession() as session: - resp = await session.get(link) - resp.raise_for_status() - return resp.content_length or -1 +"""HTTP helper methods.""" +from aiohttp import ClientSession + +from jarvis_core.filters import url + + +async def get_size(link: str) -> int: + """ + Get the url filesize. + + Args: + link: URL to get + + Returns: + Size in bytes + + Raises: + Exception: On status code + ValueError: On bad URL + """ + if not url.match(link): + raise ValueError("Invalid URL.") + + async with ClientSession() as session: + resp = await session.get(link) + resp.raise_for_status() + return resp.content_length or -1 diff --git a/poetry.lock b/poetry.lock index 38435bb..33fffa1 100644 --- a/poetry.lock +++ b/poetry.lock @@ -31,15 +31,16 @@ frozenlist = ">=1.1.0" [[package]] name = "astroid" -version = "2.9.3" +version = "2.4.2" description = "An abstract syntax tree for Python with inference support." category = "dev" optional = false -python-versions = ">=3.6.2" +python-versions = ">=3.5" [package.dependencies] -lazy-object-proxy = ">=1.4.0" -wrapt = ">=1.11,<1.14" +lazy-object-proxy = ">=1.4.0,<1.5.0" +six = ">=1.12,<2.0" +wrapt = ">=1.11,<2.0" [[package]] name = "async-timeout" @@ -104,7 +105,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" [[package]] name = "dis-snek" -version = "6.0.0" +version = "7.0.0" description = "An API wrapper for Discord filled with snakes" category = "main" optional = false @@ -113,8 +114,20 @@ python-versions = ">=3.10" [package.dependencies] aiohttp = "*" attrs = "*" +discord-typings = "*" tomli = "*" +[[package]] +name = "discord-typings" +version = "0.3.1" +description = "Maintained typings of payloads that Discord sends" +category = "main" +optional = false +python-versions = ">=3.7" + +[package.dependencies] +typing_extensions = ">=4,<5" + [[package]] name = "flake8" version = "4.0.1" @@ -175,11 +188,11 @@ testing = ["Django (<3.1)", "colorama", "docopt", "pytest (<7.0.0)"] [[package]] name = "lazy-object-proxy" -version = "1.7.1" +version = "1.4.3" description = "A fast and thorough lazy object proxy." category = "dev" optional = false -python-versions = ">=3.6" +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "marshmallow" @@ -264,18 +277,6 @@ python-versions = ">=3.6" qa = ["flake8 (==3.8.3)", "mypy (==0.782)"] testing = ["docopt", "pytest (<6.0.0)"] -[[package]] -name = "platformdirs" -version = "2.5.1" -description = "A small Python module for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["Sphinx (>=4)", "furo (>=2021.7.5b38)", "proselint (>=0.10.2)", "sphinx-autodoc-typehints (>=1.12)"] -test = ["appdirs (==1.4.4)", "pytest (>=6)", "pytest-cov (>=2.7)", "pytest-mock (>=3.6)"] - [[package]] name = "pluggy" version = "0.13.1" @@ -327,19 +328,18 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "pylint" -version = "2.12.2" +version = "2.6.2" description = "python code static checker" category = "dev" optional = false -python-versions = ">=3.6.2" +python-versions = ">=3.5.*" [package.dependencies] -astroid = ">=2.9.0,<2.10" +astroid = ">=2.4.0,<2.5" colorama = {version = "*", markers = "sys_platform == \"win32\""} isort = ">=4.2.5,<6" mccabe = ">=0.6,<0.7" -platformdirs = ">=2.2.0" -toml = ">=0.9.2" +toml = ">=0.7.1" [[package]] name = "pymongo" @@ -452,7 +452,7 @@ python-versions = ">=3.6" [[package]] name = "rope" -version = "0.22.0" +version = "0.23.0" description = "a python refactoring library..." category = "dev" optional = false @@ -461,6 +461,14 @@ python-versions = "*" [package.extras] dev = ["build", "pytest", "pytest-timeout"] +[[package]] +name = "six" +version = "1.16.0" +description = "Python 2 and 3 compatibility utilities" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" + [[package]] name = "snowballstemmer" version = "2.2.0" @@ -485,6 +493,14 @@ category = "main" optional = false python-versions = ">=3.7" +[[package]] +name = "typing-extensions" +version = "4.1.1" +description = "Backported and Experimental Type Hints for Python 3.6+" +category = "main" +optional = false +python-versions = ">=3.6" + [[package]] name = "ujson" version = "5.1.0" @@ -520,9 +536,9 @@ python-versions = "*" [[package]] name = "wrapt" -version = "1.13.3" +version = "1.14.0" description = "Module for decorators, wrappers and monkey patching." -category = "dev" +category = "main" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" @@ -549,7 +565,7 @@ multidict = ">=4.0" [metadata] lock-version = "1.1" python-versions = "^3.10" -content-hash = "8edf07b473e9615a836f71510d792021c6760ef94abe4b720f9ff12a37c5dce5" +content-hash = "a07e2ba142cae04f133b170017335e96cb4076f0eff2ccbf6a37e080f865505d" [metadata.files] aiohttp = [ @@ -631,8 +647,8 @@ aiosignal = [ {file = "aiosignal-1.2.0.tar.gz", hash = "sha256:78ed67db6c7b7ced4f98e495e572106d5c432a93e1ddd1bf475e1dc05f5b7df2"}, ] astroid = [ - {file = "astroid-2.9.3-py3-none-any.whl", hash = "sha256:506daabe5edffb7e696ad82483ad0228245a9742ed7d2d8c9cdb31537decf9f6"}, - {file = "astroid-2.9.3.tar.gz", hash = "sha256:1efdf4e867d4d8ba4a9f6cf9ce07cd182c4c41de77f23814feb27ca93ca9d877"}, + {file = "astroid-2.4.2-py3-none-any.whl", hash = "sha256:bc58d83eb610252fd8de6363e39d4f1d0619c894b0ed24603b881c02e64c7386"}, + {file = "astroid-2.4.2.tar.gz", hash = "sha256:2f4078c2a41bf377eea06d71c9d2ba4eb8f6b1af2135bec27bbbb7d8f12bb703"}, ] async-timeout = [ {file = "async-timeout-4.0.2.tar.gz", hash = "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15"}, @@ -659,8 +675,12 @@ colorama = [ {file = "colorama-0.4.4.tar.gz", hash = "sha256:5941b2b48a20143d2267e95b1c2a7603ce057ee39fd88e7329b0c292aa16869b"}, ] dis-snek = [ - {file = "dis-snek-6.0.0.tar.gz", hash = "sha256:3abe2af832bd87adced01ebc697e418b25871a4158ac8ba2e202d8fbb2921f44"}, - {file = "dis_snek-6.0.0-py3-none-any.whl", hash = "sha256:106cb08b0cc982c59db31be01ee529e4d7273835de7f418562d8e6b24d7f965d"}, + {file = "dis-snek-7.0.0.tar.gz", hash = "sha256:c39d0ff5e1f0cde3a0feefcd05f4a7d6de1d6b1aafbda745bbaa7a63d541af0f"}, + {file = "dis_snek-7.0.0-py3-none-any.whl", hash = "sha256:5a1fa72d3d5de96a7550a480d33a4f4a6ac8509391fa20890c2eb495fb45d221"}, +] +discord-typings = [ + {file = "discord-typings-0.3.1.tar.gz", hash = "sha256:854cfb66d34edad49b36d8aaffc93179bb397a97c81caba2da02896e72821a74"}, + {file = "discord_typings-0.3.1-py3-none-any.whl", hash = "sha256:65890c467751daa025dcef15683c32160f07427baf83380cfdf11d84ceec980a"}, ] flake8 = [ {file = "flake8-4.0.1-py2.py3-none-any.whl", hash = "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d"}, @@ -740,43 +760,27 @@ jedi = [ {file = "jedi-0.18.1.tar.gz", hash = "sha256:74137626a64a99c8eb6ae5832d99b3bdd7d29a3850fe2aa80a4126b2a7d949ab"}, ] lazy-object-proxy = [ - {file = "lazy-object-proxy-1.7.1.tar.gz", hash = "sha256:d609c75b986def706743cdebe5e47553f4a5a1da9c5ff66d76013ef396b5a8a4"}, - {file = "lazy_object_proxy-1.7.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:bb8c5fd1684d60a9902c60ebe276da1f2281a318ca16c1d0a96db28f62e9166b"}, - {file = "lazy_object_proxy-1.7.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a57d51ed2997e97f3b8e3500c984db50a554bb5db56c50b5dab1b41339b37e36"}, - {file = "lazy_object_proxy-1.7.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:fd45683c3caddf83abbb1249b653a266e7069a09f486daa8863fb0e7496a9fdb"}, - {file = "lazy_object_proxy-1.7.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:8561da8b3dd22d696244d6d0d5330618c993a215070f473b699e00cf1f3f6443"}, - {file = "lazy_object_proxy-1.7.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:fccdf7c2c5821a8cbd0a9440a456f5050492f2270bd54e94360cac663398739b"}, - {file = "lazy_object_proxy-1.7.1-cp310-cp310-win32.whl", hash = "sha256:898322f8d078f2654d275124a8dd19b079080ae977033b713f677afcfc88e2b9"}, - {file = "lazy_object_proxy-1.7.1-cp310-cp310-win_amd64.whl", hash = "sha256:85b232e791f2229a4f55840ed54706110c80c0a210d076eee093f2b2e33e1bfd"}, - {file = "lazy_object_proxy-1.7.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:46ff647e76f106bb444b4533bb4153c7370cdf52efc62ccfc1a28bdb3cc95442"}, - {file = "lazy_object_proxy-1.7.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:12f3bb77efe1367b2515f8cb4790a11cffae889148ad33adad07b9b55e0ab22c"}, - {file = "lazy_object_proxy-1.7.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:c19814163728941bb871240d45c4c30d33b8a2e85972c44d4e63dd7107faba44"}, - {file = "lazy_object_proxy-1.7.1-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:e40f2013d96d30217a51eeb1db28c9ac41e9d0ee915ef9d00da639c5b63f01a1"}, - {file = "lazy_object_proxy-1.7.1-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:2052837718516a94940867e16b1bb10edb069ab475c3ad84fd1e1a6dd2c0fcfc"}, - {file = "lazy_object_proxy-1.7.1-cp36-cp36m-win32.whl", hash = "sha256:6a24357267aa976abab660b1d47a34aaf07259a0c3859a34e536f1ee6e76b5bb"}, - {file = "lazy_object_proxy-1.7.1-cp36-cp36m-win_amd64.whl", hash = "sha256:6aff3fe5de0831867092e017cf67e2750c6a1c7d88d84d2481bd84a2e019ec35"}, - {file = "lazy_object_proxy-1.7.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:6a6e94c7b02641d1311228a102607ecd576f70734dc3d5e22610111aeacba8a0"}, - {file = "lazy_object_proxy-1.7.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c4ce15276a1a14549d7e81c243b887293904ad2d94ad767f42df91e75fd7b5b6"}, - {file = "lazy_object_proxy-1.7.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e368b7f7eac182a59ff1f81d5f3802161932a41dc1b1cc45c1f757dc876b5d2c"}, - {file = "lazy_object_proxy-1.7.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:6ecbb350991d6434e1388bee761ece3260e5228952b1f0c46ffc800eb313ff42"}, - {file = "lazy_object_proxy-1.7.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:553b0f0d8dbf21890dd66edd771f9b1b5f51bd912fa5f26de4449bfc5af5e029"}, - {file = "lazy_object_proxy-1.7.1-cp37-cp37m-win32.whl", hash = "sha256:c7a683c37a8a24f6428c28c561c80d5f4fd316ddcf0c7cab999b15ab3f5c5c69"}, - {file = "lazy_object_proxy-1.7.1-cp37-cp37m-win_amd64.whl", hash = "sha256:df2631f9d67259dc9620d831384ed7732a198eb434eadf69aea95ad18c587a28"}, - {file = "lazy_object_proxy-1.7.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:07fa44286cda977bd4803b656ffc1c9b7e3bc7dff7d34263446aec8f8c96f88a"}, - {file = "lazy_object_proxy-1.7.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:4dca6244e4121c74cc20542c2ca39e5c4a5027c81d112bfb893cf0790f96f57e"}, - {file = "lazy_object_proxy-1.7.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:91ba172fc5b03978764d1df5144b4ba4ab13290d7bab7a50f12d8117f8630c38"}, - {file = "lazy_object_proxy-1.7.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:043651b6cb706eee4f91854da4a089816a6606c1428fd391573ef8cb642ae4f7"}, - {file = "lazy_object_proxy-1.7.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:b9e89b87c707dd769c4ea91f7a31538888aad05c116a59820f28d59b3ebfe25a"}, - {file = "lazy_object_proxy-1.7.1-cp38-cp38-win32.whl", hash = "sha256:9d166602b525bf54ac994cf833c385bfcc341b364e3ee71e3bf5a1336e677b55"}, - {file = "lazy_object_proxy-1.7.1-cp38-cp38-win_amd64.whl", hash = "sha256:8f3953eb575b45480db6568306893f0bd9d8dfeeebd46812aa09ca9579595148"}, - {file = "lazy_object_proxy-1.7.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:dd7ed7429dbb6c494aa9bc4e09d94b778a3579be699f9d67da7e6804c422d3de"}, - {file = "lazy_object_proxy-1.7.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:70ed0c2b380eb6248abdef3cd425fc52f0abd92d2b07ce26359fcbc399f636ad"}, - {file = "lazy_object_proxy-1.7.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7096a5e0c1115ec82641afbdd70451a144558ea5cf564a896294e346eb611be1"}, - {file = "lazy_object_proxy-1.7.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:f769457a639403073968d118bc70110e7dce294688009f5c24ab78800ae56dc8"}, - {file = "lazy_object_proxy-1.7.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:39b0e26725c5023757fc1ab2a89ef9d7ab23b84f9251e28f9cc114d5b59c1b09"}, - {file = "lazy_object_proxy-1.7.1-cp39-cp39-win32.whl", hash = "sha256:2130db8ed69a48a3440103d4a520b89d8a9405f1b06e2cc81640509e8bf6548f"}, - {file = "lazy_object_proxy-1.7.1-cp39-cp39-win_amd64.whl", hash = "sha256:677ea950bef409b47e51e733283544ac3d660b709cfce7b187f5ace137960d61"}, - {file = "lazy_object_proxy-1.7.1-pp37.pp38-none-any.whl", hash = "sha256:d66906d5785da8e0be7360912e99c9188b70f52c422f9fc18223347235691a84"}, + {file = "lazy-object-proxy-1.4.3.tar.gz", hash = "sha256:f3900e8a5de27447acbf900b4750b0ddfd7ec1ea7fbaf11dfa911141bc522af0"}, + {file = "lazy_object_proxy-1.4.3-cp27-cp27m-macosx_10_13_x86_64.whl", hash = "sha256:a2238e9d1bb71a56cd710611a1614d1194dc10a175c1e08d75e1a7bcc250d442"}, + {file = "lazy_object_proxy-1.4.3-cp27-cp27m-win32.whl", hash = "sha256:efa1909120ce98bbb3777e8b6f92237f5d5c8ea6758efea36a473e1d38f7d3e4"}, + {file = "lazy_object_proxy-1.4.3-cp27-cp27m-win_amd64.whl", hash = "sha256:4677f594e474c91da97f489fea5b7daa17b5517190899cf213697e48d3902f5a"}, + {file = "lazy_object_proxy-1.4.3-cp27-cp27mu-manylinux1_x86_64.whl", hash = "sha256:0c4b206227a8097f05c4dbdd323c50edf81f15db3b8dc064d08c62d37e1a504d"}, + {file = "lazy_object_proxy-1.4.3-cp34-cp34m-manylinux1_x86_64.whl", hash = "sha256:d945239a5639b3ff35b70a88c5f2f491913eb94871780ebfabb2568bd58afc5a"}, + {file = "lazy_object_proxy-1.4.3-cp34-cp34m-win32.whl", hash = "sha256:9651375199045a358eb6741df3e02a651e0330be090b3bc79f6d0de31a80ec3e"}, + {file = "lazy_object_proxy-1.4.3-cp34-cp34m-win_amd64.whl", hash = "sha256:eba7011090323c1dadf18b3b689845fd96a61ba0a1dfbd7f24b921398affc357"}, + {file = "lazy_object_proxy-1.4.3-cp35-cp35m-manylinux1_x86_64.whl", hash = "sha256:48dab84ebd4831077b150572aec802f303117c8cc5c871e182447281ebf3ac50"}, + {file = "lazy_object_proxy-1.4.3-cp35-cp35m-win32.whl", hash = "sha256:ca0a928a3ddbc5725be2dd1cf895ec0a254798915fb3a36af0964a0a4149e3db"}, + {file = "lazy_object_proxy-1.4.3-cp35-cp35m-win_amd64.whl", hash = "sha256:194d092e6f246b906e8f70884e620e459fc54db3259e60cf69a4d66c3fda3449"}, + {file = "lazy_object_proxy-1.4.3-cp36-cp36m-manylinux1_x86_64.whl", hash = "sha256:97bb5884f6f1cdce0099f86b907aa41c970c3c672ac8b9c8352789e103cf3156"}, + {file = "lazy_object_proxy-1.4.3-cp36-cp36m-win32.whl", hash = "sha256:cb2c7c57005a6804ab66f106ceb8482da55f5314b7fcb06551db1edae4ad1531"}, + {file = "lazy_object_proxy-1.4.3-cp36-cp36m-win_amd64.whl", hash = "sha256:8d859b89baf8ef7f8bc6b00aa20316483d67f0b1cbf422f5b4dc56701c8f2ffb"}, + {file = "lazy_object_proxy-1.4.3-cp37-cp37m-macosx_10_13_x86_64.whl", hash = "sha256:1be7e4c9f96948003609aa6c974ae59830a6baecc5376c25c92d7d697e684c08"}, + {file = "lazy_object_proxy-1.4.3-cp37-cp37m-manylinux1_x86_64.whl", hash = "sha256:d74bb8693bf9cf75ac3b47a54d716bbb1a92648d5f781fc799347cfc95952383"}, + {file = "lazy_object_proxy-1.4.3-cp37-cp37m-win32.whl", hash = "sha256:9b15f3f4c0f35727d3a0fba4b770b3c4ebbb1fa907dbcc046a1d2799f3edd142"}, + {file = "lazy_object_proxy-1.4.3-cp37-cp37m-win_amd64.whl", hash = "sha256:9254f4358b9b541e3441b007a0ea0764b9d056afdeafc1a5569eee1cc6c1b9ea"}, + {file = "lazy_object_proxy-1.4.3-cp38-cp38-manylinux1_x86_64.whl", hash = "sha256:a6ae12d08c0bf9909ce12385803a543bfe99b95fe01e752536a60af2b7797c62"}, + {file = "lazy_object_proxy-1.4.3-cp38-cp38-win32.whl", hash = "sha256:5541cada25cd173702dbd99f8e22434105456314462326f06dba3e180f203dfd"}, + {file = "lazy_object_proxy-1.4.3-cp38-cp38-win_amd64.whl", hash = "sha256:59f79fef100b09564bc2df42ea2d8d21a64fdcda64979c0fa3db7bdaabaf6239"}, ] marshmallow = [ {file = "marshmallow-3.14.1-py3-none-any.whl", hash = "sha256:04438610bc6dadbdddb22a4a55bcc7f6f8099e69580b2e67f5a681933a1f4400"}, @@ -897,10 +901,6 @@ parso = [ {file = "parso-0.8.3-py2.py3-none-any.whl", hash = "sha256:c001d4636cd3aecdaf33cbb40aebb59b094be2a74c556778ef5576c175e19e75"}, {file = "parso-0.8.3.tar.gz", hash = "sha256:8c07be290bb59f03588915921e29e8a50002acaf2cdc5fa0e0114f91709fafa0"}, ] -platformdirs = [ - {file = "platformdirs-2.5.1-py3-none-any.whl", hash = "sha256:bcae7cab893c2d310a711b70b24efb93334febe65f8de776ee320b517471e227"}, - {file = "platformdirs-2.5.1.tar.gz", hash = "sha256:7535e70dfa32e84d4b34996ea99c5e432fa29a708d0f4e394bbcb2a8faa4f16d"}, -] pluggy = [ {file = "pluggy-0.13.1-py2.py3-none-any.whl", hash = "sha256:966c145cd83c96502c3c3868f50408687b38434af77734af1e9ca461a4081d2d"}, {file = "pluggy-0.13.1.tar.gz", hash = "sha256:15b2acde666561e1298d71b523007ed7364de07029219b604cf808bfa1c765b0"}, @@ -922,8 +922,8 @@ pyflakes = [ {file = "pyflakes-2.4.0.tar.gz", hash = "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c"}, ] pylint = [ - {file = "pylint-2.12.2-py3-none-any.whl", hash = "sha256:daabda3f7ed9d1c60f52d563b1b854632fd90035bcf01443e234d3dc794e3b74"}, - {file = "pylint-2.12.2.tar.gz", hash = "sha256:9d945a73640e1fec07ee34b42f5669b770c759acd536ec7b16d7e4b87a9c9ff9"}, + {file = "pylint-2.6.2-py3-none-any.whl", hash = "sha256:e71c2e9614a4f06e36498f310027942b0f4f2fde20aebb01655b31edc63b9eaf"}, + {file = "pylint-2.6.2.tar.gz", hash = "sha256:718b74786ea7ed07aa0c58bf572154d4679f960d26e9641cc1de204a30b87fc9"}, ] pymongo = [ {file = "pymongo-3.12.3-cp27-cp27m-macosx_10_14_intel.whl", hash = "sha256:c164eda0be9048f83c24b9b2656900041e069ddf72de81c17d874d0c32f6079f"}, @@ -1086,8 +1086,12 @@ pyyaml = [ {file = "PyYAML-6.0.tar.gz", hash = "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2"}, ] rope = [ - {file = "rope-0.22.0-py3-none-any.whl", hash = "sha256:2847220bf72ead09b5abe72b1edc9cacff90ab93663ece06913fc97324167870"}, - {file = "rope-0.22.0.tar.gz", hash = "sha256:b00fbc064a26fc62d7220578a27fd639b2fad57213663cc396c137e92d73f10f"}, + {file = "rope-0.23.0-py3-none-any.whl", hash = "sha256:edf2ed3c9b35a8814752ffd3ea55b293c791e5087e252461de898e953cf9c146"}, + {file = "rope-0.23.0.tar.gz", hash = "sha256:f87662c565086d660fc855cc07f37820267876634c3e9e51bddb32ff51547268"}, +] +six = [ + {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, + {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, ] snowballstemmer = [ {file = "snowballstemmer-2.2.0-py2.py3-none-any.whl", hash = "sha256:c8e1716e83cc398ae16824e5572ae04e0d9fc2c6b985fb0f900f5f0c96ecba1a"}, @@ -1101,6 +1105,10 @@ tomli = [ {file = "tomli-2.0.1-py3-none-any.whl", hash = "sha256:939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc"}, {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, ] +typing-extensions = [ + {file = "typing_extensions-4.1.1-py3-none-any.whl", hash = "sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2"}, + {file = "typing_extensions-4.1.1.tar.gz", hash = "sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42"}, +] ujson = [ {file = "ujson-5.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:644552d1e89983c08d0c24358fbcb5829ae5b5deee9d876e16d20085cfa7dc81"}, {file = "ujson-5.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0cae4a9c141856f7ad1a79c17ff1aaebf7fd8faa2f2c2614c37d6f82ed261d96"}, @@ -1162,57 +1170,70 @@ wcwidth = [ {file = "wcwidth-0.2.5.tar.gz", hash = "sha256:c4d647b99872929fdb7bdcaa4fbe7f01413ed3d98077df798530e5b04f116c83"}, ] wrapt = [ - {file = "wrapt-1.13.3-cp27-cp27m-macosx_10_9_x86_64.whl", hash = "sha256:e05e60ff3b2b0342153be4d1b597bbcfd8330890056b9619f4ad6b8d5c96a81a"}, - {file = "wrapt-1.13.3-cp27-cp27m-manylinux1_i686.whl", hash = "sha256:85148f4225287b6a0665eef08a178c15097366d46b210574a658c1ff5b377489"}, - {file = "wrapt-1.13.3-cp27-cp27m-manylinux1_x86_64.whl", hash = "sha256:2dded5496e8f1592ec27079b28b6ad2a1ef0b9296d270f77b8e4a3a796cf6909"}, - {file = "wrapt-1.13.3-cp27-cp27m-manylinux2010_i686.whl", hash = "sha256:e94b7d9deaa4cc7bac9198a58a7240aaf87fe56c6277ee25fa5b3aa1edebd229"}, - {file = "wrapt-1.13.3-cp27-cp27m-manylinux2010_x86_64.whl", hash = "sha256:498e6217523111d07cd67e87a791f5e9ee769f9241fcf8a379696e25806965af"}, - {file = "wrapt-1.13.3-cp27-cp27mu-manylinux1_i686.whl", hash = "sha256:ec7e20258ecc5174029a0f391e1b948bf2906cd64c198a9b8b281b811cbc04de"}, - {file = "wrapt-1.13.3-cp27-cp27mu-manylinux1_x86_64.whl", hash = "sha256:87883690cae293541e08ba2da22cacaae0a092e0ed56bbba8d018cc486fbafbb"}, - {file = "wrapt-1.13.3-cp27-cp27mu-manylinux2010_i686.whl", hash = "sha256:f99c0489258086308aad4ae57da9e8ecf9e1f3f30fa35d5e170b4d4896554d80"}, - {file = "wrapt-1.13.3-cp27-cp27mu-manylinux2010_x86_64.whl", hash = "sha256:6a03d9917aee887690aa3f1747ce634e610f6db6f6b332b35c2dd89412912bca"}, - {file = "wrapt-1.13.3-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:936503cb0a6ed28dbfa87e8fcd0a56458822144e9d11a49ccee6d9a8adb2ac44"}, - {file = "wrapt-1.13.3-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:f9c51d9af9abb899bd34ace878fbec8bf357b3194a10c4e8e0a25512826ef056"}, - {file = "wrapt-1.13.3-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:220a869982ea9023e163ba915077816ca439489de6d2c09089b219f4e11b6785"}, - {file = "wrapt-1.13.3-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:0877fe981fd76b183711d767500e6b3111378ed2043c145e21816ee589d91096"}, - {file = "wrapt-1.13.3-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:43e69ffe47e3609a6aec0fe723001c60c65305784d964f5007d5b4fb1bc6bf33"}, - {file = "wrapt-1.13.3-cp310-cp310-win32.whl", hash = "sha256:78dea98c81915bbf510eb6a3c9c24915e4660302937b9ae05a0947164248020f"}, - {file = "wrapt-1.13.3-cp310-cp310-win_amd64.whl", hash = "sha256:ea3e746e29d4000cd98d572f3ee2a6050a4f784bb536f4ac1f035987fc1ed83e"}, - {file = "wrapt-1.13.3-cp35-cp35m-manylinux1_i686.whl", hash = "sha256:8c73c1a2ec7c98d7eaded149f6d225a692caa1bd7b2401a14125446e9e90410d"}, - {file = "wrapt-1.13.3-cp35-cp35m-manylinux1_x86_64.whl", hash = "sha256:086218a72ec7d986a3eddb7707c8c4526d677c7b35e355875a0fe2918b059179"}, - {file = "wrapt-1.13.3-cp35-cp35m-manylinux2010_i686.whl", hash = "sha256:e92d0d4fa68ea0c02d39f1e2f9cb5bc4b4a71e8c442207433d8db47ee79d7aa3"}, - {file = "wrapt-1.13.3-cp35-cp35m-manylinux2010_x86_64.whl", hash = "sha256:d4a5f6146cfa5c7ba0134249665acd322a70d1ea61732723c7d3e8cc0fa80755"}, - {file = "wrapt-1.13.3-cp35-cp35m-win32.whl", hash = "sha256:8aab36778fa9bba1a8f06a4919556f9f8c7b33102bd71b3ab307bb3fecb21851"}, - {file = "wrapt-1.13.3-cp35-cp35m-win_amd64.whl", hash = "sha256:944b180f61f5e36c0634d3202ba8509b986b5fbaf57db3e94df11abee244ba13"}, - {file = "wrapt-1.13.3-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:2ebdde19cd3c8cdf8df3fc165bc7827334bc4e353465048b36f7deeae8ee0918"}, - {file = "wrapt-1.13.3-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:610f5f83dd1e0ad40254c306f4764fcdc846641f120c3cf424ff57a19d5f7ade"}, - {file = "wrapt-1.13.3-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:5601f44a0f38fed36cc07db004f0eedeaadbdcec90e4e90509480e7e6060a5bc"}, - {file = "wrapt-1.13.3-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:e6906d6f48437dfd80464f7d7af1740eadc572b9f7a4301e7dd3d65db285cacf"}, - {file = "wrapt-1.13.3-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:766b32c762e07e26f50d8a3468e3b4228b3736c805018e4b0ec8cc01ecd88125"}, - {file = "wrapt-1.13.3-cp36-cp36m-win32.whl", hash = "sha256:5f223101f21cfd41deec8ce3889dc59f88a59b409db028c469c9b20cfeefbe36"}, - {file = "wrapt-1.13.3-cp36-cp36m-win_amd64.whl", hash = "sha256:f122ccd12fdc69628786d0c947bdd9cb2733be8f800d88b5a37c57f1f1d73c10"}, - {file = "wrapt-1.13.3-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:46f7f3af321a573fc0c3586612db4decb7eb37172af1bc6173d81f5b66c2e068"}, - {file = "wrapt-1.13.3-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:778fd096ee96890c10ce96187c76b3e99b2da44e08c9e24d5652f356873f6709"}, - {file = "wrapt-1.13.3-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:0cb23d36ed03bf46b894cfec777eec754146d68429c30431c99ef28482b5c1df"}, - {file = "wrapt-1.13.3-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:96b81ae75591a795d8c90edc0bfaab44d3d41ffc1aae4d994c5aa21d9b8e19a2"}, - {file = "wrapt-1.13.3-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:7dd215e4e8514004c8d810a73e342c536547038fb130205ec4bba9f5de35d45b"}, - {file = "wrapt-1.13.3-cp37-cp37m-win32.whl", hash = "sha256:47f0a183743e7f71f29e4e21574ad3fa95676136f45b91afcf83f6a050914829"}, - {file = "wrapt-1.13.3-cp37-cp37m-win_amd64.whl", hash = "sha256:fd76c47f20984b43d93de9a82011bb6e5f8325df6c9ed4d8310029a55fa361ea"}, - {file = "wrapt-1.13.3-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:b73d4b78807bd299b38e4598b8e7bd34ed55d480160d2e7fdaabd9931afa65f9"}, - {file = "wrapt-1.13.3-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:ec9465dd69d5657b5d2fa6133b3e1e989ae27d29471a672416fd729b429eb554"}, - {file = "wrapt-1.13.3-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:dd91006848eb55af2159375134d724032a2d1d13bcc6f81cd8d3ed9f2b8e846c"}, - {file = "wrapt-1.13.3-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:ae9de71eb60940e58207f8e71fe113c639da42adb02fb2bcbcaccc1ccecd092b"}, - {file = "wrapt-1.13.3-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:51799ca950cfee9396a87f4a1240622ac38973b6df5ef7a41e7f0b98797099ce"}, - {file = "wrapt-1.13.3-cp38-cp38-win32.whl", hash = "sha256:4b9c458732450ec42578b5642ac53e312092acf8c0bfce140ada5ca1ac556f79"}, - {file = "wrapt-1.13.3-cp38-cp38-win_amd64.whl", hash = "sha256:7dde79d007cd6dfa65afe404766057c2409316135cb892be4b1c768e3f3a11cb"}, - {file = "wrapt-1.13.3-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:981da26722bebb9247a0601e2922cedf8bb7a600e89c852d063313102de6f2cb"}, - {file = "wrapt-1.13.3-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:705e2af1f7be4707e49ced9153f8d72131090e52be9278b5dbb1498c749a1e32"}, - {file = "wrapt-1.13.3-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:25b1b1d5df495d82be1c9d2fad408f7ce5ca8a38085e2da41bb63c914baadff7"}, - {file = "wrapt-1.13.3-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:77416e6b17926d953b5c666a3cb718d5945df63ecf922af0ee576206d7033b5e"}, - {file = "wrapt-1.13.3-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:865c0b50003616f05858b22174c40ffc27a38e67359fa1495605f96125f76640"}, - {file = "wrapt-1.13.3-cp39-cp39-win32.whl", hash = "sha256:0a017a667d1f7411816e4bf214646d0ad5b1da2c1ea13dec6c162736ff25a374"}, - {file = "wrapt-1.13.3-cp39-cp39-win_amd64.whl", hash = "sha256:81bd7c90d28a4b2e1df135bfbd7c23aee3050078ca6441bead44c42483f9ebfb"}, - {file = "wrapt-1.13.3.tar.gz", hash = "sha256:1fea9cd438686e6682271d36f3481a9f3636195578bab9ca3382e2f5f01fc185"}, + {file = "wrapt-1.14.0-cp27-cp27m-macosx_10_9_x86_64.whl", hash = "sha256:5a9a1889cc01ed2ed5f34574c90745fab1dd06ec2eee663e8ebeefe363e8efd7"}, + {file = "wrapt-1.14.0-cp27-cp27m-manylinux1_i686.whl", hash = "sha256:9a3ff5fb015f6feb78340143584d9f8a0b91b6293d6b5cf4295b3e95d179b88c"}, + {file = "wrapt-1.14.0-cp27-cp27m-manylinux1_x86_64.whl", hash = "sha256:4b847029e2d5e11fd536c9ac3136ddc3f54bc9488a75ef7d040a3900406a91eb"}, + {file = "wrapt-1.14.0-cp27-cp27m-manylinux2010_i686.whl", hash = "sha256:9a5a544861b21e0e7575b6023adebe7a8c6321127bb1d238eb40d99803a0e8bd"}, + {file = "wrapt-1.14.0-cp27-cp27m-manylinux2010_x86_64.whl", hash = "sha256:88236b90dda77f0394f878324cfbae05ae6fde8a84d548cfe73a75278d760291"}, + {file = "wrapt-1.14.0-cp27-cp27mu-manylinux1_i686.whl", hash = "sha256:f0408e2dbad9e82b4c960274214af533f856a199c9274bd4aff55d4634dedc33"}, + {file = "wrapt-1.14.0-cp27-cp27mu-manylinux1_x86_64.whl", hash = "sha256:9d8c68c4145041b4eeae96239802cfdfd9ef927754a5be3f50505f09f309d8c6"}, + {file = "wrapt-1.14.0-cp27-cp27mu-manylinux2010_i686.whl", hash = "sha256:22626dca56fd7f55a0733e604f1027277eb0f4f3d95ff28f15d27ac25a45f71b"}, + {file = "wrapt-1.14.0-cp27-cp27mu-manylinux2010_x86_64.whl", hash = "sha256:65bf3eb34721bf18b5a021a1ad7aa05947a1767d1aa272b725728014475ea7d5"}, + {file = "wrapt-1.14.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:09d16ae7a13cff43660155383a2372b4aa09109c7127aa3f24c3cf99b891c330"}, + {file = "wrapt-1.14.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:debaf04f813ada978d7d16c7dfa16f3c9c2ec9adf4656efdc4defdf841fc2f0c"}, + {file = "wrapt-1.14.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:748df39ed634851350efa87690c2237a678ed794fe9ede3f0d79f071ee042561"}, + {file = "wrapt-1.14.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:1807054aa7b61ad8d8103b3b30c9764de2e9d0c0978e9d3fc337e4e74bf25faa"}, + {file = "wrapt-1.14.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:763a73ab377390e2af26042f685a26787c402390f682443727b847e9496e4a2a"}, + {file = "wrapt-1.14.0-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:8529b07b49b2d89d6917cfa157d3ea1dfb4d319d51e23030664a827fe5fd2131"}, + {file = "wrapt-1.14.0-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:68aeefac31c1f73949662ba8affaf9950b9938b712fb9d428fa2a07e40ee57f8"}, + {file = "wrapt-1.14.0-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:59d7d92cee84a547d91267f0fea381c363121d70fe90b12cd88241bd9b0e1763"}, + {file = "wrapt-1.14.0-cp310-cp310-win32.whl", hash = "sha256:3a88254881e8a8c4784ecc9cb2249ff757fd94b911d5df9a5984961b96113fff"}, + {file = "wrapt-1.14.0-cp310-cp310-win_amd64.whl", hash = "sha256:9a242871b3d8eecc56d350e5e03ea1854de47b17f040446da0e47dc3e0b9ad4d"}, + {file = "wrapt-1.14.0-cp35-cp35m-manylinux1_i686.whl", hash = "sha256:a65bffd24409454b889af33b6c49d0d9bcd1a219b972fba975ac935f17bdf627"}, + {file = "wrapt-1.14.0-cp35-cp35m-manylinux1_x86_64.whl", hash = "sha256:9d9fcd06c952efa4b6b95f3d788a819b7f33d11bea377be6b8980c95e7d10775"}, + {file = "wrapt-1.14.0-cp35-cp35m-manylinux2010_i686.whl", hash = "sha256:db6a0ddc1282ceb9032e41853e659c9b638789be38e5b8ad7498caac00231c23"}, + {file = "wrapt-1.14.0-cp35-cp35m-manylinux2010_x86_64.whl", hash = "sha256:14e7e2c5f5fca67e9a6d5f753d21f138398cad2b1159913ec9e9a67745f09ba3"}, + {file = "wrapt-1.14.0-cp35-cp35m-win32.whl", hash = "sha256:6d9810d4f697d58fd66039ab959e6d37e63ab377008ef1d63904df25956c7db0"}, + {file = "wrapt-1.14.0-cp35-cp35m-win_amd64.whl", hash = "sha256:d808a5a5411982a09fef6b49aac62986274ab050e9d3e9817ad65b2791ed1425"}, + {file = "wrapt-1.14.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:b77159d9862374da213f741af0c361720200ab7ad21b9f12556e0eb95912cd48"}, + {file = "wrapt-1.14.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:36a76a7527df8583112b24adc01748cd51a2d14e905b337a6fefa8b96fc708fb"}, + {file = "wrapt-1.14.0-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:a0057b5435a65b933cbf5d859cd4956624df37b8bf0917c71756e4b3d9958b9e"}, + {file = "wrapt-1.14.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3a0a4ca02752ced5f37498827e49c414d694ad7cf451ee850e3ff160f2bee9d3"}, + {file = "wrapt-1.14.0-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:8c6be72eac3c14baa473620e04f74186c5d8f45d80f8f2b4eda6e1d18af808e8"}, + {file = "wrapt-1.14.0-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:21b1106bff6ece8cb203ef45b4f5778d7226c941c83aaaa1e1f0f4f32cc148cd"}, + {file = "wrapt-1.14.0-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:493da1f8b1bb8a623c16552fb4a1e164c0200447eb83d3f68b44315ead3f9036"}, + {file = "wrapt-1.14.0-cp36-cp36m-win32.whl", hash = "sha256:89ba3d548ee1e6291a20f3c7380c92f71e358ce8b9e48161401e087e0bc740f8"}, + {file = "wrapt-1.14.0-cp36-cp36m-win_amd64.whl", hash = "sha256:729d5e96566f44fccac6c4447ec2332636b4fe273f03da128fff8d5559782b06"}, + {file = "wrapt-1.14.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:891c353e95bb11abb548ca95c8b98050f3620a7378332eb90d6acdef35b401d4"}, + {file = "wrapt-1.14.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:23f96134a3aa24cc50614920cc087e22f87439053d886e474638c68c8d15dc80"}, + {file = "wrapt-1.14.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6807bcee549a8cb2f38f73f469703a1d8d5d990815c3004f21ddb68a567385ce"}, + {file = "wrapt-1.14.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6915682f9a9bc4cf2908e83caf5895a685da1fbd20b6d485dafb8e218a338279"}, + {file = "wrapt-1.14.0-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:f2f3bc7cd9c9fcd39143f11342eb5963317bd54ecc98e3650ca22704b69d9653"}, + {file = "wrapt-1.14.0-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:3a71dbd792cc7a3d772ef8cd08d3048593f13d6f40a11f3427c000cf0a5b36a0"}, + {file = "wrapt-1.14.0-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:5a0898a640559dec00f3614ffb11d97a2666ee9a2a6bad1259c9facd01a1d4d9"}, + {file = "wrapt-1.14.0-cp37-cp37m-win32.whl", hash = "sha256:167e4793dc987f77fd476862d32fa404d42b71f6a85d3b38cbce711dba5e6b68"}, + {file = "wrapt-1.14.0-cp37-cp37m-win_amd64.whl", hash = "sha256:d066ffc5ed0be00cd0352c95800a519cf9e4b5dd34a028d301bdc7177c72daf3"}, + {file = "wrapt-1.14.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:d9bdfa74d369256e4218000a629978590fd7cb6cf6893251dad13d051090436d"}, + {file = "wrapt-1.14.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:2498762814dd7dd2a1d0248eda2afbc3dd9c11537bc8200a4b21789b6df6cd38"}, + {file = "wrapt-1.14.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5f24ca7953f2643d59a9c87d6e272d8adddd4a53bb62b9208f36db408d7aafc7"}, + {file = "wrapt-1.14.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:5b835b86bd5a1bdbe257d610eecab07bf685b1af2a7563093e0e69180c1d4af1"}, + {file = "wrapt-1.14.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b21650fa6907e523869e0396c5bd591cc326e5c1dd594dcdccac089561cacfb8"}, + {file = "wrapt-1.14.0-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:354d9fc6b1e44750e2a67b4b108841f5f5ea08853453ecbf44c81fdc2e0d50bd"}, + {file = "wrapt-1.14.0-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:1f83e9c21cd5275991076b2ba1cd35418af3504667affb4745b48937e214bafe"}, + {file = "wrapt-1.14.0-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:61e1a064906ccba038aa3c4a5a82f6199749efbbb3cef0804ae5c37f550eded0"}, + {file = "wrapt-1.14.0-cp38-cp38-win32.whl", hash = "sha256:28c659878f684365d53cf59dc9a1929ea2eecd7ac65da762be8b1ba193f7e84f"}, + {file = "wrapt-1.14.0-cp38-cp38-win_amd64.whl", hash = "sha256:b0ed6ad6c9640671689c2dbe6244680fe8b897c08fd1fab2228429b66c518e5e"}, + {file = "wrapt-1.14.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b3f7e671fb19734c872566e57ce7fc235fa953d7c181bb4ef138e17d607dc8a1"}, + {file = "wrapt-1.14.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:87fa943e8bbe40c8c1ba4086971a6fefbf75e9991217c55ed1bcb2f1985bd3d4"}, + {file = "wrapt-1.14.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:4775a574e9d84e0212f5b18886cace049a42e13e12009bb0491562a48bb2b758"}, + {file = "wrapt-1.14.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:9d57677238a0c5411c76097b8b93bdebb02eb845814c90f0b01727527a179e4d"}, + {file = "wrapt-1.14.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:00108411e0f34c52ce16f81f1d308a571df7784932cc7491d1e94be2ee93374b"}, + {file = "wrapt-1.14.0-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:d332eecf307fca852d02b63f35a7872de32d5ba8b4ec32da82f45df986b39ff6"}, + {file = "wrapt-1.14.0-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:01f799def9b96a8ec1ef6b9c1bbaf2bbc859b87545efbecc4a78faea13d0e3a0"}, + {file = "wrapt-1.14.0-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:47045ed35481e857918ae78b54891fac0c1d197f22c95778e66302668309336c"}, + {file = "wrapt-1.14.0-cp39-cp39-win32.whl", hash = "sha256:2eca15d6b947cfff51ed76b2d60fd172c6ecd418ddab1c5126032d27f74bc350"}, + {file = "wrapt-1.14.0-cp39-cp39-win_amd64.whl", hash = "sha256:bb36fbb48b22985d13a6b496ea5fb9bb2a076fea943831643836c9f6febbcfdc"}, + {file = "wrapt-1.14.0.tar.gz", hash = "sha256:8323a43bd9c91f62bb7d4be74cc9ff10090e7ef820e27bfe8815c57e68261311"}, ] yapf = [ {file = "yapf-0.32.0-py2.py3-none-any.whl", hash = "sha256:8fea849025584e486fd06d6ba2bed717f396080fd3cc236ba10cb97c4c51cf32"}, diff --git a/tests/test_jarvis_core.py b/tests/test_jarvis_core.py index 6d89349..e153b07 100644 --- a/tests/test_jarvis_core.py +++ b/tests/test_jarvis_core.py @@ -1,5 +1,5 @@ -from jarvis_core import __version__ - - -def test_version(): - assert __version__ == "0.1.0" +from jarvis_core import __version__ + + +def test_version(): + assert __version__ == "0.1.0"