Request: "OriginalAirDate" for programs aired prior to 1970 in recorded_files.json

Want to write your own code to work with a HDHomeRun or work with the HDHomeRun DVR? We are happy to help with concepts, APIs, best practices.
Post Reply
djp952
Posts: 1263
Joined: Wed Oct 01, 2008 8:46 pm
Device ID: 131EB7F7;131ED0E0
Location: Elkridge, MD USA
x 5

Request: "OriginalAirDate" for programs aired prior to 1970 in recorded_files.json

Post by djp952 »

Would it be possible to get an accurate "OriginalAirDate" in the DVR engine's recorded_files.json for dates prior to 1/1/1970? I would be fine with a string-based "YYYY-MM-DD" or even just a "YYYY" value somewhere in the JSON.

The current time_t-based "OriginalAirDate" works fine for current/modern programming, but when the user has recorded something like "Hogan's Heroes" or a move from the 1940s, it would be nice if I could give them slightly more accurate information other than "Some time on or before 1/1/1970" :)

Thank you!

nickk
Silicondust
Posts: 16096
Joined: Tue Jan 13, 2004 9:39 am
x 39

Re: Request: "OriginalAirDate" for programs aired prior to 1970 in recorded_files.json

Post by nickk »

Hi,

This should already work. The OriginalAirDate value is in unix time format - for dates before 1970 it will be a negative number.

I will double check these are coming through.

Nick

signcarver
Expert
Posts: 9254
Joined: Wed Jan 24, 2007 1:04 am
Device ID: 10802091 131B34B7 13231F92 1070A18E 1073ED6F 15300C36
x 15

Re: Request: "OriginalAirDate" for programs aired prior to 1970 in recorded_files.json

Post by signcarver »

Even if it is in the original data, the DVR (recorded_files.json) does not appear to present the original airdate when it is before that date... the few I tested also showed the dvr engine would not get such data when it "retrieves its marching orders" from the server but it could be that the particular series I checked doesn't have such data available.

djp952
Posts: 1263
Joined: Wed Oct 01, 2008 8:46 pm
Device ID: 131EB7F7;131ED0E0
Location: Elkridge, MD USA
x 5

Re: Request: "OriginalAirDate" for programs aired prior to 1970 in recorded_files.json

Post by djp952 »

I see the same thing here, any program prior to 1970 has no OriginalAirDate value at all. I don't recall ever seeing a negative one in the past, but I also treat time_t as an unsigned value, which I will clearly need to change regardless :)

nickk
Silicondust
Posts: 16096
Joined: Tue Jan 13, 2004 9:39 am
x 39

Re: Request: "OriginalAirDate" for programs aired prior to 1970 in recorded_files.json

Post by nickk »

Best to treat unix time as a signed 64-bit int (internally we use a custom type time64_t).

Post Reply