OMDB API Unstable?
#1
I am playing around with the omdb api and i find that only 1 out of 10 request actually comeback usable. All request status_codes are 200 so i know the url is correct. Has anyone else experienced this as I would like to use the api but I want it be reliable. I have not donated yet, may that be the reason?
Shield TV | Windows 10 | Mariadb | Mii Box
Evolve Ecosystem Repo | TV Melodies | Madnox Holiday Mod
Reply
#2
It's working quite well, but sometimes the server aren't responding correctly. 

As workaround I've placed it in a loop with a timeout of 5s and 3 retries.


for i in range(1,4): # loop if heavy server load
            log('OMDb call try %s/3' % str(i), force=RATING_DEBUG)
            try:
                request = requests.get(url, timeout=5)
                if not str(request.status_code).startswith('5'):
                    break

            except Exception:
                if i < 3:
                    xbmc.sleep(500)
                else:
                    log(error_msg + '408', WARNING)
                    return
Main: Lancool II Mesh  - Ryzen 9 5900x - MSI x570 Unify - Zotac RTX 3080 AMP HOLO - 32GB Trident Z Neo 3600 CL16 -  EVO 960 M.2 250GB / EVO 940 250GB / MX100 512GB /  Crucial P1 2TB / WD Blue 3D Nand 2TB 
Sound: Saxx AS30 DSP - Beyer Dynamic Custom One Pro 
TV: Nvidia Shield 2019 Pro- Adalight 114x LEDs - Sony 65XG9505 - Kodi / Emby - Yamaha RX-V683 - Heco Victa 700/101/251a + Dynavoice Magic FX-4
Server: i3 Skylake - 8GB - OMV4 - 22TB Storage
Reply
#3
(2020-01-14, 19:02)sualfred Wrote: It's working quite well, but sometimes the server aren't responding correctly. 

As workaround I've placed it in a loop with a timeout of 5s and 3 retries.


for i in range(1,4): # loop if heavy server load
            log('OMDb call try %s/3' % str(i), force=RATING_DEBUG)
            try:
                request = requests.get(url, timeout=5)
                if not str(request.status_code).startswith('5'):
                    break

            except Exception:
                if i < 3:
                    xbmc.sleep(500)
                else:
                    log(error_msg + '408', WARNING)
                    return
Thanks had not even though about this.
Shield TV | Windows 10 | Mariadb | Mii Box
Evolve Ecosystem Repo | TV Melodies | Madnox Holiday Mod
Reply
#4
Working also quite well on my side. I just mentioned the awards tag isn't updated for plenty of movies since 2018. Some data filled, some not. Before 2018 in almost every case filled.
Also in summer and autumn 2019 the tomatometerallaudience wasn't responding data for a long time on really a lot of movies. But it's all fine again now. In most cases ratings votes are equal to the websites from original source.
I really hope Letterboxd ratings votes will find it's way into OMDB cause the API is out now and Letterboxd is getting from day to day more popular.
Reply
#5
(2020-01-31, 23:55)chrissix Wrote: Working also quite well on my side. I just mentioned the awards tag isn't updated for plenty of movies since 2018. Some data filled, some not. Before 2018 in almost every case filled.
Also in summer and autumn 2019 the tomatometerallaudience wasn't responding data for a long time on really a lot of movies. But it's all fine again now. In most cases ratings votes are equal to the websites from original source.
I really hope Letterboxd ratings votes will find it's way into OMDB cause the API is out now and Letterboxd is getting from day to day more popular.
I really like letterboxd, I hope it is added soon...
Reply



Logout Mark Read Team Forum Stats Members Help
OMDB API Unstable?0
This forum uses Lukasz Tkacz MyBB addons.