Skip to content

Commit b909879

Browse files
Copilotcrossjam
andcommitted
Move validation imports to module top level
Co-authored-by: crossjam <208062+crossjam@users.noreply.github.com>
1 parent 1e84dcd commit b909879

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

src/retrocast/process_commands.py

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,11 @@
11
"""CLI commands for processing podcast audio files (transcription, analysis)."""
22

3+
import json
34
from pathlib import Path
45
from typing import Optional
56

67
import rich_click as click
8+
from pydantic import ValidationError
79
from rich.console import Console
810
from rich.progress import (
911
BarColumn,
@@ -18,6 +20,7 @@
1820
from retrocast.appdir import get_app_dir, get_default_db_path
1921
from retrocast.datastore import Datastore
2022
from retrocast.transcription import TranscriptionManager
23+
from retrocast.transcription.models import TranscriptionJSONModel
2124

2225
console = Console()
2326

@@ -463,12 +466,6 @@ def _validate_single_file(
463466
Tuple of (is_valid, error_type, error_message)
464467
error_type can be 'validation' or 'parse' or None
465468
"""
466-
import json
467-
468-
from pydantic import ValidationError
469-
470-
from retrocast.transcription.models import TranscriptionJSONModel
471-
472469
relative_path = json_file.relative_to(output_dir)
473470

474471
try:

0 commit comments

Comments
 (0)