Orphaned Recordings Issue (1 Viewer)

peter448

Portal Member
June 7, 2008
19
0
Brisbane
Home Country
TV-Server Version: 1.0.0.0 RC1 (Refresh)
MediaPortal Version: 1.0.0.0 RC1 (Refresh)
MediaPortal Skin: Blue Two
Windows Version: Vista Home Premium SP1 (vLite'd)
CPU Type: AMD Athlon(tm) Processor LE-1600 2.20GHz
HDD: Western Digital 500GB SATA (WD5000AAKS)
Memory: 2GB DDR2 800 (2x1GB)
Motherboard: Gigabyte GA-MA78GM-S2H rev1.0
Video Card: Integrated ATI HD-3200
Video Card Driver: 8.475
Sound Card: Integrated Realtek HD
Sound Card AC3: HDMI & SPDIF
Sound Card Driver: 1.84
1. TV Card: Leadtek Winfast DTV1000S
1. TV Card Type: DVB-T
1. TV Card Driver: 1.3.3.5
2. TV Card: Leadtek Winfast DTV1000S
2. TV Card Type: DVB-T
2. TV Card Driver: 1.3.3.5
MPEG2 Video Codec: Vista Codec Pack 4.6.5
MPEG2 Audio Codec: Vista Codec Pack 4.6.5
h.264 Video Codec: Vista Codec Pack 4.6.5
HTPC Case: Antec NSK2480B
Remote: Microsoft
TV: Panasonic TH50PX70a
TV - HTPC Connection: HDMI

Hi All, I've come across another issue (I'll need others to confirm if it should be considered a bug). I haven't been able to locate another post specifically about this.

This is how to replicate.

1. If not already, you need to make/have at least 2 completed TV recordings that you don't want (ie can delete or remove). They need to be at least a minute long each (not that how long they are is the issue, but if they are to short you have to be very quick to see the issue). Preference is to record programs that get named via EPG (ie not 'manual') as it makes the issue easier to verify. Try to also record TV that you haven't recorded before so it doesn't create a folder to store the same shows in, again it just makes it easier to verify.

2. In 'Recorded TV', select one of the recording and play it in full screen.

3. After it has started go back so that you are at the Recorded TV selections screen, with the recording you are playing, still playing in the bottom left.

4. Go to the same recording in the selection list, and delete the recording (ie delete the recording that is playing).

5. The recording will be removed from the selection list while it keeps on playing in the bottom left (This is the clue that led me to think there was a problem).

6. Select Stop to halt the recording that is playing.


Now, repeat the above steps but this time SWAP steps 4 and 6 above for another/different recording. Both will be gone from the selection list (as you would expect).


7. Exit MP and using explorer or whatever go to your Recorded TV location/folder.

You will see that the first recording file still exists in the folder (although it's related .XML file has been deleted), and for the second both the recording and .XML file have been removed.

In the first case you effectively have an orphaned recording, and you have to delete it manually. The second is working as you would expect.

OK. Now I've explained what the issue is, I'll explain what I think is going on with the first case.

When you go to delete the first recording, the actually file the recording is in is actually open and in use, and as in most OS's you cant delete a file if this is the case, so the OS wont let MP delete it.

To my way of thinking the behaviour that has MP trying to delete a file it is currently playing is incorrect.

Solution: After you select delete (and confirm it) for any recording...or any other file MP has access to (videos/music)...it first stops that file, closing it with the OS enabling it to be deleted correctly.

Of course this solution assumes that something non-MP related also doesn't have the file open, but I think that is a reasonable assumption. This of course could also be dealt with at an error/informational level.

Can others please confirm this issue for me please. BTW I'm not running any SVN's.

Regards, Pete :confused:
 

Paranoid Delusion

Moderation Manager
  • Premium Supporter
  • June 13, 2005
    13,052
    2,978
    Cheshire
    Home Country
    United Kingdom United Kingdom
    Can others please confirm this issue for me please. BTW I'm not running any SVN's

    Yes

    See behaviour as 2 options.

    automatically stop playing file and delete
    or
    ask user to stop playing file, before a delete can take place.

    My thinking, already put to Devs
     

    peter448

    Portal Member
    June 7, 2008
    19
    0
    Brisbane
    Home Country
    See behaviour as 2 options.

    automatically stop playing file and delete
    or
    ask user to stop playing file, before a delete can take place.

    Personal I think 'automatically stop playing file and delete' should be the way to go.

    If you've got confirm deletes on, then the second option above would be another popup to be navigate...could get annoying on a useability front. Implying that a delete would stop a file if it was playing is not an unreasonable assumption.

    Peter
     

    gibman

    Retired Team Member
  • Premium Supporter
  • October 4, 2006
    2,998
    1,372
    Usa
    Home Country
    Ethiopia Ethiopia
    I stumbled upon this problem myself - although I did know of it's since a long time now.

    The fix; I made sure that the database record would only be deleted if the file was successfully deleted also.
    As it was before the database record would always get deleted regardless of the outcome of the file deletion.

    /gibman
     

    Paranoid Delusion

    Moderation Manager
  • Premium Supporter
  • June 13, 2005
    13,052
    2,978
    Cheshire
    Home Country
    United Kingdom United Kingdom
    The fix; I made sure that the database record would only be deleted if the file was successfully deleted also.
    As it was before the database record would always get deleted regardless of the outcome of the file deletion.

    Sounds good, can we have this added as a default action, would rather find the file still there, than just randomly filling up hdd with orphaned recordings.

    Thanks.
     

    peter448

    Portal Member
    June 7, 2008
    19
    0
    Brisbane
    Home Country
    Hi. I see an issue with this fix. Users wont know why the recording hasn't deleted. They'll be pressing delete, probably more than once, and it wont go (and wont go means from the db, .XML and folder), and they wont understand why.

    I still think that Paranoid Delusion' first option is the way to go....but as I'm not a developer there may be reasons doing this option is not feasible.

    Regards, Peter
     

    gibman

    Retired Team Member
  • Premium Supporter
  • October 4, 2006
    2,998
    1,372
    Usa
    Home Country
    Ethiopia Ethiopia
    It's in SVN.

    be my guest and compile tvplugin :)

    Before deleting stuff, it now determines if a rec. is being played back locally, if it does, then playback is stopped and then deleted.
    There are no extra prompts involved here.

    Todo; alternatively tell the user that the recorded TV show could not be deleted.


    /gibman
     

    Paranoid Delusion

    Moderation Manager
  • Premium Supporter
  • June 13, 2005
    13,052
    2,978
    Cheshire
    Home Country
    United Kingdom United Kingdom
    Before deleting stuff, it now determines if a rec. is being played back locally, if it does, then playback is stopped and then deleted.
    There are no extra prompts involved here.

    Excellent.

    Thnx gibman
     

    gibman

    Retired Team Member
  • Premium Supporter
  • October 4, 2006
    2,998
    1,372
    Usa
    Home Country
    Ethiopia Ethiopia
    I have added this too now.
    "tell the user that the recorded TV show could not be deleted."

    lang. def added for english and danish

    <String id="200054">Could not delete TV recording.</String>

    /gibman
     

    Users who are viewing this thread

    Top Bottom