This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import re | |
from logging import CRITICAL, DEBUG, ERROR, INFO, NOTSET, WARNING, Formatter, LogRecord | |
from typing import Dict, Optional | |
import colorama | |
class Colors: | |
"""Available colors for log formatter.""" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
compact: true | |
output: cli | |
quiet: true | |
download-external-modules: true | |
evaluate-variables: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import ast | |
def extract_imports(file_path): | |
with open(file_path, 'r') as file: | |
tree = ast.parse(file.read()) | |
imports = [] | |
for node in ast.walk(tree): | |
if isinstance(node, ast.Import): |
OlderNewer