+ Reply to Thread
Results 1 to 8 of 8

Thread: NRecord still auto-deletes shows that have been archived

  1. #1
    Join Date
    Sep 2008
    Location
    California
    Posts
    4,503

    NRecord still auto-deletes shows that have been archived

    Code:
    2012-08-05 22:00:03.984	[DEBUG][7]	Started recording (177820:8:F:\Recordings\Monk\Monk_20120805_22002300.ts)
    2012-08-05 22:00:04.048	[DEBUG][7]	Starting: C:\Users\Public\NPVR\Scripts\ParallelProcessing.bat "F:\Recordings\Monk\Monk_20120805_22002300.ts" 8 177820 1532
    2012-08-05 22:00:04.062	[DEBUG][7]	 - deleting extra recording: C:\Archive\Monk\Monk_20120729_22002300.ts (7/30/2012 5:00:00 AM)
    2012-08-05 22:00:04.404	[DEBUG][7]	 -removing: C:\Archive\Monk\Monk_20120729_22002300.txt
    2012-08-05 22:00:04.404	[DEBUG][7]	 -removing: C:\Archive\Monk\Monk_20120729_22002300.log
    2012-08-05 22:00:04.406	[DEBUG][7]	 -removing: C:\Archive\Monk\Monk_20120729_22002300.edl
    2012-08-05 22:00:04.411	[DEBUG][7]	 -removing: C:\Archive\Monk\Monk_20120729_22002300.logo.txt
    ok, I realize this may not count as a bug, since you probably had no intention of handling this any differently now. But the act of "Archiving" a show kinda implies the user is trying to keep it! So having it count the archived episodes against the "Keep X number of recordings" count, and then delete an episode from the archive location rather defeats the purpose.

    I suggest two rules in your code when processing the "Keep X number of recordings" logic:

    1. Count only the recordings which are currently stored in the current target recording path for that recurring recording.
    2. Only delete the oldest show in the current target recording path for that recurring recording.

    edit: also, while I've not tested it recently, I'm pretty sure there's still another bug in the auto-deletion logic that might be worth fixing:

    if I am watching the oldest episode of a show when a new recording starts, it will try to delete the show I am watching and of course fail because it's open. but it will still remove the recording from the database, thus leaving the recording file 'orphaned' on the disk. After a few months, these orphans add up to many gigabytes of lost disk space, and I have to go hunting around and clean them up by hand. If the file delete fails, just leave the show in the database and go on... catch it next time.
    Last edited by johnsonx42; 2012-08-06 at 08:48 AM.
    NPVR Tech Support Sticky - - http://forums.gbpvr.com/showthread.p...487#post454487
    ---------------------------
    my config: NPVR 2.6.2/Win7Pro/Athlon II X3-440/radeon hd4550/hvr-2250/hvr-850/KWorld 315U/TimeWarner QAM & Analog, OTA ATSC/schedules direct

  2. #2
    Join Date
    Nov 2003
    Location
    NextPVR HQ, Wellington, New Zealand
    Posts
    73,207
    Quote Originally Posted by johnsonx42 View Post
    ok, I realize this may not count as a bug, since you probably had no intention of handling this any differently now.
    This. I hadn't intended it to do that. I could rename the button 'Move' if you think that'd be clearer?

    It's relatively easy for it to clear the group id, so that old recordings are no longer deleted, but I suspect many users would prefer to keep that.

  3. #3
    Join Date
    Sep 2008
    Location
    California
    Posts
    4,503
    I hadn't intended it to do that.
    Since the old "Keep" function from GB-PVR has not made any return to NPVR, we still have no way to prevent a recording from being auto-deleted, other than to set the recording to "Keep All" and then manage by hand (a bit unwieldy for shows that record multiple times per day, and your wife just wants to save a few favorite episodes). Since I did not understand exactly how NPVR keeps track of which shows are part of the group being counted and auto-deleted, I thought the act of moving the show elsewhere would prevent deletion. I'm not complaining about that specific show that got deleted by the way, I didn't care, it's just the fact that it did meant the Archive function doesn't work the way I want it to.

    It's relatively easy for it to clear the group id, so that old recordings are no longer deleted, but I suspect many users would prefer to keep that.
    Perhaps an option in config.xml to set the behavior? <ArchiveClearGroupID>true/false</ArchiveClearGroupID>? Or alternately, if you add a function to NScriptHelper to do this, I could just call it with PostArchiving.bat. I personally think the desire to have the archive function protect a show from auto-deletion would be common enough that the user shouldn't need a special script for it, but any way it can be accomplished is fine.
    NPVR Tech Support Sticky - - http://forums.gbpvr.com/showthread.p...487#post454487
    ---------------------------
    my config: NPVR 2.6.2/Win7Pro/Athlon II X3-440/radeon hd4550/hvr-2250/hvr-850/KWorld 315U/TimeWarner QAM & Analog, OTA ATSC/schedules direct

  4. #4
    Join Date
    Nov 2003
    Location
    NextPVR HQ, Wellington, New Zealand
    Posts
    73,207
    I haven't test it, but this patch should clear the group id when you archive, even if you archive to the current directory - in effect giving you a 'keep' function.
    Attached Files Attached Files

  5. #5
    Join Date
    Sep 2008
    Location
    California
    Posts
    4,503
    Thanks sub. I probably won't get to test it until tomorrow. Olympics are recording now, I'll be out during the break between the daytime and primetime olympics, and I stayed up very late last night so I doubt I'll make it past midnight when the primetime olympics finish.
    NPVR Tech Support Sticky - - http://forums.gbpvr.com/showthread.p...487#post454487
    ---------------------------
    my config: NPVR 2.6.2/Win7Pro/Athlon II X3-440/radeon hd4550/hvr-2250/hvr-850/KWorld 315U/TimeWarner QAM & Analog, OTA ATSC/schedules direct

  6. #6
    Join Date
    Sep 2008
    Location
    California
    Posts
    4,503
    While it's probably no surprise to you as I gather this was a simple change, I can report that with this patch it does seem to work as I hoped. I had 4 episodes of a show that was set to keep 4, I archived 3 of the 4, and then 2 more episodes recorded and I now have 6 episodes so it didn't count the 3 I had archived against the total. Presumably when it does reach the limit, it will only delete unarchived episodes. Thanks for this improvement, it is most welcome.

    One bug does remain in the Archive function - if you go into the Archive menu, and then press Escape to go back (as is standard for NPVR) instead of selecting "[Cancel - Do nothing]", it still responds "Archiving" and issues a dummy archive request to a nul location; with this new code it presumably also clears the Group id which is not what the user was trying to accomplish by pressing Escape.
    NPVR Tech Support Sticky - - http://forums.gbpvr.com/showthread.p...487#post454487
    ---------------------------
    my config: NPVR 2.6.2/Win7Pro/Athlon II X3-440/radeon hd4550/hvr-2250/hvr-850/KWorld 315U/TimeWarner QAM & Analog, OTA ATSC/schedules direct

  7. #7
    Join Date
    Nov 2003
    Location
    NextPVR HQ, Wellington, New Zealand
    Posts
    73,207
    Quote Originally Posted by johnsonx42 View Post
    One bug does remain in the Archive function - if you go into the Archive menu, and then press Escape to go back (as is standard for NPVR) instead of selecting "[Cancel - Do nothing]", it still responds "Archiving" and issues a dummy archive request to a nul location; with this new code it presumably also clears the Group id which is not what the user was trying to accomplish by pressing Escape.
    This should fix it.
    Attached Files Attached Files

  8. #8
    Join Date
    Sep 2008
    Location
    California
    Posts
    4,503
    That patch works too, thanks.
    NPVR Tech Support Sticky - - http://forums.gbpvr.com/showthread.p...487#post454487
    ---------------------------
    my config: NPVR 2.6.2/Win7Pro/Athlon II X3-440/radeon hd4550/hvr-2250/hvr-850/KWorld 315U/TimeWarner QAM & Analog, OTA ATSC/schedules direct

+ Reply to Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts