Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ python:
install:
- pip install -r external_requirements.txt --extra-index-url https://pypi.python.org/simple
- pip install -r test_requirements.txt --extra-index-url https://pypi.python.org/simple
- pip install "cloudshell-shell-core>=2.2.0,<2.3.0" --extra-index-url https://testpypi.python.org/simple
- pip install "cloudshell-automation-api>=8.0.0.0,<8.1.0.0" --extra-index-url https://testpypi.python.org/simple
- pip install "cloudshell-shell-core>=3.1.0,<3.2.0" --extra-index-url https://testpypi.python.org/simple
- pip install "cloudshell-automation-api>=8.2.0.0,<8.2.1.0" --extra-index-url https://testpypi.python.org/simple

script:
- pushd package
Expand All @@ -21,3 +21,4 @@ notifications:
email: false
#notifications:
# webhools: https://qualisystems.getbadges.io/api/app/webhook/{will be added later}

4 changes: 2 additions & 2 deletions drivers/customscript_shell/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
cloudshell-shell-core>=2.2.0,<2.3.0
cloudshell-cm-customscript>=1.2.0,<1.3.0
cloudshell-shell-core>=3.1.0,<3.2.0
cloudshell-cm-customscript>=1.3.0,<1.4.0
2 changes: 1 addition & 1 deletion drivers/version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.2.0
1.3.0
4 changes: 4 additions & 0 deletions kill_python.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
@echo off
::taskkill /im python.exe /f
wmic Path win32_process Where "CommandLine Like '%%\\ExecutionServer\\%%python.exe%%'" Call Terminate
wmic Path win32_process Where "CommandLine Like '%%\\ProgramData\\QualiSystems\\%%python.exe%%'" Call Terminate
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ def json_to_object(self, json_str):

script_conf = ScriptConfiguration()
script_conf.timeout_minutes = json_obj.get('timeoutMinutes', 0.0)
script_conf.print_output = bool_parse(json_obj.get('printOutput'))
script_conf.print_output = bool_parse(json_obj.get('printOutput', True))

repo = json_obj['repositoryDetails']
script_conf.script_repo.url = repo.get('url')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
from cloudshell.cm.customscript.domain.reservation_output_writer import ReservationOutputWriter
from cloudshell.cm.customscript.domain.script_configuration import HostConfiguration
from cloudshell.cm.customscript.domain.script_executor import IScriptExecutor, ErrorMsg, ExcutorConnectionError
from requests import ConnectionError
from requests import ConnectionError, ConnectTimeout


class WindowsScriptExecutor(IScriptExecutor):
Expand All @@ -39,6 +39,9 @@ def connect(self):
uid = str(uuid4())
result = self.session.run_cmd('@echo '+uid)
assert uid in result.std_out
except ConnectTimeout as e:
self.logger(e.response)
raise ExcutorConnectionError(10060, e) #10060=Timeout
except ConnectionError as e:
match = re.search(r'\[Errno (?P<errno>\d+)\]', str(e.message))
error_code = int(match.group('errno')) if match else 0
Expand Down
4 changes: 2 additions & 2 deletions package/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
cloudshell-automation-api>=8.0.0.0,<8.1.0.0
cloudshell-shell-core>=2.2.0,<2.3.0
cloudshell-automation-api>=8.2.0.0,<8.2.1.0
cloudshell-shell-core>=3.1.0,<3.2.0
pywinrm>=0.2.2
paramiko>=2.1.1
scpclient>=0.7
2 changes: 1 addition & 1 deletion package/version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.2.0
1.3.0
2 changes: 1 addition & 1 deletion version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.2.0
1.3.0