mirror of
https://github.com/Marsh232/Telegram-IP-CALC.git
synced 2025-07-01 15:26:10 +00:00
Fix name config
Minor PEP fix
This commit is contained in:
parent
de1c1af628
commit
b35f974de5
2
.gitignore
vendored
2
.gitignore
vendored
@ -39,5 +39,5 @@ coverage.xml
|
|||||||
*.pot
|
*.pot
|
||||||
# Sphinx documentation
|
# Sphinx documentation
|
||||||
docs/_build/
|
docs/_build/
|
||||||
src/сonfig.json
|
src/config.json
|
||||||
.idea/
|
.idea/
|
@ -12,7 +12,7 @@ logging.basicConfig(level=logging.INFO, format="%(asctime)s - %(name)-29s - %(le
|
|||||||
class Config:
|
class Config:
|
||||||
|
|
||||||
# noinspection PyTypeChecker
|
# noinspection PyTypeChecker
|
||||||
def __init__(self, config_file="сonfig.json"):
|
def __init__(self, config_file="config.json"):
|
||||||
self.log = logging.getLogger(__name__)
|
self.log = logging.getLogger(__name__)
|
||||||
self.debug = self.log.debug
|
self.debug = self.log.debug
|
||||||
|
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
from aiogram.types import ReplyKeyboardMarkup, KeyboardButton, ReplyKeyboardRemove
|
from aiogram.types import ReplyKeyboardMarkup, KeyboardButton, ReplyKeyboardRemove
|
||||||
|
|
||||||
network = KeyboardButton('Сеть')
|
network_button = KeyboardButton('Сеть')
|
||||||
subnet = KeyboardButton('Подсети')
|
subnet_button = KeyboardButton('Подсети')
|
||||||
help = KeyboardButton('Помощь')
|
help_button = KeyboardButton('Помощь')
|
||||||
|
|
||||||
kb = ReplyKeyboardMarkup(resize_keyboard=True, one_time_keyboard=True)
|
kb = ReplyKeyboardMarkup(resize_keyboard=True, one_time_keyboard=True)
|
||||||
kb.row(network, subnet, help)
|
kb.row(network_button, subnet_button, help_button)
|
||||||
|
@ -13,7 +13,7 @@ from aiogram.utils import executor
|
|||||||
from config import Config
|
from config import Config
|
||||||
from keyboard import *
|
from keyboard import *
|
||||||
|
|
||||||
config = Config("сonfig.json")
|
config = Config("config.json")
|
||||||
log = logging.getLogger("Bot")
|
log = logging.getLogger("Bot")
|
||||||
bot = Bot(token=config.token)
|
bot = Bot(token=config.token)
|
||||||
dp = Dispatcher(bot)
|
dp = Dispatcher(bot)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user