Skip to content

Commit

Permalink
Logging to debug file copy
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisjkhan committed Dec 31, 2022
1 parent 3746b2a commit 606a6fc
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
7 changes: 4 additions & 3 deletions cdp_backend/pipeline/event_gather_pipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -334,9 +334,10 @@ def convert_video_and_handle_host(

trim_video = bool(session.video_start_time or session.video_end_time)

log.info(f"File to trim: {str(video_filepath)}")
log.info(f"File exists: {video_filepath.exists()}")
log.info(f"File stats: {video_filepath.stat()}")
log.info(f"File to trim: {video_filepath}")
log.info(f"File exists: {Path(video_filepath).exists()}")
if Path(video_filepath).exists():
log.info(f"File stats: {Path(video_filepath).stat()}")

# Convert to mp4 if file isn't of approved web format
cdp_will_host = False
Expand Down
3 changes: 2 additions & 1 deletion cdp_backend/utils/file_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -717,7 +717,8 @@ def clip_and_reformat_video(

log.info(f"File to trim: {str(video_filepath)}")
log.info(f"File exists: {video_filepath.exists()}")
log.info(f"File stats: {video_filepath.stat()}")
if video_filepath.exists():
log.info(f"File stats: {video_filepath.stat()}")

try:
ffmpeg_stdout, ffmpeg_stderr = (
Expand Down

0 comments on commit 606a6fc

Please sign in to comment.