python winpdb远程调试
1.使用rpdb2.start_embedded_debugger ,注意要将参数fAllowRemote 设置为True
2.winpdb前端GUI使用python2
3.rpdb兼容python2,3
def start_embedded_debugger(
pwd,
fAllowUnencrypted = True,
fAllowRemote = False,
timeout = TIMEOUT_FIVE_MINUTES,
fDebug = False
): """
Use 'start_embedded_debugger' to invoke the debugger engine in embedded
scripts. put the following line as the first line in your script: import rpdb2; rpdb2.start_embedded_debugger(pwd) This will cause the script to freeze until a debugger console attaches. pwd - The password that governs security of client/server communication
fAllowUnencrypted - Allow unencrypted communications. Communication will
be authenticated but encrypted only if possible.
fAllowRemote - Allow debugger consoles from remote machines to connect.
timeout - Seconds to wait for attachment before giving up. If None,
never give up. Once the timeout period expires, the debuggee will
resume execution.
fDebug - debug output. IMPORTNAT SECURITY NOTE:
USING A HARDCODED PASSWORD MAY BE UNSECURE SINCE ANYONE WITH READ
PERMISSION TO THE SCRIPT WILL BE ABLE TO READ THE PASSWORD AND CONNECT TO
THE DEBUGGER AND DO WHATEVER THEY WISH VIA THE 'EXEC' DEBUGGER COMMAND. It is safer to use: start_embedded_debugger_interactive_password()
""" return __start_embedded_debugger(
pwd,
fAllowUnencrypted,
fAllowRemote,
timeout,
fDebug
) def start_embedded_debugger_interactive_password(
fAllowUnencrypted = True,
fAllowRemote = False,
timeout = TIMEOUT_FIVE_MINUTES,
fDebug = False,
stdin = sys.stdin,
stdout = sys.stdout
): if g_server is not None:
return if stdout is not None:
stdout.write('Please type password:') pwd = stdin.readline().rstrip('n') return __start_embedded_debugger(
pwd,
fAllowUnencrypted,
fAllowRemote,
timeout,
fDebug
)
参考:
1.https://segmentfault.com/a/1190000000356018
2.http://winpdb.org/docs/embedded-debugging/
python winpdb远程调试的更多相关文章
- python的远程调试(使用pycharm)
测试环境描述1:c++调用python,操作系统环境是linux 2:pycharm安装在windows 安装步骤 1:把pycharm-debug.egg上传到linux上面. 2:使用easy_i ...
- visual studio 2015使用python tools远程调试maya 2016
步骤: 1. 去https://apps.exchange.autodesk.com/MAYA/en/Home/Index搜索Developer Kit并下载,maya 2016可以直接点击这里下载. ...
- Python安装远程调试Android需要的扩展脚本
http://android-scripting.googlecode.com/hg/python/ase/android.py 拷贝到/Python27/Lib/site-packages这个目录下 ...
- 使用pycharm远程调试python代码
使用 pycharm 进行 python 代码远程调试 pycharm 的远程调试是从远程机器连接到本地机器,需要在远程机器的py文件中指定本地机器的IP和端口. 远程机器上,通过easy_insta ...
- 最简单方法远程调试Python多进程子程序
Python 2.6新增的multiprocessing,即多进程,给子进程代码调试有点困难,比如python自带的pdb如果直接在子进程代码里面启动会抛出一堆异常,原因是子进程的stdin/out/ ...
- 在ubunut下使用pycharm和eclipse进行python远程调试
我比较喜欢Pycharm,因为这个是JetBrains公司出的python IDE工具,该公司下的java IDE工具--IDEA,无论从界面还是操作上都甩eclipse几条街,但项目组里有些人使用e ...
- 利用PyCharm进行Python远程调试
背景描述 有时候Python应用的代码在本地开发环境运行十分正常,但是放到线上以后却出现了莫名其妙的异常,经过再三排查以后还是找不到问题原因,于是就在想,要是可以在服务器环境中进行单步跟踪调试就好了. ...
- 第四百零三节,python网站在线支付,支付宝接口集成与远程调试,
第四百零三节,python网站在线支付,支付宝接口集成与远程调试, windows系统安装Python虚拟环境 首先保证你的系统已经安装好了Python 安装virtualenv C:\WINDOWS ...
- 使用IntelliJ IDEA进行Python远程调试的需求(未完)
使用IntelliJ IDEA进行Python远程调试的需求(未完) 在研究深度学习Machlearning时,有时候需要借助ubuntu搭建的tensorflow环境,另外也有越来越多的运算程序只能 ...
随机推荐
- ionic 一些常见问题和命令
最近项目需要用到ionic就马上去撸,但是做下来发现官方文档的native插件,按照文档来做也遇到很多坑或者暂时想不出办法实现的. ionic这种属于跨平台的开发,是适用于比较常见通用的平台,安卓机, ...
- Ubuntu18.4中Apache在加不同端口的虚拟主机
1.添加监听端口 sudo vim /etc/apache2/ports.conf Listen 80 Listen 6080 <IfModule ssl_module> ...
- Jenkins 利用Dashboard View插件管理任务视图
利用Dashboard View插件管理任务视图 by:授客 QQ:1033553122 步骤 1. 安装Dashboard View插件 说明: 如果无法在线安装,可以选择本地上传方式安装 附 ...
- Cookie的HttpOnly、secure、domain属性
Cookie主要属性 Cookie主要属性: path domain max-age expires:是expires的补充,现阶段有兼容性问题:IE低版本不支持,所以一般不单独使用 secure h ...
- LeetCode题解之Second Minimum Node In a Binary Tree
1.题目描述 2.问题分析 使用set. 3.代码 set<int> s; int findSecondMinimumValue(TreeNode* root) { dfs(root); ...
- Intel P4 CPU
1. P4 CPU 结构 奔4处理器是Intel的经典之作,它是采用乱序执行内核的超标量处理器.P4采用的微架构称为 Net Burst,基本结构如下: 奔4处理器微架构被分成了4大部分: (1)存储 ...
- 如何轻松搞定 笔记本搜不到WIFI信号问题
经常用电脑的同志肯定遇到过:一开机,发现右下角网络图标有个×号,wifi信号也搜不到:或者其他wifi信号能搜到,唯独自家的搜不到,是不是感觉很绝望啊,居然被wifi欺负到身上了,这也太憋屈了吧. 此 ...
- <!DOCTYPE>标签与table高度100% (转)
<!DOCTYPE>标签可声明三种DTD类型,分别表示严格版本.过渡版本以及基于框架的 HTML 文档. 三种HTML文档类型: HTML 4.01 规定了三种文档类型:Strict.Tr ...
- emacs org-mode文件转html文件
Table of Contents 1. 发布站点 by emacs org-mode 1.1 org-mode 自带的导出方法 1.2 批量导出 1.3 css 美化 1.4 导出html 1. 发 ...
- 使用Gitkraken进行其他Git操作
使用Gitkraken进行其他Git操作 查看某次 commit 的文件改动 使用 Gitkraken 能非常方便的看到任意一次的 commit 对项目文件的改动. 具体操作是:在树状分支图上单击某个 ...