Page 1 of 1

[NoBug]Error 5: 19.7+ Only, including Fresh

Posted: 24 Feb 2019 10:26
by Dustydog
Also doesn't want to acknowledge "step;" inside a script. In fact, it threw the below "step" error when that was the first command encountered.

None of this happens after downgrading to 19.6.

This is from a long, but well-used script and happens regardless of how I call it, though it uses the:

"Description : Identifier" syntax and is usually called from another script or shortcut. And no, I'd rather not post it all.

The "Error 5" doesn't repeat after it has shown once, but it won't recognize an internal "step;" command regardless. Again, fine in 19.6.

I'm sticking to 19.6 for awhile to get some work done. Any ideas? Anyone else? What the heck does it mean, anyway?

Good Luck! (Just to me?)

Code: Select all

Error 5

Error:  	5 (0x00000005)
Desc:   	Invalid procedure call or argument
Dll:    	0
Proc:   	script_Process: if

Source: 	XYplorer
XY ver: 	XYplorer 19.70.0100
OS:     	Windows 10 Professional, 64-bit, Release 1803, Build 17134.590
Locale: 	1033
ANSI:   	1252
ACP:    	1252  (ANSI - Latin I)
DBCS:   	No
DPI:    	96 (100%)

Date:   	2019-02-24 01:09:35

Code: Select all

Error 5

Error:  	5 (0x00000005)
Desc:   	Invalid procedure call or argument
Dll:    	0
Proc:   	script_Process: set

Source: 	XYplorer
XY ver: 	XYplorer 19.70.0100
OS:     	Windows 10 Professional, 64-bit, Release 1803, Build 17134.590
Locale: 	1033
ANSI:   	1252
ACP:    	1252  (ANSI - Latin I)
DBCS:   	No
DPI:    	96 (100%)

Date:   	2019-02-24 01:27:44

Code: Select all

Error 5

Error:  	5 (0x00000005)
Desc:   	Invalid procedure call or argument
Dll:    	0
Proc:   	script_Process: step

Source: 	XYplorer
XY ver: 	XYplorer 19.70.0100
OS:     	Windows 10 Professional, 64-bit, Release 1803, Build 17134.590
Locale: 	1033
ANSI:   	1252
ACP:    	1252  (ANSI - Latin I)
DBCS:   	No
DPI:    	96 (100%)

Date:   	2019-02-24 01:31:07
INSTALLED CURRENT BETA:

Code: Select all

Error:  	5 (0x00000005)
Desc:   	Invalid procedure call or argument
Dll:    	0
Proc:   	script_Process: set

Source: 	XYplorer
XY ver: 	XYplorer 19.70.0104
OS:     	Windows 10 Professional, 64-bit, Release 1803, Build 17134.590
Locale: 	1033 (en-US)
ANSI:   	1252, ACP: 1252  (ANSI - Latin I)
Font:   	Segoe UI 12.75, DBCS: No
DPI:    	96 (100%), 2560x1440

Date:   	2019-02-24 01:41:09
FRESH:

Code: Select all

Error 5

Error:  	5 (0x00000005)
Desc:   	Invalid procedure call or argument
Dll:    	0
Proc:   	script_Process: set

Source: 	XYplorer
XY ver: 	XYplorer 19.70.0104 (Virgin)
OS:     	Windows 10 Professional, 64-bit, Release 1803, Build 17134.590
Locale: 	1033 (en-US)
ANSI:   	1252, ACP: 1252  (ANSI - Latin I)
Font:   	Segoe UI 9, DBCS: No
DPI:    	96 (100%), 2560x1440

Date:   	2019-02-24 01:51:44

Code: Select all

Error 5

Error:  	5 (0x00000005)
Desc:   	Invalid procedure call or argument
Dll:    	0
Proc:   	script_Process: set

Source: 	XYplorer
XY ver: 	XYplorer 19.70.0104 (Virgin)
OS:     	Windows 10 Professional, 64-bit, Release 1803, Build 17134.590
Locale: 	1033 (en-US)
ANSI:   	1252, ACP: 1252  (ANSI - Latin I)
Font:   	Segoe UI 9, DBCS: No
DPI:    	96 (100%), 2560x1440

Date:   	2019-02-24 01:56:19

Re: Error 5: 19.7+ Only, including Fresh

Posted: 24 Feb 2019 10:52
by highend
No problems here so far with my scripts and no problems with step; as well.

Send me the script via e-mail or pm...

Re: Error 5: 19.7+ Only, including Fresh

Posted: 24 Feb 2019 10:57
by bdeshi
Dustydog wrote: 24 Feb 2019 10:26"Description : Identifier" syntax and is usually called from another script or shortcut. And no, I'd rather not post it all.
You should show us a smallest possible script that displays this behaviour.

Re: Error 5: 19.7+ Only, including Fresh - My Bad

Posted: 24 Feb 2019 12:40
by Dustydog
Turned on syntax checking. Discovered I had a bad function declaration in a multi-script that was being called by the main script (so A called B called C, which had the error), though the function with the bad declaration wasn't itself being called. Evidently 19.6 was friendlier about it than 19.7 for some reason.

My bad though.

Thanks for the offers of help.

Re: Error 5: 19.7+ Only, including Fresh

Posted: 24 Feb 2019 12:40
by admin
From the date I would guess it's related to this:

Code: Select all

v19.60.0105 - 2019-02-15 20:50
    ! Scripting: Parsing error with nested Switch statements. Fixed.
You should be able to identify the offending line by stepping...

PS: Oh, it self-fixed?! Okay. :mrgreen:

Re: [NoBug]Error 5: 19.7+ Only, including Fresh

Posted: 26 Feb 2019 19:31
by JohnM
I have just recently started getting the error 5 message as well. Here's mine.
xy error 5.PNG
xy error 5.PNG (16.47 KiB) Viewed 1438 times
Interestingly, prior to 19.70.0110 the "Proc" line in the error message was "script_Process: set". Not it is "script_Process: focus".

I get the message when I enable step mode (Script->Step Mode) on a script that I use a lot. The message shows immediately after clicking "Continue" in the "Stepping through a script" dialogue box.

Here is a stripped down version of that script that reproduces the problem every time (including on ::fresh).

Code: Select all

"Testing : testing"
	focus "L";

	$FILE_LIST = get("SelectedItemsPathNames", "|");

	foreach($name, $FILE_LIST, "|", "e") {
		$base = getpathcomponent($name, "base");
		$suffix = "." . getpathcomponent($name, "ext");

		switch ($suffix) {
		case ".txt":
			$matches = regexmatches($base, "^testpatt$");
			foreach($var, $matches, "|", "e") {
				echo $var
			}
			break;

		default:
			break;
		}
	}
	status "Test complete", 004080, ready;
I suspect that it has to do with the second foreach() (inside the switch) because if I remove it, the problem goes away.

After I get this message, step mode stops working. To get step mode working again I restart XY.

Cheers
John

Re: [NoBug]Error 5: 19.7+ Only, including Fresh

Posted: 26 Feb 2019 20:25
by highend
Look at that line...
echo $var
and now ask yourself, what is missing :mrgreen:

Re: [NoBug]Error 5: 19.7+ Only, including Fresh

Posted: 26 Feb 2019 21:22
by admin
It was a bug. Fix comes.

Re: [NoBug]Error 5: 19.7+ Only, including Fresh

Posted: 27 Feb 2019 20:09
by JohnM
highend wrote:and now ask yourself, what is missing
I ask myself that question everyday. Yes I noticed that I missed the semicolon, but XY puts it in automagically. 8)
admin wrote:It was a bug. Fix comes.
It's fixed now (even with the missing semicolon), thanks :tup: