jachinlin / geektime_dl

把极客时间装进 Kindle
https://jachinlin.github.io/geektime_dl
1.37k stars 354 forks source link

使用 Docker 下载课程失败 #31

Closed skhe closed 5 years ago

skhe commented 5 years ago

日志如下:

───────┬─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
       │ File: geektime.log
───────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
   1   │ log_time=2019-05-21 14:24:19,620    levelname=ERROR process=1   exception=Traceback (most recent call last):
   2   │   File "/usr/local/lib/python3.7/site-packages/geektime_dl/cli/command.py", line 63, in main
   3   │     o.work(args)
   4   │   File "/usr/local/lib/python3.7/site-packages/geektime_dl/cli/command.py", line 26, in work
   5   │     return self.run(args)
   6   │   File "/usr/local/lib/python3.7/site-packages/geektime_dl/cli/mp3.py", line 83, in run
   7   │     super(Mp3Batch, self).run([cid.strip()] + args)
   8   │   File "/usr/local/lib/python3.7/site-packages/geektime_dl/cli/mp3.py", line 45, in run
   9   │     data = dc.get_course_content(course_id)
  10   │   File "/usr/local/lib/python3.7/site-packages/geektime_dl/data_client/__init__.py", line 59, in get_course_content
  11   │     post_detail = self.get_post_content(post['id'], force=force)
  12   │   File "/usr/local/lib/python3.7/site-packages/geektime_dl/data_client/__init__.py", line 36, in get_post_content
  13   │     data = self._gk.get_post_content(post_id)
  14   │   File "/usr/local/lib/python3.7/site-packages/geektime_dl/utils/__init__.py", line 36, in wrapper
  15   │     result = func(*args, **kwargs)
  16   │   File "/usr/local/lib/python3.7/site-packages/geektime_dl/data_client/gk_apis.py", line 126, in get_post_content
  17   │     raise Exception('course query fail:' + resp.json()['error']['msg'])
  18   │   File "/usr/local/lib/python3.7/site-packages/requests/models.py", line 897, in json
  19   │     return complexjson.loads(self.text, **kwargs)
  20   │   File "/usr/local/lib/python3.7/json/__init__.py", line 348, in loads
  21   │     return _default_decoder.decode(s)
  22   │   File "/usr/local/lib/python3.7/json/decoder.py", line 337, in decode
  23   │     obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  24   │   File "/usr/local/lib/python3.7/json/decoder.py", line 355, in raw_decode
  25   │     raise JSONDecodeError("Expecting value", s, err.value) from None
  26   │ json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
  27   │     location=/usr/local/lib/python3.7/site-packages/geektime_dl/cli/command.py:74
  28   │
  29   │ log_time=2019-05-21 14:32:15,111    levelname=ERROR process=1   exception=Traceback (most recent call last):
  30   │   File "/usr/local/lib/python3.7/site-packages/geektime_dl/cli/command.py", line 63, in main
  31   │     o.work(args)
  32   │   File "/usr/local/lib/python3.7/site-packages/geektime_dl/cli/command.py", line 26, in work
  33   │     return self.run(args)
  34   │   File "/usr/local/lib/python3.7/site-packages/geektime_dl/cli/mp3.py", line 83, in run
  35   │     super(Mp3Batch, self).run([cid.strip()] + args)
  36   │   File "/usr/local/lib/python3.7/site-packages/geektime_dl/cli/mp3.py", line 45, in run
  37   │     data = dc.get_course_content(course_id)
  38   │   File "/usr/local/lib/python3.7/site-packages/geektime_dl/data_client/__init__.py", line 59, in get_course_content
  39   │     post_detail = self.get_post_content(post['id'], force=force)
  40   │   File "/usr/local/lib/python3.7/site-packages/geektime_dl/data_client/__init__.py", line 36, in get_post_content
  41   │     data = self._gk.get_post_content(post_id)
  42   │   File "/usr/local/lib/python3.7/site-packages/geektime_dl/utils/__init__.py", line 36, in wrapper
  43   │     result = func(*args, **kwargs)
  44   │   File "/usr/local/lib/python3.7/site-packages/geektime_dl/data_client/gk_apis.py", line 126, in get_post_content
  45   │     raise Exception('course query fail:' + resp.json()['error']['msg'])
  46   │   File "/usr/local/lib/python3.7/site-packages/requests/models.py", line 897, in json
  47   │     return complexjson.loads(self.text, **kwargs)
  48   │   File "/usr/local/lib/python3.7/json/__init__.py", line 348, in loads
  49   │     return _default_decoder.decode(s)
  50   │   File "/usr/local/lib/python3.7/json/decoder.py", line 337, in decode
  51   │     obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  52   │   File "/usr/local/lib/python3.7/json/decoder.py", line 355, in raw_decode
  53   │     raise JSONDecodeError("Expecting value", s, err.value) from None
  54   │ json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
  55   │     location=/usr/local/lib/python3.7/site-packages/geektime_dl/cli/command.py:74
  56   │
───────┴─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
CALTyang commented 5 years ago

+1

mgcnrx11 commented 5 years ago

+1

cat geektime.log 
log_time=2019-05-27 15:07:10,938        levelname=ERROR process=1       exception=Traceback (most recent call last):
  File "/usr/local/lib/python3.7/site-packages/geektime_dl/cli/command.py", line 63, in main
    o.work(args)
  File "/usr/local/lib/python3.7/site-packages/geektime_dl/cli/command.py", line 26, in work
    return self.run(args)
  File "/usr/local/lib/python3.7/site-packages/geektime_dl/cli/ebook.py", line 109, in run
    data = dc.get_course_content(course_id, force=force)
  File "/usr/local/lib/python3.7/site-packages/geektime_dl/data_client/__init__.py", line 59, in get_course_content
    post_detail = self.get_post_content(post['id'], force=force)
  File "/usr/local/lib/python3.7/site-packages/geektime_dl/data_client/__init__.py", line 36, in get_post_content
    data = self._gk.get_post_content(post_id)
  File "/usr/local/lib/python3.7/site-packages/geektime_dl/utils/__init__.py", line 36, in wrapper
    result = func(*args, **kwargs)
  File "/usr/local/lib/python3.7/site-packages/geektime_dl/data_client/gk_apis.py", line 126, in get_post_content
    raise Exception('course query fail:' + resp.json()['error']['msg'])
  File "/usr/local/lib/python3.7/site-packages/requests/models.py", line 897, in json
    return complexjson.loads(self.text, **kwargs)
  File "/usr/local/lib/python3.7/json/__init__.py", line 348, in loads
    return _default_decoder.decode(s)
  File "/usr/local/lib/python3.7/json/decoder.py", line 337, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "/usr/local/lib/python3.7/json/decoder.py", line 355, in raw_decode
    raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
        location=/usr/local/lib/python3.7/site-packages/geektime_dl/cli/command.py:74
skhe commented 5 years ago

???