Previous Thread
Next Thread
Print Thread
APN Script error #28835 08 Mar 19 06:39 AM
Joined: Oct 2015
Posts: 230
S
Stuart Offline OP
Member
OP Offline
Member
S
Joined: Oct 2015
Posts: 230
I've had to re-install my PC and now have an error when using APN. When I try any key command, such as g, or f I get a dialog message box with the error:
Unexpected error in file: ScriptRegistry.cpp, line: 239, version: 2..4.0.14.
No ScriptRunner for this script type!

In the case of the find command, the find dialog box is then opened, but the goto command does nothing.

I have tried re-installing, re-syncing the APN repo and copying from a working installation on a different PC, all to no avail.

I suspect the problem may not be with APN, rather than something else about the installation. I have Python installed and have tried moving the order of its location within the PATH envirnoment variable, but that hasn't helped either.

Does the error message provide any clues for you for where I can look to solve this issue please?

Re: APN Script error #28836 08 Mar 19 10:25 AM
Joined: Jun 2001
Posts: 11,794
J
Jack McGregor Offline
Member
Offline
Member
J
Joined: Jun 2001
Posts: 11,794
Uh oh. This may be a preview of the kind of problem that is more and more likely to occur as civilization becomes increasingly dependent on technology that no one fully understands any more. :rolleyes: At least it's not a nuclear reactor we're talking about.

Which is a roundabout way of saying "I have no idea!" But that might be a slight exaggeration, since I can almost certainly come up with some ideas; whether they are helpful remains to be determined...

1. The ScriptRunner message certainly sounds like it doesn't think the Python connection is operational. Are you sure you have Python 2.7.x installed? (Newer versions won't work with APN.)

2. While on that subject, can we assume you followed the steps outlined on the home page of the APN Repository (as opposed to some in-house-developed recipe for setting up a new PC)?

3. What do you see on the Tools > Options > Extensions display? I have the following:

Code
CTags Tagger         1.6   Yes
Custom Scheme Lexer  2.0   Yes
pyPN                 1.0   Yes
4. When you say the Find dialog comes up, but the "goto command does nothing", do you mean the "Find Next" (on the Search dialog) button? Or the Edit > Goto command (which brings up a dialog where you enter the line number to jump to)? Neither of those seem related to the Python interface, which does suggest something deeper is broken.

I'll get out my pick axe and try to dig into the code to see if I can find some further details on that ScriptRunner error or any other clues.

Re: APN Script error #28837 08 Mar 19 10:42 AM
Joined: Oct 2015
Posts: 230
S
Stuart Offline OP
Member
OP Offline
Member
S
Joined: Oct 2015
Posts: 230
No, I didn't follow the APN installation process exactly as outlined. Skipped the Ashell part as not required, but can confirm that this has not/is not causing any issues on the other PC.

I don't see the pyPN line in the extensions, so that will most likely be the issue. However, Python2.7 is installed and in the PATh variable. I do also have Python3.7, but that appears after 2.7 in the path, so shouldn't but might be causing the issue.

I can't be sure now, but it is possible that Python was installed after APN, rather than before.

I have tried re-installing/repairing APN but that hasn't worked.

How can I add the Python Extension? Is the any manual way or do I need to uninstall and re-install?

I can also try unintalling Python3.7, at least until after APN has been set up.

Re: APN Script error #28838 08 Mar 19 10:44 AM
Joined: Oct 2015
Posts: 230
S
Stuart Offline OP
Member
OP Offline
Member
S
Joined: Oct 2015
Posts: 230
f produces the error, then the Find dialog, which then works as usual.

q or g on a variable or function name, produces the error and nothing else.

Re: APN Script error #28839 08 Mar 19 11:18 AM
Joined: Jun 2001
Posts: 11,794
J
Jack McGregor Offline
Member
Offline
Member
J
Joined: Jun 2001
Posts: 11,794
This might help: APN Search for Extensions

As a side note, you have a slightly different keyboard mapping than I do. (I have F = Find, and G = Goto, but Q is a script to toggle the commenting of the selected lines (i.e. "Scripts.ASB Block Comment Toggle").

Which raises another question: under Tools > Options > Keyboard, if you scroll down the list of Keyboard Shortcuts, do you see any scripts in there (e.g. Scripts.ASB, Scripts.Text, etc.)?

Re: APN Script error #28840 08 Mar 19 11:27 AM
Joined: Oct 2015
Posts: 230
S
Stuart Offline OP
Member
OP Offline
Member
S
Joined: Oct 2015
Posts: 230
Sorry, I meant q on its own, for comment toggle, or g for 'go to', as you have them.

No Scripts, so that will be the answer. I haven't run the APN Extension finder, so that is probably why.

Everything might have been copied to the other system, thus skipping the above process, which might also explain why the APn variable wasn't required.

I'll explore further along these lines.

Thank you.


Powered by UBB.threads™ PHP Forum Software 7.7.3