[nvda-addons] Re: How do I debug a global plugin?

  • From: "Pranav Lal" <pranav.lal@xxxxxxxxx>
  • To: <nvda-addons@xxxxxxxxxxxxx>
  • Date: Sun, 19 Jul 2015 00:14:17 +0530

Hi Joseph,
<snip You cannot debug an add-on code from a mainstream IDE such as Eclipse
because the IDE cannot find some modules (you need to add the path for NVDA core
modules manually). To debug an add-on, you may need to run NVDA with the add-on
loaded, then using logs, print statements or tones (I usually use the latter
two).
PL] That is exactly what I am doing.

Pranav
-----Original Message-----
From: nvda-addons-bounce@xxxxxxxxxxxxx
[mailto:nvda-addons-bounce@xxxxxxxxxxxxx] On Behalf Of Joseph Lee
Sent: Saturday, July 18, 2015 9:48 PM
To: nvda-addons@xxxxxxxxxxxxx
Subject: [nvda-addons] Re: How do I debug a global plugin?

Hi,
You cannot debug an add-on code from a mainstream IDE such as Eclipse because
the IDE cannot find some modules (you need to add the path for NVDA core
modules manually). To debug an add-on, you may need to run NVDA with the add-on
loaded, then using logs, print statements or tones (I usually use the latter
two).
Cheers,
Joseph

-----Original Message-----
From: nvda-addons-bounce@xxxxxxxxxxxxx
[mailto:nvda-addons-bounce@xxxxxxxxxxxxx] On Behalf Of Zahari Yurukov
Sent: Saturday, July 18, 2015 8:44 AM
To: nvda-addons@xxxxxxxxxxxxx
Subject: [nvda-addons] Re: How do I debug a global plugin?

Hi,
what is the error then - it should be present in the NVDA's log file.
What is your logging level in NVDA's General Settings? If it's something less
than debug - that should explain why you don't see your debug messages, or the
execution doesn't get to them at all.
Indeed, there is a python debugger - pdb, but I've never used it.
I never heard of pyScripter - is it accessible? If you're not satisfied with it
- try Eclipse with the pydev extention, though have in mind that to navigate in
it you would need to familiarize yourself with its keyboard shortcuts first.
However, using a simple editor like Notepad++ and logging stuff should be
enough - that's what most people here do.

Best wishes,
Zahari

На 18.07.2015 в 17:54, Pranav Lal написа:

Hi Zahari,

I did what the guide said. The file is being compiled and I get an error if
there is a compiler error with the file.

Anyhow, I'll continue troubleshooting.

Pranav

-----Original Message-----
From: nvda-addons-bounce@xxxxxxxxxxxxx
[mailto:nvda-addons-bounce@xxxxxxxxxxxxx] On Behalf Of Zahari Yurukov
Sent: Saturday, July 18, 2015 6:30 PM
To: nvda-addons@xxxxxxxxxxxxx
Subject: [nvda-addons] Re: How do I debug a global plugin?

Hi,
probably your script is not loaded at all. Look at NVDA's Developer guide how
you should declare a global plugin and check your code again:
http://www.nvaccess.org/files/nvda/documentation/developerGuide.html#t
oc14

hth,
Zahari

На 18.07.2015 в 15:02, Pranav Lal написа:
Hi all,

I am trying to write a basic global plugin. How do I debug it? Yes, I
can add log statements and send output to nvda's log.. However, in my
current code, that too is failing without an error. Is there a way
for me to load the script into an IDE like pyScripter and debug?

Pranav

----------------------------------------------------------------
NVDA add-ons: A list to discuss add-on code enhancements and for reporting
bugs.

Community addons are available from: http://addons.nvda-project.org
To send a message to the list: nvda-addons@xxxxxxxxxxxxx To change
your list settings/unsubscribe:
//www.freelists.org/list/nvda-addons
To contact list moderators: nvda-addons-moderators@xxxxxxxxxxxxx

----------------------------------------------------------------
NVDA add-ons: A list to discuss add-on code enhancements and for reporting
bugs.

Community addons are available from: http://addons.nvda-project.org To
send a message to the list: nvda-addons@xxxxxxxxxxxxx To change your
list settings/unsubscribe: //www.freelists.org/list/nvda-addons
To contact list moderators: nvda-addons-moderators@xxxxxxxxxxxxx

----------------------------------------------------------------
NVDA add-ons: A list to discuss add-on code enhancements and for reporting
bugs.

Community addons are available from: http://addons.nvda-project.org To
send a message to the list: nvda-addons@xxxxxxxxxxxxx To change your
list settings/unsubscribe: //www.freelists.org/list/nvda-addons
To contact list moderators: nvda-addons-moderators@xxxxxxxxxxxxx

----------------------------------------------------------------
NVDA add-ons: A list to discuss add-on code enhancements and for reporting
bugs.

Community addons are available from: http://addons.nvda-project.org To send a
message to the list: nvda-addons@xxxxxxxxxxxxx To change your list
settings/unsubscribe: //www.freelists.org/list/nvda-addons
To contact list moderators: nvda-addons-moderators@xxxxxxxxxxxxx

----------------------------------------------------------------
NVDA add-ons: A list to discuss add-on code enhancements and for reporting
bugs.

Community addons are available from: http://addons.nvda-project.org To send a
message to the list: nvda-addons@xxxxxxxxxxxxx To change your list
settings/unsubscribe: //www.freelists.org/list/nvda-addons
To contact list moderators: nvda-addons-moderators@xxxxxxxxxxxxx

----------------------------------------------------------------
NVDA add-ons: A list to discuss add-on code enhancements and for reporting bugs.

Community addons are available from: http://addons.nvda-project.org
To send a message to the list: nvda-addons@xxxxxxxxxxxxx
To change your list settings/unsubscribe:
//www.freelists.org/list/nvda-addons
To contact list moderators: nvda-addons-moderators@xxxxxxxxxxxxx

Other related posts: