Moved files all say 1 minute length with no metadata

Post Reply
User avatar
MarkGSD

Posts: 14
Joined: Thu Oct 26, 2017 10:09 pm
Location: SoCal

HTPC Specs: Show details

Moved files all say 1 minute length with no metadata

#1

Post by MarkGSD » Fri May 05, 2023 7:45 am

I periodically need to move the WTV files from the assigned recording disk/folder to other disks with more space. I've added these directories into WMC. It can find the files in the new locations but then the metadata gets lost. They all show a length of 1 minute with no episode metadata like actual length, original broadcast date, episode name, etc.

I'm wondering if there is a way to tell WMC to rescan all those directories and reread the metadata. Is that something that the EPG123 Client can do if I use the Rebuild Database option? Or do I need to delete WMC's database so it will rebuild from the various directories?

Space

Posts: 2840
Joined: Sun Jun 02, 2013 9:44 pm
Location:

HTPC Specs: Show details

#2

Post by Space » Fri May 05, 2023 9:01 am

The reason why this happens when you move a WTV file to another folder on another drive (when WMC is monitoring that folder for new videos) is because WMC sees the file in the new location before it is completely done being copied. This means it is missing some of the metadata, so WMC loads incomplete (mostly missing) metadata and then never checks the file again for updated metadata.

I made a post about this here. This post includes the way I "fixed" the "1 minute" metadata, although I did have it not work on one file (not sure why, but it was probably corrupted somehow). It also explains how to prevent this from happening in the first place by copying over the file to a temporary non-WMC monitored folder on the second drive and then after the copy is done "rename" it (move it) to the monitored folder (note that the temporary folder MUST be on the same drive as your final destination folder). This will prevent WMC from loading metadata from a file that has not yet been completely copied over.

I also wrote an AutoHotkey script (using the old 1.1 version of AutoHotkey) that automatically monitors the recording folder and copies over files to the second drive once then are done recording (find it in this thread). The method used by this script differs slightly from the one mentioned in my first post in that instead of moving the file to a temporary folder on the second drive, it instead just copies it directly to the monitored folder on the second drive but with a .TMP extension added to the end of the filename (WMC only looks for files with certain extensions, such as the .WTV extension so it will not load the metadata from this file while it has this unknown extension), then after the copy is done, it renames the file back to the original name with the .WTV extension, so WMC will only "see" the file once the copy is completed, and therefore will be able to load the complete metadata.

User avatar
MarkGSD

Posts: 14
Joined: Thu Oct 26, 2017 10:09 pm
Location: SoCal

HTPC Specs: Show details

#3

Post by MarkGSD » Sun May 07, 2023 6:52 am

It worked! Thank you so much!

Space

Posts: 2840
Joined: Sun Jun 02, 2013 9:44 pm
Location:

HTPC Specs: Show details

#4

Post by Space » Mon May 08, 2023 9:35 am

You're welcome.

Post Reply