- 博客(4)
- 收藏
- 关注
原创 module ‘__main__‘ has no attribute ‘__file__‘
module ‘main’ has no attribute 'file’问题的解决导入您的时发生问题settings.INSTALLED_APPS:for app in settings.INSTALLED_APPS:try:mod = import_module(app)except ImportError as e:raise ImproperlyConfigured(‘ImportError %s: %s’ % (app, e.args[0]))template_dir = os.pa
2020-12-14 15:27:20
1239
原创 Cookie获取、保存与读取
为什么要使用Cookie呢?Cookie,指某些网站为了辨别用户身份、进行session跟踪而储存在用户本地终端上的数据(通常经过加密)比如说有些网站需要登录后才能访问某个页面,在登录之前,你想抓取某个页面内容是不允许的。那么我们可以利用Urllib库保存我们登录的Cookie,然后再抓取其他页面就达到目的了。1|11.1 Opener当你获取一个URL你使用一个opener(一个urllib.OpenerDirector的实例)。在前面,我们都是使用的默认的opener,也就是urlopen。它是
2020-12-13 10:24:53
1612
原创 安装ipywidgets
InstallationUsers can install the current version of ipywidgets with pip or conda.With pippip install ipywidgetsjupyter nbextension enable --py widgetsnbextensionWhen using virtualenv and working in an activated virtual environment, the --sys-prefix o
2020-12-08 10:20:30
2752
原创 python3.7 安装contextily
python3.7 安装contextilypython3.7 安装contextilyAnaconda添加 国内镜像源1、清华conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forgeconda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2conda conf
2020-12-07 14:38:58
1331
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人
RSS订阅