I am using WAPT 2.2.1, in a completely Windows environment.
I want to run a .bat file with a very simple command line:
Code: Select all
ipconfig /all > Y:\SimonP\MAC\%username%.txtHere is the package I put in place (just as simple):
Code: Select all
# -*- coding: utf-8 -*-
from setuphelpers import *
def install():
run("ipconfig.bat")
Code: Select all
*** Remote Interpreter Reinitialized ***
Command Line : install "c:\waptdev\dams-ipconfig_0_PROD-wapt\WAPT\.."
Using config file: C:\Program Files (x86)\wapt\wapt-get.ini
Installing WAPT files c:\waptdev\dams-ipconfig_0_PROD-wapt
2022-08-22 11:47:00,203 CRITICAL Fatal error in install script: CalledProcessErrorOutput: Command 'ipconfig.bat' returned non-zero exit status 1.
Output:
c:\waptdev\dams-ipconfig_0_PROD-wapt>ipconfig /all 1>Y:\SimonP\MAC\h.veyrent.txt
The system cannot find the path specified.
:
Traceback (most recent call last):
File "C:\Program Files (x86)\wapt\common.py", line 4035, in install_wapt
exitstatus = setup.install()
File "c:\waptdev\dams-ipconfig_0_PROD-wapt\setup.py", line 5, in install
run("ipconfig.bat")
File "C:\Program Files (x86)\wapt\common.py", line 3817, in run
return ensure_unicode(run(*arg, pidlist=self.pidlist,**args))
File "C:\Program Files (x86)\wapt\waptutils.py", line 2126, in run
raise CalledProcessErrorOutput(proc.returncode, cmd, ''.join(output))
waptutils.CalledProcessErrorOutput: Command 'ipconfig.bat' returned non-zero exit status 1.
Output:
c:\waptdev\dams-ipconfig_0_PROD-wapt>ipconfig /all 1>Y:\SimonP\MAC\h.veyrent.txt
The system cannot find the path specified.
FATAL ERROR : CalledProcessErrorOutput: Command 'ipconfig.bat' returned non-zero exit status 1.
Output:
c:\waptdev\dams-ipconfig_0_PROD-wapt>ipconfig /all 1>Y:\SimonP\MAC\h.veyrent.txt
The system cannot find the path specified.
Exit code: 3
>>> What did I do wrong, or what did I forget?
I correctly placed the .bat file in the package (as with an .msi or .exe installation), the .bat file launched manually works and correctly sends the result to the shared directory.
THANKS
Good day,
Hugo
