I will take a look later when I'm back home.
I will check my code to figure out in what situation this error is generated. That will give me an idea what to suggest to @cyoungers.
@cyoungers it seems that one of your sources is lacking some information that my script is looking for. I'm not sure exactly what it is as it could be one of several things.
In a browser, on the same machine where OliveTin is running, please go to this URL:
192.168.0.11:8089/devices
You should see a lot of text with information about all your sources and channels.
Once this page is fully loaded, please copy the whole content and paste it into a text file.
Then please send it to me at glfbidon-cdvr@yahoo.com
It will be easier for me to troubleshoot this.
Thank you for providing the data, @cyoungers.
After reviewing your data, I immediately identified the issue: your source "EPLUS" has zero channels.
My script did not account for this scenario.
Sorry you ran into this issue and thank you for reporting this.
Thanks to you, this will be fixed in the next version of my script that I'm planning on releasing later today.
Cool. My EPLUS container stopped working awhile ago and I never got around to fixing it. Glad it uncovered this edge case I guess.
I have made changes to the script and I am in the testing phase now.
If everything goes well, I will release a new version tomorrow.
Update 5/11:
Test failed. I broke something in the code. ๐ซค
Today is a busy day and I probably won't be able to look at it until late evening, if at all.
Maybe tomorrow morning.
Version 3.2.0:
[IMPROVED] Ignore sources that have the "Lineup" field empty
[FIXED] Crash when a new source with zero channels is detected
[NEW] Detect, report, and back up removed sources (in "Deleted_Sources" subdirectory)
@bnhf please integrate in OliveTin at your convenience.
@chDVRuser sorry for the delay, this is a release that is long overdue with your requested change.
@cyoungers it should work for you now
Thanks! Works great.
Version 3.3.0
[FIXED] Two or more sources each using the same HDHomeRun device model were combined into one source.
Note: sources that use a HDHomeRun device will be reported as new sources the first time this version of the script is run. The names of their channel lineup log files will contain the device IDs to differentiate them in case they use the same HDHomeRun device model.
I really like this idea, so I'm just trying this out in command line on a Windows 11 machine. I'm trying to monitor on a different PC than the one where Channels server is located and I get the error message below.
C:> python channels_dvr_monitor_channels.py -f 15 -i 192.168.88.240
Traceback (most recent call last):
File "C:\channels_dvr_monitor_channels.py", line 62, in
import argparse, glob, os, requests, smtplib, sys, time
ModuleNotFoundError: No module named 'requests'
The "ModuleNotFoundError: No module named 'requests'" occurs when you forget to install the requests module before importing it or if you install it in an incorrect environment. To resolve this error, follow these steps:
-
Install the requests module:
- Open your terminal or command prompt.
- Navigate to your project's root directory.
- Run the following command to install the requests module:
If you're using Python 3, use:pip install requests
pip3 install requests
-
Check your Python installation:
- Make sure you have Python and pip installed.
- If pip is not in your path, you can use:
For Python 3:python -m pip install requests
python3 -m pip install requests
-
Alternative methods:
- On Linux, you can use your system's package manager:
- CentOS:
sudo yum install python-requests
- Debian/Ubuntu (Python 2):
sudo apt-get install python-requests
- Debian/Ubuntu (Python 3):
sudo apt-get install python3-requests
- CentOS:
- On Windows, use:
Or if pip is not in your path:pip install requests
python -m pip install requests
- On Linux, you can use your system's package manager:
Remember to install the requests module in the correct environment, and you should be good to go! ยนยฒยณโดโต
Source: Conversation with Copilot, 5/31/2024
(1) python - ImportError: No module named requests - Stack Overflow. python - ImportError: No module named requests - Stack Overflow.
(2) ModuleNotFoundError: No module named 'requests' in Python. ModuleNotFoundError: No module named 'requests' in Python | bobbyhadz.
(3) Solved: ModuleNotFoundError: No module named 'requests' in Python 3. Solved: ModuleNotFoundError: No module named 'requests' in Python 3 | CyberITHub.
(4) ModuleNotFoundError: no module named 'requests' [Solved in Python Django]. ModuleNotFoundError: no module named 'requests' [Solved in Python Django].
(5) python - ModuleNotFoundError: No module named 'requests' - Stack Overflow. python - ModuleNotFoundError: No module named 'requests' - Stack Overflow.
(6) undefined. PyPI ยท The Python Package Index.
(7) undefined. requests ยท PyPI.
Thank you for the quick response! Installed the module; all is running now and the number of channels in the log for each source I have is the same as what is listed in Channels settings. Thank you again.
Yes. It just did it's first update and logged correctly.
Perfect. Thank you for confirming.
And below is what I get with after reloading the Pluto source. It's looks like it's working very nicely!
Check time: 2024-05-31 09:54:47
Server version: 2024.05.26.0350
Channels DVR server URL: http://192.168.88.240:8089
Channels DVR version: 2024.05.26.0350
Pluto TV: 406 channels (+1)
(https://nocords.xyz/pluto/playlist.m3u)
<--- Lineup changes (starting at 0) --->
- 4490 : Telemundo Noticias Noreste
<--- Channel changes --->
- Telemundo Noticias Noreste (4490)
<--- Duplicated channels --->
CBS News Baltimore: 2540, 5070
CBS News Chicago: 2570, 5120
CBS News Los Angeles: 2560, 5150
CBS News New York: 2550, 5180
Pluto TV Cars: 0, 1560
Next check: 2024-05-31 10:09:47
Latest version (v3.3.0) of this script incorporated into OliveTin-for-Channels, and pushed as bnhf/olivetin:latest with all the usual OliveTin bells and whistles:
Let me know if you can figure out how to enable a start time.
I will be manually removing and adding the one server to check tomorrow.
I have it start at 11:05 and check every 12 hrs
I haven't had enough time yet to sit down and work on my code.
No rush. Just letting you know that when you do, I'll test it.