Skip to content

Commit

Permalink
removed unused logger imports
Browse files Browse the repository at this point in the history
  • Loading branch information
nfearnley committed May 21, 2024
1 parent 7631bec commit bece151
Show file tree
Hide file tree
Showing 7 changed files with 3 additions and 21 deletions.
1 change: 0 additions & 1 deletion sizebot/lib/eval.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,6 @@ def get_eval_globals() -> dict[str, Any]:
"Image": Image,
"ImageDraw": ImageDraw,
"io": io,
"logger": logger,
"errors": errors,
"arrow": arrow,
"roll": roll,
Expand Down
3 changes: 0 additions & 3 deletions sizebot/lib/macrovision.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
from dataclasses import dataclass
import json
import importlib.resources as pkg_resources
import logging

import sizebot.data
from sizebot.lib.digidecimal import Decimal
Expand All @@ -13,8 +12,6 @@
from sizebot.lib.userdb import User
from sizebot.lib.utils import url_safe

logger = logging.getLogger("sizebot")

_model_heights = json.loads(pkg_resources.read_text(sizebot.data, "models.json"))


Expand Down
4 changes: 0 additions & 4 deletions sizebot/lib/proportions.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import logging

from discord import Embed

from sizebot import __version__
Expand All @@ -13,8 +11,6 @@
from sizebot.lib.userdb import User
from sizebot.lib.stats import Stat, calc_view_angle, get_mapped_stat, StatBox

logger = logging.getLogger("sizebot")

compareicon = "https://media.discordapp.net/attachments/650460192009617433/665022187916492815/Compare.png"


Expand Down
4 changes: 0 additions & 4 deletions sizebot/lib/statproxy.py
Original file line number Diff line number Diff line change
@@ -1,16 +1,12 @@
from __future__ import annotations

import logging

from sizebot.lib.errors import InvalidStat, InvalidStatTag
from sizebot.lib.stats import get_mapped_stat, taglist
from sizebot.lib.types import BotContext

re_full_string = r"\$(\w+=[^;$]+;?)+"
re_component = r"(\w+)=([^;$]+);?"

logger = logging.getLogger("sizebot")


class StatProxy:
def __init__(self, name: str, tag: bool):
Expand Down
3 changes: 0 additions & 3 deletions sizebot/lib/surface.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
import logging
from sizebot.lib.units import SV, WV

GRAVITY = 980.7 # cm/s^2
WATER_SURFACE_TENSION = 72.8 # dy/cm

logger = logging.getLogger("sizebot")

# WV = grams
# SV = meters

Expand Down
4 changes: 0 additions & 4 deletions sizebot/plugins/active.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
import logging

import arrow

import discord
from sizebot.lib import errors, userdb

logger = logging.getLogger("sizebot")


async def on_message(m: discord.Message):
"""Is this user active?"""
Expand Down
5 changes: 3 additions & 2 deletions sizebot/plugins/monika.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
import sizebot.data

logger = logging.getLogger("sizebot")
monikalines = pkg_resources.read_text(sizebot.data, "monikalines.txt").splitlines()

_monikalines = pkg_resources.read_text(sizebot.data, "monikalines.txt").splitlines()


async def on_message(m: discord.Message):
Expand All @@ -20,5 +21,5 @@ async def on_message(m: discord.Message):
logger.debug("Monika detected.")
if random.randrange(6) == 1:
logger.info("Monika triggered.")
line = random.choice(monikalines)
line = random.choice(_monikalines)
await m.channel.send(line, delete_after = 7)

0 comments on commit bece151

Please sign in to comment.