Author Topic: 26.0.3.1: Can no longer build when ssh into another machine  (Read 1887 times)

rowbearto

  • Senior Community Member
  • Posts: 2335
  • Hero Points: 132
I often like to ssh into a different machine manually from the "Build" tool window and then run the "Build" command in SlickEdit.

This worked fine in previous releases.

But now in 26.0.3.1 when I try to do this I get an error:

Code: [Select]
/home/rbresali/pen/slickedit/se_26000301_linux64/bin/vsbuild -signal vsbuild_done -commandfile "/tmp/slk.486800.20220713162217087.-6.cmf"
/home/rbresali/pen/slickedit/se_26000301_linux64/bin/vsbuild -signal vsbuild_done -commandfile "/tmp/slk.486800.20220713162217087.-6.cmf"
ERROR: Could not open arg file '/tmp/slk.486800.20220713162217087.-6.cmf'

As I have sshed somewhere else then vsbuild is running on a different machine then SlickEdit. That machine has a different /tmp directory, so SlickEdit is not able to find it.

I would really like to be able to get this ability back.

patrick

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 1818
  • Hero Points: 151
Re: 26.0.3.1: Can no longer build when ssh into another machine
« Reply #1 on: July 13, 2022, 04:53:21 PM »
Ah, it's referencing a local arguments file.  I may need to put in a configuration option so you can disable it for this case.  I'll look and see what I can do.

rowbearto

  • Senior Community Member
  • Posts: 2335
  • Hero Points: 132
Re: 26.0.3.1: Can no longer build when ssh into another machine
« Reply #2 on: September 12, 2022, 03:09:07 PM »
Patrick:

This issue is still there in beta2. Any way I can get this functionality back?

patrick

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 1818
  • Hero Points: 151
Re: 26.0.3.1: Can no longer build when ssh into another machine
« Reply #3 on: September 12, 2022, 07:11:51 PM »
In beta 3, you'll be able to set "def_allow_vsbuild_use_commandfile" to 0 and get back the old behavior where it isn't referencing a commandfile on the local filesystem.

rowbearto

  • Senior Community Member
  • Posts: 2335
  • Hero Points: 132
Re: 26.0.3.1: Can no longer build when ssh into another machine
« Reply #4 on: September 12, 2022, 07:34:15 PM »
Thanks Patrick.

What is this new feature with def_allow_vsbuild_use_commandfile set to non-zero?

Why not have the old behavior as the default and the new behavior be non-default?

patrick

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 1818
  • Hero Points: 151
Re: 26.0.3.1: Can no longer build when ssh into another machine
« Reply #5 on: September 12, 2022, 07:59:03 PM »
The var just controls whether some arguments to vsbuild are passed inside of a file rather than on the command line to vsbuild.

It's on by default because it fixes some obscure problems with different build shells and expansions/quoting.  I don't think anyone anticipated that vsbuild commands would be running on a remote machine, so it was enabled by default with no way to revert to the old behavior.  If you didn't have problems before, turning this off gets the old behavior that will work with the remote vsbuild.



rowbearto

  • Senior Community Member
  • Posts: 2335
  • Hero Points: 132
Re: 26.0.3.1: Can no longer build when ssh into another machine
« Reply #6 on: September 12, 2022, 10:22:12 PM »
Couldn't you fix the issues by passing on the command line to vsbuild? Seems like when I build remotely I would also have the same obscure problems that you fixed? By figuring out how to pass to command line with vsbuild then you solve the issue for both remote and local builds. Now if you have 2 solutions your fixes won't carry over to the remote case which could be unmaintained and stop working over time.

Not sure nobody anticipated that vsbuild commands can run on a remote machine, I've been doing this for years and it only stopped working in 26.0.3 - it worked fine in 26.0.2 and for all releases before it. I even have this issue about an aspect of it, see: https://community.slickedit.com/index.php/topic,18611.msg74869.html#msg74869

rowbearto

  • Senior Community Member
  • Posts: 2335
  • Hero Points: 132
Re: 26.0.3.1: Can no longer build when ssh into another machine
« Reply #7 on: September 13, 2022, 12:41:42 AM »
What about having vs_exe do escaping that vsbuild interprets? Then you can work with any shell. You control the code on both sides - vs_exe and vsbuild, so you could have complete control over how to escape things. Then you can make sure that vsbuild runs with all the proper parameters that are supposed to have space, quotes, etc.

For example with url encoding spaces are converted to %20. Couldn't you use a urlencode() to send the command line parameters to vsbuild? Then you could continue to send the parameters over the command line. If urlencode() doesn't work you could possibly reuse some other available encoding/decoding scheme?

rowbearto

  • Senior Community Member
  • Posts: 2335
  • Hero Points: 132
Re: 26.0.3.1: Can no longer build when ssh into another machine
« Reply #8 on: September 22, 2022, 01:17:53 PM »
In beta3 I tried adding:

def_allow_vsbuild_use_commandfile = 0;

into my Slick-C file for my settings.

When loading my .e file I get error:

Identifier 'def_allow_vsbuild_use_commandfile ' not declared.

I found it in 'compile.e', but even after I add "import compile.e" I still get this error.

patrick

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 1818
  • Hero Points: 151
Re: 26.0.3.1: Can no longer build when ssh into another machine
« Reply #9 on: September 23, 2022, 12:30:18 PM »
That's odd. I can set it in a macro, or in a defmain {} script when compile.e is imported.

I can do either of these:
Code: [Select]
   def_allow_vsbuild_use_commandfile=1;
   set_var('def_allow_vsbuild_use_commandfile 0');

Does it work if you do the set-var version?

Does it make any difference if you load the "compile.e" from the SlickEdit install directory, and then re-load your macro file and re-run your setup?   (I wouldn't expect it to unless another version of compile.e was loaded, so this is a paranoia check). 


rowbearto

  • Senior Community Member
  • Posts: 2335
  • Hero Points: 132
Re: 26.0.3.1: Can no longer build when ssh into another machine
« Reply #10 on: September 23, 2022, 12:52:24 PM »
The set-var version loads and executes properly.

I tried loading 'compile.e' from SlickEdit directory, but macro still won't load if I do:

Code: [Select]
#import "compile.e"
...
def_allow_vsbuild_use_commandfile = 0;

Not sure if this makes a difference but I set that variable inside a command function:

Code: [Select]
_command void initialSeConfig() name_info(','VSARG2_READ_ONLY)
{

Look for robutils_20220923.e on support and try to load it. This is the .e file where I get this error.

patrick

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 1818
  • Hero Points: 151
Re: 26.0.3.1: Can no longer build when ssh into another machine
« Reply #11 on: September 23, 2022, 06:15:03 PM »
I can't reproduce it with that file.  I've gone through different scenarios, with clean configs, and existing v27 configs, and upgrades from v26.  No luck.

If you run v27 with -sc /tmp/CleanConfig, can you load the file then?  It seems like it's should be something related to upgrading, but if you get it with a clean config, then I'm on the wrong track.




rowbearto

  • Senior Community Member
  • Posts: 2335
  • Hero Points: 132
Re: 26.0.3.1: Can no longer build when ssh into another machine
« Reply #12 on: September 23, 2022, 07:28:51 PM »
I'm also getting the error with a clean config.

patrick

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 1818
  • Hero Points: 151
Re: 26.0.3.1: Can no longer build when ssh into another machine
« Reply #13 on: September 23, 2022, 08:13:16 PM »
Not what I was expecting.  Could you go to the build window when it is not connected to a remote machine, and run "printenv" and get the output?   Might be best to upload it to support rather than post it, since it will have a lot of system information.

Clark

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 6864
  • Hero Points: 528
Re: 26.0.3.1: Can no longer build when ssh into another machine
« Reply #14 on: September 24, 2022, 01:54:09 AM »
In beta3 I tried adding:

def_allow_vsbuild_use_commandfile = 0;

into my Slick-C file for my settings.

When loading my .e file I get error:

Identifier 'def_allow_vsbuild_use_commandfile ' not declared.

I found it in 'compile.e', but even after I add "import compile.e" I still get this error.

Make sure when loading/compiling your macro that SlickEdit isn't finding the wrong compile.e. I've been burned by this since I have copies of macros all over the place.