停在变量更改的行 [英] Stop at the line where a variable gets changed

查看:48
本文介绍了停在变量更改的行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试跟踪变量的更新时间。我有一个观察者,但是有什么方法可以设置它,以便在更新值时可以暂停执行?

I am trying to track down when a variable gets updated. I have a watcher, but is there any way to set it up so that the execution can be paused when the value is getting updated?

这称为观察点数据断点

推荐答案

当前pycharm没有默认的内置功能,实时跟踪变量修改。或者,您可以执行以下操作:

Currently pycharm does not have a default built-in feature that tracks variable modification in real time. Alternatively you can do this:


  1. 运行调试

  2. 从调试器窗格->变量,右键单击

  3. 在监视窗格中,右键单击该变量并选择引用对象。

我认为您正在谈论的功能称为监视点支持,根据本文的介绍:
http://sourceforge.net/blog/watchpoints-in-python/
Eric和PyScriptor具有此功能,但没有pycharm。

The feature you are talking about is, I believe, called watchpoint support and according to this article: http://sourceforge.net/blog/watchpoints-in-python/ Eric and PyScriptor has the feature but not pycharm.

这篇关于停在变量更改的行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆