Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Specify a formatter for the root logger handler #10

Merged
merged 1 commit into from
Oct 3, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions src/dandisets_linkml_status_tools/cli/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,10 @@
from dandi.dandiapi import DandiAPIClient
from pydantic2linkml.cli.tools import LogLevel

from dandisets_linkml_status_tools.cli.tools import compile_validation_report, output_reports
from dandisets_linkml_status_tools.cli.tools import (
compile_validation_report,
output_reports,
)

if TYPE_CHECKING:
from dandisets_linkml_status_tools.cli.models import DandisetValidationReport
Expand Down Expand Up @@ -35,7 +38,10 @@ def main(
] = LogLevel.WARNING,
):
# Set log level of the CLI
logging.basicConfig(level=getattr(logging, log_level))
logging.basicConfig(
format="[%(asctime)s]%(levelname)s:%(name)s:%(message)s",
level=getattr(logging, log_level),
)

output_path = Path(dandi_instance + "-reports")

Expand Down
Loading