K-vanc / Tempest-EPG-Generator

The fastest XMLTV formatted EPG Generator with GUI and the lowest memory usage
https://hub.docker.com/r/kvanc/tempest_epg
Other
121 stars 21 forks source link

I cannot get any listing using the ENC type sources for the US #10

Closed Stuggy closed 1 year ago

Stuggy commented 1 year ago

I can get UK listings but I cannot work out how to get USA listings after trying various of the generators. I always get zero channles in my xml after having added them in my requested channels. I even put in a zip code.

I read the help file too.

K-vanc commented 1 year ago

Hi and thanks for using Tempest. In order to be more clear, Could you please mentione which siteconfig(s) you tried to Generate channel list? Also i didnt get if you have problem on channel generation or epg grabbing (or both)? There are information files in US folder for different siteconfigs since some of them using 5 digit number zip codes such as 10001 while for some others Tempest generating its own location code list on straight channel creation run. Also please note that if you trying tvtv.us(out of US), they recently started wide ranged geo-blocking so you will need an US vpn running on the machine where Tempest runs.

K-vanc commented 1 year ago

Hi again. I have checked all encrypted USA siteconfigs and found minor corrections on channel creation of tvpassport and flixed. Both are corrected. As I said tvtv.us needs US IP address to use. All other siteconfigs are working without an issue. Do you still have problem?

Stuggy commented 1 year ago

Thanks for the replies. I will check and thanks for the clarification on tvtv.us.

I will report back.

Stuggy commented 1 year ago

I just tried some from not a USA IP.


`(1/9) Site: [ENC]thetimes.co.uk_0
Channel id: 437
Xmltv id: Sky Golf
68 shows grabbed in 23.70 seconds

(2/9) Site: mzansimagic.dstv.com_0
Channel id: 213
Xmltv id: Mzansi Bioskop | 213
56 shows grabbed in 2.56 seconds

(3/9) Site: [ENC][EX]tvguide.com[US]_0
Channel id: 9200004886
Xmltv id: [Frontier TV New York] HBO (East) - HBO
No show grabbed in 0.13 seconds

(4/9) Site: [ENC][EX]tvpassport.com_0
Channel id: 1766
Xmltv id: [Broadcast - New York, NY] CBS (WCBS) New York, NY (2-1)
No show grabbed in 0.10 seconds

(5/9) Site: [ENC][EX]tvtv.us_0
Channel id: 11867
Xmltv id: [Charter Spectrum Southern Manhattan - New York] TBS
No show grabbed in 0.07 seconds

(6/9) Site: [ENC][EX]ontvtonight.com[US]_0
Channel id: 9610663133/wcbs-fave-tv
Xmltv id: [Antenna - Broadcast TV New York] WCBS Fave TV
No show grabbed in 0.09 seconds

(7/9) Site: [ENC][EX]ontvtonight.com[US]_0
Channel id: 69022930/the-golf-channel
Xmltv id: [Cable - Eastern Time Zone Eastern Time Zone Standard Cable] The Golf Channel
No show grabbed in 0.01 seconds

(8/9) Site: [ENC][EX]tvguide.com[US]_0
Channel id: 9233005443
Xmltv id: [Frontier TV New York] The Golf Channel
No show grabbed in 0.01 seconds

(9/9) Site: [ENC]denverpost.com_0
Channel id: 55
Xmltv id: [Comcast - Denver Metro, CO] Golf Channel USA`
Stuggy commented 1 year ago

I know I didn't have a VPN for tvtv_us.

I'm still not clear on what channel generator does. Maybe I need to use that. I think it is for just assigning a zip? All the channels show in the tempest configurator without doing anything special in channel generator.

Stuggy commented 1 year ago

If I go into channel generator (which I think is just to get a time zone offset) and enter say 10001 for any of the US providers and hit generate I get:

Please add Channel ID & Name to proceed

K-vanc commented 1 year ago

Hi. Channel generator is for creating fresh channel lists. Since websites changing this information timely, you cannot grab with an out dated channel list. There are some siteconfigs which will directly Generate new list, some of them needs zip code to be entered as user key and some of them will create its own key list on empty run then one of created key shall be used as user key for channel generation. Details for such operation needed siteconfigs explained on below links. The other siteconfigs need no additional data.

https://github.com/K-vanc/Tempest-EPG-Generator/blob/main/Siteconfigs/USA/0_Info%20for%20tvtv.us%20-%20tvpassport%20-%20tvguide%20-%20ontvtonight%20-%20%20directv%20-%20online-tivo%20-%20whattowatch.md

https://github.com/K-vanc/Tempest-EPG-Generator/blob/main/Siteconfigs/USA/0_info%20for%20flixed.io.md

It seems you cannot use encrypted siteconfigs with expire date [ENC][EX]. There may be several reasons for this. Could you please write your;

Tempest Version ? Php/Web Server Name ? Php version ?

Stuggy commented 1 year ago

PHP 7.0.33 Latest tempest from pull - I only copied the changed siteconfigs and the php file but looked unchanged. server name: 5ed03fd41741 (just a local test server)

K-vanc commented 1 year ago

Php version is ok Tempest Version is written on top right of screen. Latest is rv1.4.2 Server Name should be something like Nginx, apache, Xammp etc. Or php's built-in development server and finally what is your operation system? (Windows, linux, android etc.)

Stuggy commented 1 year ago

Version rv 1.4.2 Nginx I created all of this in docker but that shouldn't matter.
Ubuntu latest

K-vanc commented 1 year ago

I dont know much about docker or newer tested to run on docker but I believe shouldnt be matter as you said. Could you please check below url on your browser

http://worldtimeapi.org/api/timezone/Europe/London

Stuggy commented 1 year ago

On my computer not server:

<html><body>
<!--StartFragment--><div id="content"><div class="tabs "><nav class="tabs-navigation"><ul class="tabs-menu" role="tablist"><li class="tabs-menu-item json is-active" role="presentation"><span class="devtools-tab-line"></span></li></ul></nav></div></div><span class="devtools-tab-line"></span><span class="devtools-tab-line"></span><div id="json-panel" style="visibility: visible; height: 100%;" class="tab-panel-box" role="tabpanel" aria-labelledby="json-tab"><div class="tab-panel json"><div class="jsonPanelBox tab-panel-inner"><div class="toolbar"></div></div></div></div><div id="json-panel" style="visibility: visible; height: 100%;" class="tab-panel-box" role="tabpanel" aria-labelledby="json-tab"><div class="tab-panel json"><div class="jsonPanelBox tab-panel-inner"><div class="toolbar"><div class="devtools-separator"></div><div class="devtools-searchbox"><input class="searchBox devtools-filterinput" placeholder="Filter JSON" value=""></div></div><div class="panelContent" id="json-scrolling-panel" tabindex="0">

  |  
-- | --
abbreviation | "GMT"
client_ip | "2.15.36.204"
datetime | "2023-01-17T15:27:05.573781+00:00"
day_of_week | 2
day_of_year | 17
dst | false
dst_from | null
dst_offset | 0
dst_until | null
raw_offset | 0
timezone | "Europe/London"
unixtime | 1673969225
utc_datetime | "2023-01-17T15:27:05.573781+00:00"
utc_offset | "+00:00"
week_number | 3

</div></div></div></div><!--EndFragment-->
</body>
</html>
Stuggy commented 1 year ago

It might be nothing but each time I hit save from the final piece of the tempest configerator after selecting channels the screen says file not found.

K-vanc commented 1 year ago

This link is required for time challenge. It seems your ip is able to reach there. I am not expereinced on docker but I remember that i red on somewhere as docker server has different dns setting from your system. It seems like your docker container is not reaching there. Can you try again after setting some google dns to your container ?

https://docs.docker.com/config/containers/container-networking/

Regarding file not found issue, it Could be an issue with docker file path. I tested Tempest on all browsers of Windows/Linux/Debian and android without any issue but as I told havent tried on docker or havent tried dockers itself so it may need some adjustments. Is it still saving configuration after that message?

Stuggy commented 1 year ago

Ok I'll dig into what you said and see.

It seems weird that some are working but maybe all the ENC type generators need something else.

It does save the configuration that is how I was able to post the results of some random EPG grab attempts above.

K-vanc commented 1 year ago

The only diff between [ENC] and [ENC][EX] is a time challenge has to be solved. From your post, seems [ENC] are running. I also find below SO link for setting docker dns on linux

https://stackoverflow.com/questions/62968807/dns-resolution-in-docker-containers

So that message may be related with sessions. I have no idea how it is working in docker. In the future, i have plans to make a docker container so i will check and fix all these issues

K-vanc commented 1 year ago

On my computer not server:

<html><body>
<!--StartFragment--><div id="content"><div class="tabs "><nav class="tabs-navigation"><ul class="tabs-menu" role="tablist"><li class="tabs-menu-item json is-active" role="presentation"><span class="devtools-tab-line"></span></li></ul></nav></div></div><span class="devtools-tab-line"></span><span class="devtools-tab-line"></span><div id="json-panel" style="visibility: visible; height: 100%;" class="tab-panel-box" role="tabpanel" aria-labelledby="json-tab"><div class="tab-panel json"><div class="jsonPanelBox tab-panel-inner"><div class="toolbar"></div></div></div></div><div id="json-panel" style="visibility: visible; height: 100%;" class="tab-panel-box" role="tabpanel" aria-labelledby="json-tab"><div class="tab-panel json"><div class="jsonPanelBox tab-panel-inner"><div class="toolbar"><div class="devtools-separator"></div><div class="devtools-searchbox"><input class="searchBox devtools-filterinput" placeholder="Filter JSON" value=""></div></div><div class="panelContent" id="json-scrolling-panel" tabindex="0">

  |  
-- | --
abbreviation | "GMT"
client_ip | "2.15.36.204"
datetime | "2023-01-17T15:27:05.573781+00:00"
day_of_week | 2
day_of_year | 17
dst | false
dst_from | null
dst_offset | 0
dst_until | null
raw_offset | 0
timezone | "Europe/London"
unixtime | 1673969225
utc_datetime | "2023-01-17T15:27:05.573781+00:00"
utc_offset | "+00:00"
week_number | 3

</div></div></div></div><!--EndFragment-->
</body>
</html>

Btw, i just noticed the format of this response. Normally it should be a standart json response without any html tag, pipes etc. Did you modify the response to paste on github or this is exactly what you got?

Stuggy commented 1 year ago

I just copied from the web page. I see now that there was also a raw response tab.

I tried editing the daemon file but it created a problem. I'll have to try that one again.

Stuggy commented 1 year ago

I worked out the syntax error .and added the DNS entry. Same result.

It is the [ENC][EX] configs that don't work it seems.

K-vanc commented 1 year ago

I found a very rare and hard to reproduce bug which triggers on some very specific condition. I am working on it now and update siteconfigs (and/or maybe Tempest) for fix.

Stuggy commented 1 year ago

Ok I'll keep an eye out for an update.

K-vanc commented 1 year ago

I have uploaded patched siteconfigs to US folder. Could you please check and update?

Stuggy commented 1 year ago

Well something seems to have changed. It now seems to hang when it gets to the first [ENC][EX]. I'm leaving it in case it is still working. I had read you said about timeouts on Linux but it hasn't been a problem yet.


(1/9) Site: [ENC]thetimes.co.uk_0
Channel id: 437
Xmltv id: Sky Golf
49 shows grabbed in 17.55 seconds

(2/9) Site: mzansimagic.dstv.com_0
Channel id: 213
Xmltv id: Mzansi Bioskop | 213
67 shows grabbed in 2.46 seconds

(3/9) Site: [ENC][EX]tvguide.com[US]_0
Channel id: 9200004886
Xmltv id: [Frontier TV New York] HBO (East) - HBO

The file not found error when saving the site config seems to be because I am rerouted to the root of my web site and it is looking for tempest.php. I have tempest installed in a folder beneath root called tempest.

K-vanc commented 1 year ago

it is not hanging but working. tvguide.com using detail pages which means it is calling an individual page for each show and takes time to finish. Time challenge is being solved in first 0.1 second after run and terminates siteconfig if fails.

File not found is a typo in my source code. Some browsers/servers are able to find location despite that typo while some of them fails. I already fixed it and will be published on next Tempest version. File name is set dynamic and even if you change name of tempest.php, it still should use the correct place.

Since my server/browser are still finding the place, you may help me to test. Please search this string(it is only 1) inside tempest.php;

location.href="/

and replace with

location.href="

this should solve the problem. If not I have to dig it more..

Stuggy commented 1 year ago

It never progressed beyond the point that I posted. The guide.xml that I created did have programmes in it. It did not continue onto the next EPG source.

I'll check the typo.

K-vanc commented 1 year ago

I dont understand well, guide.xml has the shows from tvguide.com siteconfig or not?

I am testing the same version and it works, relatively slow but works on tvguide.com

image

Stuggy commented 1 year ago

The href fix worked for that one small bug.

Stuggy commented 1 year ago

It seems improved but not consistent. It didn't complete this time either but got further. Interestingly this time it didn't get any results for Frontier TV New York] HBO (East) - HBO.


(1/9) Site: [ENC]thetimes.co.uk_0
Channel id: 437
Xmltv id: Sky Golf
49 shows grabbed in 17.41 seconds

(2/9) Site: mzansimagic.dstv.com_0
Channel id: 213
Xmltv id: Mzansi Bioskop | 213
67 shows grabbed in 2.37 seconds

(3/9) Site: [ENC][EX]tvguide.com[US]_0
Channel id: 9200004886
Xmltv id: [Frontier TV New York] HBO (East) - HBO
No show grabbed in 0.08 seconds

(4/9) Site: [ENC][EX]tvpassport.com_0
Channel id: 1766
Xmltv id: [Broadcast - New York, NY] CBS (WCBS) New York, NY (2-1)
No show grabbed in 0.07 seconds

(5/9) Site: [ENC][EX]tvtv.us_0
Channel id: 11867
Xmltv id: [Charter Spectrum Southern Manhattan - New York] TBS
92 shows grabbed in 33.84 seconds

(6/9) Site: [ENC][EX]ontvtonight.com[US]_0
Channel id: 9610663133/wcbs-fave-tv
Xmltv id: [Antenna - Broadcast TV New York] WCBS Fave TV
K-vanc commented 1 year ago

it is working but this time problem with your docker container. It already grabbed from tvtv.us and if it can decode 1 of them, it can decode all of them. if you check tvpassport and tvguide.com return times, they are 0.08 and 0.07 seconds which means they cannot connect to time server or connected but result failed on time challenge. As I said, I dont know about Docket but it has any time setup which may be different from your system time? Also is it possible to try with another dns server with restarted container?

Stuggy commented 1 year ago

OK I will trouble shoot. At least there is some life now.

K-vanc commented 1 year ago

Thanks. I am also collecting information about docker in that way :)

Stuggy commented 1 year ago

Some grabs at different times. A bit random although some work better than others.

[ENC]thetimes.co.uk_0 | 49 | 49 | 45 -- | -- | -- | -- mzansimagic.dstv.com_0 | 68 | 68 | 75 [ENC][EX]tvguide.com[US]_0 | 41 | 0 | 0 [ENC][EX]tvpassport.com_0 | 0 | 97 | 94 [ENC][EX]tvtv.us_0 | 92 | 0 | 0 [ENC][EX]ontvtonight.com[US]_0 | 0 | 126 | 0 [ENC][EX]ontvtonight.com[US]_0 | 0 | 44 | 0 [ENC][EX]tvguide.com[US]_0 | 46 | 0 | 0 [ENC]denverpost.com_0 | 53 | 53 | 40
K-vanc commented 1 year ago

Interesting. Some is always working while some of them working whenever they want.. Now I can confirm the bug I previously mentioned is cleared but seems like an another issue. The time server I used is sometimes being inaccessible for some places, in order to be more clear for some ip ranges because different people from same country are receiving different results time by time.. I was planning to make an alternative for it today and ask some users to test but unfortunately my pc's power inlet burned out this morning (2nd time since 1st of Jan) so i am waiting service to repair and hoping no damage on main board/storage..

K-vanc commented 1 year ago

I am still waiting news from my pc and didnt make any setup on my temporary pc since i dont know how long i will use it but able to understand what is the problem and why giving different results time by time. The time server, i used is a free api mostly for development and testing purpose and has a black listing feature for fair usage. Normally, my time challenge works only once for each [ENC][EX] siteconfig and verifies all other channels belong to it. So if you select 1000 channel from same [ENC][EX] siteconfig, it will make only 1 check for all 1000 channels during grabbing but if you select 1 channel from several [ENC][EX] siteconfigs are run again and again for testing purpose, you will make several requests in a short time and api will temporarily blacklist you. This is the reason of getting different results on each try while some users are never experiencing such issue. Situation getting worse with vpn usage since they are common ips and maybe already blocked by some other person(non Tempest usage). So basicly, i will make some modifications on [ENC][EX] siteconfigs when I get back my pc and hoping it will close the issue once for all

Stuggy commented 1 year ago

Ah OK that makes sense. Will continue to watch the thread.

K-vanc commented 1 year ago

Ok, I am partially back. So I need some volunteers( @Stuggy ) to test a new siteconfig. Now, I syncronized Tempest with atomic clock and added my hand made load balancer. I think it will solve that temporary banning issue forever. You can test again and again till confirm it is absolutely working without an issue then I will start upgrading all other [ENC][EX] siteconfigs.

https://github.com/K-vanc/Tempest-EPG-Generator/blob/main/Siteconfigs/USA/%5BENC%5D%5BEX%5Dtvguide.com%5BUS%5D_99.siteconfig.php

Stuggy commented 1 year ago

I'm away for a week. I will check when I get back.

K-vanc commented 1 year ago

Hi. No issue, I will start upgrading siteconfigs so it will be a live testing for all. I heavily debugged/tested and couldn't find a problem so I am pretty confident about results.

K-vanc commented 1 year ago

OK, I updated all [ENC][EX] siteconfigs with new solution. Also updated some other siteconfigs that I observed problems. Waiting for feedback from any [ENC][EX] siteconfigs users. In addition, (I am not %100 sure and cannot guarantee anything but) maybe this new solution can solve some problems of unofficial android php server users on [ENC][EX] siteconfigs at their own risk since I am not giving any official support for unofficial android php servers

Stuggy commented 1 year ago

The update is much better. I got data from all 9 of the test files. One did give an error but seemed to get data:


(5/9) Site: [ENC][EX]tvtv.us_0
Channel id: 11867
Xmltv id: [Charter Spectrum Southern Manhattan - New York] TBS
224 shows grabbed in 61.55 seconds
Request Error(url1): Operation timed out after 5000 milliseconds with 0 bytes received

You can mark this closed if you want.

K-vanc commented 1 year ago

Hi. Thanks for the feedback. Based on all others feedbacks I received, i can definetly say [ENC][EX] siteconfigs are not having issue anymore for anyone. That error is not related with time challenge or Tempest itself. It is a curl error between your connection and website. After request completion, your pc awaits for a completed message but sometimes website's server is not sending that response within timeout range and curl complains about connection status. It is not a problem for most of the times. Anyway, i am closing issue since the author confirms as well. Thanks everyone for the valuable feedbacks