Advanced Pass to keep only 1 of any episode from any hit (Local News Pass)

I'm not sure why your rule isn't working, but I think you might be the only one running into this. I have a couple news programs—BBC World News, PBS Newshour, etc.— and they're set to keep only the 2 most recent recordings, and have never had an issue like you're experiencing.

It sounds like it may be something more related to the guide, such as different time slots having different series identifiers, than an actual bug.

Perhaps your could offer more details, as I'm trying to follow along in your explanation, but am still confused.

I checked the code and the pruner does not care what series is being recorded.. it should apply to all recordings that originated from a season pass, and respect the keep settings accordingly.

@tmm1 thanks for checking the code. That seems to be consistent with what I thought. It’s not working as intended then for me for some reason. Anything I can provide that would be useful to troubleshoot.

These just pile up, if I let them go for multiple days it keeps one of each but only the last days worth of each episode.

The names of each are different, the IDs are different is it possible in the advanced case the code isn’t pruning on the ID of the subscription and instead is keying off the Name or something else? That’s what it feels like.

@racameron I believe the differences is I’m taping different shows all with different names on the same channel. “News at Noon” “News at 4” “ News at 5” etc. each with their own ID for that time slot. The guide data is correct from what I can see. these are different shows not the same show aired again that same day.

For shows that are a single taping on a single day (like The Daily Show) I’m able to have only one recording kept.

Check out the screen shots I think they make my use case pretty clear. If not please do ask more questions as i may not be explaining it correctly.

Can you click Help > Submit Diagnostics

Also try running the pruner manually:

Then check the Log to see what was deleted. You might still have to empty from the Trash as well.

@tmm1 Logs have been submitted as a2a63454-9755-443d-bab2-42b2876b524a .

Oddly this evening things started working as expected and the old backlog of recordings cleaned themselves up to show only the latest so something must have clogged up the pruner for a little while. I’m wondering if perhaps a backlog of checking for commercials or something? What’s the normal timing on the reaper?

I’ll keep an eye on it tomorrow. I see the log link in there now under help (had no idea it was there) and will try snooping on it. Is there a setting to ask an advanced schedule pass to never put deleted items for that pass in the trash? I’ll be sucking up about 8-9 hours of HD news and only watching about 1-2 hours of it a day depending on when we decide to watch. If not no big deal. If this ends up working well we will probably find a android streamer with good horsepower and a coveted USB port :slight_smile:

Yes it looks like it waited until all the back to back recording / commercial detection happened before pruning I think.

2020/05/28 19:23:06.033316 [DVR] Pruning old recording 7 News at 530PM 2020-05-28-1730.mpg
2020/05/28 19:23:06.039366 [DVR] Pruning old recording 7 News at 5PM 2020-05-28-1700.mpg
2020/05/28 19:23:06.042902 [DVR] Pruning old recording 7 News at 430PM 2020-05-28-1630.mpg
2020/05/28 19:23:06.046241 [DVR] Pruning old recording 7 News at Noon 2020-05-28-1203.mpg

I had paused the season pass which made it stop clogging up the works.

Commercial detection seems slow in the shield. Shame we can’t fire up the Tegra AI cores :slight_smile: bet it would fly.

Hmm, the pruner should be running every 3 hours regardless of what else is happening..

Ahh is there a way to have you run the pruner more often? I see that it’s very much aware that it’s doing the new recording as part of the advanced schedule. Can that be used as a trigger to fire off a prune. For news I only really care about what the latest available is so there is no need to keep any around. In 3 hours I could have 6 1/2 hour news programs queues up during the day. Is pruning somehow expensive operation? Why is it going so sparingly?

I did try manually running curl To fire off a prune tonight with the url above and It didn’t seem to do anything in the logs I did get a “true” returned from the call. It would seem /deleted is not the right end point for instantly enforcing the keep 1 of an advance schedule. I did just /dvr/pruner and it worked in a few seconds. I’m guessing the /deleted is to empty the trash if the time has gone by appropriately.

So I guess the question remains - why 3 hours? Can there be a global setting somewhere to let me choose to prune after every recording is finished? I’m not sure I get the trade off to run it on a wider schedule seems like from poking around the forums tonight it was 24 hours before. This seems to break the keep x intent doesn’t it?

Would love to see this smoothed out without me needing to make a call from another server in the home to force the behavior I would like if it’s not horribly expensive on the DVR to do the prune exercise.

If I understand you correctly you are creating many hours of recordings each and every day. Leaving commercial detection enabled for this pass is likely causing it to run almost continually to try and keep up. I’m not sure but as you speculated I’m betting the pruner will not take any action on a show that is waiting for commercial detection, or has it in progress.

This might explain the issue.

@Macnbaish It seems to be a combination of both the 3 hour prune process schedule and possibly the commercial skip (although @tmm1 mentioned that prune will win over any other process in action)

I don't see a way in the UI to turn off commercial skip for a particular pass, is this possible? I'm happy to turn it off for the news if it would help.

Only from the web UI: Recordings > Shows > All > Series Name > Settings (Cog icon) > Show Settings > Detect Commercials

Ok.. so I need to go into each recording today as they are happening in each time slot and turn them off individually. Then hopefully they will be remembered. It's sort of amazing this isn't a setting that can be set at the Pass Schedule level vs. on the show level. The assumption that the Pass covers only one show is what gets me into trouble here possibly.

I'll undelete a bunch from yesterday and set the flags and see if that helps today as a one time thing that shouldn't be so bad to test with.

I still think my 3 hour prune schedule timer will keep these around and piling up especially in the period of the day where they do 1/2 hour fresh news segments back to back.

KC

While you cannot set the commercial detection from a rule (which rules out rules that may not have a particular series, or may cover multiple series), there is a workaround: you can disable commercial detection in general, then selectively enable it for new programs as they record.

Edit: I know it's frustrating, but when you create edge cases that are a bit outside the normal workflows, bugs and inconsistencies tend to show up much more frequently.

@racameron I appreciate the help and your commentary. However, I'm not entirely sure I buy into the assumption that it's "outside the normal workflow" to want to record the local news and have only the latest copy of the news be available.

If you step back a little and look at the behavior of the platform, yes my situation is indeed pressing on a deficiency of the platform. The Keep Only logic actually doesn't work in real time, it batches. So for any program that you have set to keep only one, a marathon in the program guide could very well create the same issue.

I also don't think it's a good workaround to turn off commercial skipping broadly and then try to remember to turn it on for every new season pass going forward. It's far better to just turn it off on a per program basis by keeping the programatic hourly and half hourly naming of the programs and finding them and turning it off for each one if the setting is indeed sticky per program. It's a one and done thing these names are predictable. Ideally you should be able to choose the various behaviors of what the platform will do with the recordings at the time that the recordings are scheduled. It's less work for the end user and it will behave the way the end user expects, not to mention more transparent as to why the behavior is happening or not happening.

If I recall, the issue is that you are recording multiple series. And while they all have the same tittle, their SeriesID is different. If that is indeed the root issue, then the issue isn't really with Channels, but rather Gracenote, as they provide the guide data that drives Channels.

I'm not sure that I buy into the argument that recording every occurrence of multiple series and having the DVR maintain only a single recording of all series in aggregate isn't an edge case.

Unfortunately, because of the way that Channels seems to be engineered, it's simply not possible to set commercial detection in the recording rule, because that particular flag seems to be paired with a series. You can either make a recording of each program that falls into your rule with its Keep setting disabled, then change the Detect Commercials setting for that program to Off. After you've done this to each program that will be captured, you can manually delete the now unneeded episodes and adjust your rule's Keep setting. While this is a bit of effort and time initially, it ought to leave the DVR in a state to satisfy your use.

@racameron Advanced Pass Subscriptions let you use a bunch of different criterion for how to record what you want to record. For instance if I wanted to have only the latest baseball game for my favorite team and that team moves channels and is based on a title you will have different IDs.

The gracenote data is correct here. These are different programs.

I get that Channels seems to be engineered in a way currently that this use case falls through the cracks. At the end of the day it's just software and can be changed if they understand the feedback and feel it's worth changing.

To be clear, what you propose is exactly what I have done. So you missed that. And I said a few posts back that it was a one and done acceptable task for me to do to unblock myself at least on the commercial skip side. That's assuming that commercial skip is even blocking me here - it actually may not be. If it is I'm fine with not doing commercial skip for these, if it's not (again I don't think it is) I'd rather have the commercial skip there if it can be.. it's nice.

Based on what was said by the engineer who was nice enough to look at the code. I also believe that the issue I'm having is NOT the commercial skip (it could be helping to contribute) but in fact the issue is that if I record 6 News casts in the 3 hour window between prunes.. I get to see all 6 in the UI until the prune happens even though the series is set to Keep 1. I also think that if this is correct that the prune situation would happen to ANYONE who has a season pass with Keep 1 and there is a marathon that hits that suddenly will keep around more than you want for a 3 hour window. This just makes it seem broken. My original ask.. and it's still the same ask.. is if I can set the system up to just fire off a prune maintenance for cleaning up Keep Until Windows after every recording is triggered. Perhaps that's too expensive an operation on the system, perhaps it's not. From what I can tell hitting the URL endpoint it seems to happen very quickly when triggered manually. So I'm hopeful they can make that change and it will give the illusion that the platform is doing exactly the behavior I want. (I don't care that they are laying around in the trash.. that's fine)

KC

Pruning is not expensive, but in the past things were deleted right away which seemed dangerous. Now that we have the Trash feature, it seems more reasonable to make it more frequent. In the past we also did not provide a "Keep 1" option, because there were bugs where an episode could be deleted while you were still watching it.

Doing things every few hours was the simplest way to get started when this code was written years ago. I could reduce the interval now, but that's also not ideal as I don't want to be waking up sleeping computers and drives unnecessarily when there's nothing to prune.

Maybe the pruner could be kicked off after every successful recording that came from a season pass with a keep rule?

I figured there was a history as to why it is the way it is today.

Maybe the pruner could be kicked off after every successful recording that came from a season pass with a keep rule?\

This is exactly what I would propose sounds like it would check all the right boxes from the user experience standpoint. Do I need to kill the commercial skip rule on these or will a prune happen even if it's trying to do the commercial skip?