FIXED: Can't execute/debug script against file in right view

Report issues, odd behaviors or submit a detailed bug report.
Post Reply
crtrubshaw
Posts: 248
Joined: 06 Jun 2012 11:08

FIXED: Can't execute/debug script against file in right view

Post by crtrubshaw » 31 Jan 2020 12:35

Hi Rickard,

I am writing a user script (.jsfs) and have a test file open in the right view, when I try to run the script I get this error popup, the script runs fine when I have the script itself (left view) focused.

Snip 20200131-112944.jpg
Snip 20200131-112944.jpg (10.59 KiB) Viewed 248 times

User avatar
pjj
Posts: 1699
Joined: 13 Oct 2009 13:48
Location: Kraków, Poland

Re: Can't execute/debug script against file in right view

Post by pjj » 31 Jan 2020 15:28

You are attempting to run a file, which is not the script -- hence the warning message (of course). Perhaps editor might get "smart" and check if any other foreground tab contains a script, but what if there are four views open, with e.g. three scripts?

There is one more bug, though: per https://www.rj-texted.se/Forum/view ... f=5&t=4238 foreground tab in inactive view should have slightly dimmed background, but it hasn't anymore -- both have the same bright color. I guess it was regressed when new Document views were introduced.
Alium tibi quaere fratrem; hic, quem tuum putas, meus est. Titus Flāvius Caesar Vespasiānus Augustus

crtrubshaw
Posts: 248
Joined: 06 Jun 2012 11:08

Re: Can't execute/debug script against file in right view

Post by crtrubshaw » 02 Feb 2020 15:11

I have attached 2 screenshots, in both shots the text file on the right has focus (as the target test file).

The first screenshot shows when I run the script (using the "Run script" button on the user toolbar), in this case there is only the script file open in the left view and a target file on the right, here it runs fine. However, in the second screenshot, there is another file open to the left of the script file, and when I try to run the script I get the error message in screenshot 2.

The attachment snip 1.jpg is no longer available
snip 1.jpg
snip 1.jpg (215.56 KiB) Viewed 202 times

crtrubshaw
Posts: 248
Joined: 06 Jun 2012 11:08

Re: Can't execute/debug script against file in right view

Post by crtrubshaw » 02 Feb 2020 15:12

snip 2.jpg
snip 2.jpg (229.44 KiB) Viewed 202 times

User avatar
Rickard Johansson
Site Admin
Posts: 5870
Joined: 19 Jul 2006 14:29

Re: Can't execute/debug script against file in right view

Post by Rickard Johansson » 07 Feb 2020 13:28

Fixed the issues in v14.40. Thanks!

Post Reply