如何把 KFX 格式转换成 MOBI 等其它电子书格式

同步到 Kindle 设备中的 KFX 文件,绝大多数都带有 DRM 保护,而且目前也没有针对 KFX 格式比较成熟的 DRM 去除方案。此外还有一个值得注意的问题,就是同步到的 Kindle 的电子书,其内容中的图片和文字会被分离,也就是说,直接从 Kindle 设备中拷贝出来的 KFX 其实是不完整的。最关键的是,从实际使用情况来看,KFX Output 和 KFX Input 这两款 Calibre 插件并不怎么好用,经常会出错。

阅读更多

AttributeError: module ‘requests’ has no attribute ‘get’

爬虫学习时遇到这个报错,因为在教学系统的练习界面里面程序没有问题,但是复制到本机的VSCode里却出现了这个提示。Google搜索了一下,大部分人是因为将自己的练习文件命名为requests.py,导致真正的requests模块调用有误。

但是我的文件并不是命名为request,后来发现因为是查看HTTP响应代码而把文件命名为http.py,没想到也导致了同样的问题。后来改成h.py就好了……

阅读更多

简单是 Python 编程的第一要则

本文是 Python 之禅特别系列的第二篇,我们将要关注其中第三与第四条原则:简单与复杂。 ——Moshe Zadka1)Moshe has been involved in the Linux community since 1998, helping in Linux “installation parties”. He has been programming Python since 1999, and has contributed to the core Python interpreter. Moshe has been a DevOps/SRE since before those terms existed, caring deeply about software reliability, build reproducibility and other such things. He has worked in companies as small as three people and as big as tens of thousands — usually some place around where software meets system administration.

阅读更多

References   [ + ]

1.Moshe has been involved in the Linux community since 1998, helping in Linux “installation parties”. He has been programming Python since 1999, and has contributed to the core Python interpreter. Moshe has been a DevOps/SRE since before those terms existed, caring deeply about software reliability, build reproducibility and other such things. He has worked in companies as small as three people and as big as tens of thousands — usually some place around where software meets system administration.

YouTube视频下载

YouTube视频保存下来是便于离线以及在不同设备播放的一种便利方式,但是因为很多「搬运工」也会将YouTube上的视频搬到别的平台,譬如从墙外到墙内,YouTube也不断采用各种方法来避免视频被轻易下载。当然,任何视频只要公开播放,都难逃被录屏的命运,无论是电脑上的录屏软件还是移动设备上的录屏功能,都可以实现把视频录制下来的功能。

阅读更多

Virus hunters

Meet the scientists searching for Disease X

From Ebola to swine flu to HIV/Aids, viruses borne by animals have caused some of the most devastating epidemics in history. What will come next? In Sierra Leone, Joe Shute joins the scientists working to find Disease X – a virus that is as yet undiscovered, but which could have the potential to ravage populations. Photographs by Simon Townsley

The caves surrounding the village of Gbentu in northern Sierra Leone are held sacred in local culture. Kings have been laid to rest here, and tributes stowed deep within the crevasses. For centuries, in times of death or crisis, tribal elders have tramped through the jungle to hold secret rituals in the darkness.

阅读更多