09 2017 档案

python获取自己的环境变量
摘要:1. import sys sys.path 2. from distutils.sysconfig import get_python_lib get_python_lib() 3. import os os.__file__ 4. import sys sys.executable 阅读全文

posted @ 2017-09-27 13:31 帅胡 阅读(369) 评论(0) 推荐(0)

Redis问题MISCONF Redis is configured to save RDB snapshots....
摘要:Redis问题MISCONF Redis is configured to save RDB snapshots, but is currently not able to persist on disk. Commands that may modify the data set are disa 阅读全文

posted @ 2017-09-25 12:28 帅胡 阅读(172) 评论(0) 推荐(0)

python的traceback模块
摘要:输出结果是 Traceback (most recent call last): 输出结果是 Traceback (most recent call last): File "test_traceback.py", line 3, in <module> File "test_traceback.p 阅读全文

posted @ 2017-09-25 10:53 帅胡 阅读(3653) 评论(0) 推荐(0)

浅析Python中的struct模块
摘要:最近在学习python网络编程这一块,在写简单的socket通信代码时,遇到了struct这个模块的使用,当时不太清楚这到底有和作用,后来查阅了相关资料大概了解了,在这里做一下简单的总结。 了解c语言的人,一定会知道struct结构体在c语言中的作用,它定义了一种结构,里面包含不同类型的数据(int 阅读全文

posted @ 2017-09-19 16:20 帅胡 阅读(231) 评论(0) 推荐(0)

python binascii模块详解
摘要:['Error', 'Incomplete', 'b2a_hex', 'hexlify' #Hexadecimal representation of binary data. 字符串转16进制'a2b_hex', 'unhexlify', #Binary data of hexadecimal r 阅读全文

posted @ 2017-09-19 15:37 帅胡 阅读(12881) 评论(0) 推荐(0)

python 3使用binascii方法的报错解决
摘要:环境是python 3 问题: 使用binascii方法一直出现报错TypeError: a bytes-like object is required, not 'str' 解决方法: 后来修改如下代码才会不报错 原理: 在新版本的python3中,取消了unicode类型,代替它的是使用unic 阅读全文

posted @ 2017-09-19 15:37 帅胡 阅读(1741) 评论(0) 推荐(0)

python2.7 安装pypcap出错 pcap.h not found
摘要:python安装pypcap的时候出错 通过不断百度+google找到解决方案 https://segmentfault.com/q/1010000007273835/a-1020000007275642 首先下载sdk开发包,http://www.winpcap.org/archive/,我下的是 阅读全文

posted @ 2017-09-16 23:13 帅胡 阅读(1208) 评论(0) 推荐(0)

清除远程桌面访问痕迹
摘要:1.开始 运行 输入 regedit 命令可以打开注册表,如下图 2.找到注册表里面的 HKEY_CURRENT_USER\Software\Microsoft\Terminal Server Client\Default 其中右边的就是,你连接过的记录了。删除您需要清除的文件即可 2.找到注册表里 阅读全文

posted @ 2017-09-13 20:52 帅胡 阅读(219) 评论(0) 推荐(0)

Python使用SSL方式发送QQ邮箱
摘要:1 #coding:utf-8 2 import smtplib 3 from email.mime.text import MIMEText 4 from email.header import Header 5 6 # 第三方 SMTP 服务 7 mail_host="smtp.qq.com" #设置服务器 8 mail_user="******@qq.com" #... 阅读全文

posted @ 2017-09-02 20:42 帅胡 阅读(273) 评论(0) 推荐(0)

导航