Refactor and clean up code formatting across multiple files

- Consolidated and simplified code formatting by removing unnecessary line breaks and improving readability in various functions.
- Updated the handling of backup file sending in backup.py for better clarity.
- Streamlined error handling and logging messages in several handlers to enhance consistency.
- Adjusted the Makefile to exclude specific files during Ruff checks and formatting.
- Made minor adjustments to function signatures and parameter handling for improved clarity and consistency.

This commit enhances code maintainability and readability without altering functionality.
This commit is contained in:
Zakhar Izmaylov
2025-01-21 08:57:12 +03:00
parent e7d54ae317
commit a2c71a49f2
33 changed files with 446 additions and 1124 deletions
+1 -1
View File
@@ -44,7 +44,7 @@ async def errors_handler(
filename=f"error_{event.update.update_id}.txt",
),
caption=f"{hbold(type(event.exception).__name__)}: {str(event.exception)[:1021]}...",
)
)
except TelegramBadRequest as exception:
logger.warning(f"Failed to send error details: {exception}")
except Exception as exception: