JustWatch Class can not be instantiated raises typeError
This has something to do with when trying to set the country
Traceback (most recent call last): File "<stdin>", line 1, in <module> , in __init__ self.locale = self.set_locale() , in set_locale if result['iso_3166_2'] == self.country or \ TypeError: string indices must be integers
Facing similar issue, any help would be appreciated! @ashgazer any resolution on this?
Same experience here. First noticed on Sep 9. The behavior is the same whether a country value is provided or not.
`>>> just_watch = JustWatch()
Traceback (most recent call last):
File "
TypeError: string indices must be integers
`
`>>> just_watch = JustWatch(country='US')
Traceback (most recent call last):
File "
TypeError: string indices must be integers
`
Justwatch site is still functioning, is it like public use is restricted now?
Justwatch site is still functioning, is it like public use is restricted now?
It's entirely possible. When I first found this repository, JW didn't have this page and now they do. https://www.justwatch.com/ca/JustWatch-Streaming-API
Ohh, could be. I didn't find any good alternative as well.
On Fri, Sep 11, 2020, 9:17 PM dreondre [email protected] wrote:
Justwatch site is still functioning, is it like public use is restricted now?
It's entirely possible. When I first found this repository, JW didn't have this page and now they do. https://www.justwatch.com/ca/JustWatch-Streaming-API
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/dawoudt/JustWatchAPI/issues/47#issuecomment-691172816, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIFUXF3ZNR5C6S4VBGR4MOLSFJBAZANCNFSM4Q632EVA .
Looks like an change from their side.
curl "https://apis.justwatch.com/content/locales/state" or opening the url in the browser works just fine
curl "https://apis.justwatch.com/content/locales/state" --user-agent 'JustWatch Python client (github.com/dawoudt/JustWatchAPI)' only returns a empty object
FYI:
curl "https://apis.justwatch.com/content/locales/state" --user-agent 'JustWatch client (github.com/dawoudt/JustWatchAPI)' works so this might not have been targeted at this lib on purpose
thanks for @chkuendig's idea using that i made a temp solution. but its not best.
from justwatch import JustWatch, justwatchapi
justwatchapi.__dict__['HEADER'] = {
'User-Agent': 'JustWatch client (github.com/dawoudt/JustWatchAPI)'}
just_watch = JustWatch()
@venkibale @rking32 I created a pull request for changing the user agent. Hopefully this gets merged soon.
https://github.com/dawoudt/JustWatchAPI/pull/48