From 6d442a424e557bfff25e398c605a5ed942093e7e Mon Sep 17 00:00:00 2001 From: Ivan Maslov Date: Thu, 21 Nov 2019 22:09:57 +0300 Subject: [PATCH] #New RobotScreenActive + tested --- .../WPy32-3720/python-3.7.2/ConsoleStart.bat | 3 +++ .../INSTALLER | 0 .../pyOpenRPA-1.0.30.dist-info}/METADATA | 2 +- .../pyOpenRPA-1.0.30.dist-info}/RECORD | 22 ++++++++++++++----- .../WHEEL | 0 .../top_level.txt | 0 .../Tools/RobotScreenActive/ConsoleStart.bat | 3 +++ .../Tools/RobotScreenActive/Monitor.py | 14 ++++++++++++ .../Tools/RobotScreenActive/Screen.py | 20 +++++++++++++++++ .../Tools/RobotScreenActive/__init__.py | 0 .../Tools/RobotScreenActive/__main__.py | 16 ++++++++++++++ .../Lib/site-packages/pyOpenRPA/__init__.py | 2 +- .../python-3.7.2.amd64/ConsoleStart.bat | 3 +++ .../INSTALLER | 0 .../pyOpenRPA-1.0.30.dist-info}/METADATA | 2 +- .../pyOpenRPA-1.0.30.dist-info}/RECORD | 22 ++++++++++++++----- .../WHEEL | 0 .../top_level.txt | 0 .../Tools/RobotScreenActive/ConsoleStart.bat | 3 +++ .../Tools/RobotScreenActive/Monitor.py | 14 ++++++++++++ .../Tools/RobotScreenActive/Screen.py | 20 +++++++++++++++++ .../Tools/RobotScreenActive/__init__.py | 0 .../Tools/RobotScreenActive/__main__.py | 16 ++++++++++++++ .../Lib/site-packages/pyOpenRPA/__init__.py | 2 +- Sources/pyOpenRPA.egg-info/PKG-INFO | 2 +- Sources/pyOpenRPA.egg-info/SOURCES.txt | 7 +++++- .../Tools/RobotScreenActive/ConsoleStart.bat | 3 +++ .../Tools/RobotScreenActive/Monitor.py | 14 ++++++++++++ .../Tools/RobotScreenActive/Screen.py | 20 +++++++++++++++++ .../Tools/RobotScreenActive/__init__.py | 0 .../Tools/RobotScreenActive/__main__.py | 16 ++++++++++++++ Sources/pyOpenRPA/__init__.py | 2 +- Sources/setup.py | 2 ++ .../pyOpenRPA.Tools.RobotScreenActive_x64.cmd | 3 +++ changelog.md | 2 ++ v1.0.30 | 0 36 files changed, 216 insertions(+), 19 deletions(-) create mode 100644 Resources/WPy32-3720/python-3.7.2/ConsoleStart.bat rename Resources/WPy32-3720/python-3.7.2/Lib/site-packages/{pyOpenRPA-1.0.29.dist-info => pyOpenRPA-1.0.30.dist-info}/INSTALLER (100%) rename Resources/{WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.29.dist-info => WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.30.dist-info}/METADATA (99%) rename Resources/{WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.29.dist-info => WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.30.dist-info}/RECORD (97%) rename Resources/WPy32-3720/python-3.7.2/Lib/site-packages/{pyOpenRPA-1.0.29.dist-info => pyOpenRPA-1.0.30.dist-info}/WHEEL (100%) rename Resources/WPy32-3720/python-3.7.2/Lib/site-packages/{pyOpenRPA-1.0.29.dist-info => pyOpenRPA-1.0.30.dist-info}/top_level.txt (100%) create mode 100644 Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/ConsoleStart.bat create mode 100644 Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/Monitor.py create mode 100644 Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/Screen.py rename v1.0.29 => Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/__init__.py (100%) create mode 100644 Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/__main__.py create mode 100644 Resources/WPy64-3720/python-3.7.2.amd64/ConsoleStart.bat rename Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/{pyOpenRPA-1.0.29.dist-info => pyOpenRPA-1.0.30.dist-info}/INSTALLER (100%) rename Resources/{WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.29.dist-info => WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.30.dist-info}/METADATA (99%) rename Resources/{WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.29.dist-info => WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.30.dist-info}/RECORD (97%) rename Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/{pyOpenRPA-1.0.29.dist-info => pyOpenRPA-1.0.30.dist-info}/WHEEL (100%) rename Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/{pyOpenRPA-1.0.29.dist-info => pyOpenRPA-1.0.30.dist-info}/top_level.txt (100%) create mode 100644 Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/ConsoleStart.bat create mode 100644 Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/Monitor.py create mode 100644 Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/Screen.py create mode 100644 Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/__init__.py create mode 100644 Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/__main__.py create mode 100644 Sources/pyOpenRPA/Tools/RobotScreenActive/ConsoleStart.bat create mode 100644 Sources/pyOpenRPA/Tools/RobotScreenActive/Monitor.py create mode 100644 Sources/pyOpenRPA/Tools/RobotScreenActive/Screen.py create mode 100644 Sources/pyOpenRPA/Tools/RobotScreenActive/__init__.py create mode 100644 Sources/pyOpenRPA/Tools/RobotScreenActive/__main__.py create mode 100644 Utils/RobotScreenActive/pyOpenRPA.Tools.RobotScreenActive_x64.cmd create mode 100644 v1.0.30 diff --git a/Resources/WPy32-3720/python-3.7.2/ConsoleStart.bat b/Resources/WPy32-3720/python-3.7.2/ConsoleStart.bat new file mode 100644 index 00000000..c9dffba5 --- /dev/null +++ b/Resources/WPy32-3720/python-3.7.2/ConsoleStart.bat @@ -0,0 +1,3 @@ +for /f "skip=1 tokens=3" %%s in ('query user %USERNAME%') do ( + %windir%\System32\tscon.exe %%s /dest:console +) \ No newline at end of file diff --git a/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/INSTALLER b/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/INSTALLER similarity index 100% rename from Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/INSTALLER rename to Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/INSTALLER diff --git a/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/METADATA b/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/METADATA similarity index 99% rename from Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/METADATA rename to Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/METADATA index 06b41ed1..8a43c705 100644 --- a/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/METADATA +++ b/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/METADATA @@ -1,6 +1,6 @@ Metadata-Version: 2.1 Name: pyOpenRPA -Version: 1.0.29 +Version: 1.0.30 Summary: First open source RPA platform for business Home-page: https://gitlab.com/UnicodeLabs/OpenRPA Author: Ivan Maslov diff --git a/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/RECORD b/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/RECORD similarity index 97% rename from Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/RECORD rename to Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/RECORD index bcf7cfd0..1a2cb877 100644 --- a/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/RECORD +++ b/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/RECORD @@ -1,3 +1,4 @@ +../../ConsoleStart.bat,sha256=_HNadUKHOYI5y6foG3srh8wjSzhX33xaKNylFtDjOJk,114 ../../Template.rdp,sha256=qPCLkjzTdYKURK7nRApkPUjRuS4K20vDPj9DIUNSSkE,2392 ../../pyOpenRPA/Orchestrator/Web/Index.xhtml,sha256=JaHn6K7wXkK6K0qYrfcRjVQDhgWA8_qR_YzIqqDDp9w,31297 ../../pyOpenRPA/Orchestrator/Web/favicon.ico,sha256=jO3pjFWbmJEPQ2KroXSKYtXIesBq46PCBlKSouewODU,5430 @@ -175,11 +176,11 @@ ../../pyOpenRPA/Resources/Web/jQuery/jquery-3.1.1.min.js,sha256=HPMOWdIdSuVgr3FD9ZE-_MgiK8qk_MdQjrgCtfqp6U4,86713 ../../pyOpenRPA/Studio/Web/Index.xhtml,sha256=74z3eWlmB6Yedbp91xgGtDjymUSlBcduAQ09ZxQ67f8,44241 ../../pyOpenRPA/Studio/Web/favicon.ico,sha256=0vdsnwKGh6pgB0FDB5mOKO7RwbxQ9F13Zg16F1pkvXs,5430 -pyOpenRPA-1.0.29.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 -pyOpenRPA-1.0.29.dist-info/METADATA,sha256=KLwKSmN6ZJq19quyg5VdnamA85Zv_i4UVXCY4k0gr80,3510 -pyOpenRPA-1.0.29.dist-info/RECORD,, -pyOpenRPA-1.0.29.dist-info/WHEEL,sha256=qB97nP5e4MrOsXW5bIU5cUn_KSVr10EV0l-GCHG9qNs,97 -pyOpenRPA-1.0.29.dist-info/top_level.txt,sha256=RPzwQXgYBRo_m5L3ZLs6Voh8aEkMeT29Xsul1w1qE0g,10 +pyOpenRPA-1.0.30.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 +pyOpenRPA-1.0.30.dist-info/METADATA,sha256=KAmO8WXVi9ZreWmoV3uXrFSx7dIlTj6s1CqsRxlSx74,3510 +pyOpenRPA-1.0.30.dist-info/RECORD,, +pyOpenRPA-1.0.30.dist-info/WHEEL,sha256=qB97nP5e4MrOsXW5bIU5cUn_KSVr10EV0l-GCHG9qNs,97 +pyOpenRPA-1.0.30.dist-info/top_level.txt,sha256=RPzwQXgYBRo_m5L3ZLs6Voh8aEkMeT29Xsul1w1qE0g,10 pyOpenRPA/Orchestrator/Orchestrator.py,sha256=mlxsd8YMs9X_Een8HfOlCv5d_LVgcx21UAQphHFfD_M,6689 pyOpenRPA/Orchestrator/Processor.py,sha256=GHXwC1B2py4mAtk9oZa-FVSJhx3no9oD2bvkj20uhNA,9051 pyOpenRPA/Orchestrator/Server.py,sha256=GH7P0L-83ONlRdVYu3oQqt2oCgXPXYjrcFb0tY_6SYU,12878 @@ -415,7 +416,16 @@ pyOpenRPA/Tools/RobotRDPActive/__pycache__/Monitor.cpython-37.pyc,, pyOpenRPA/Tools/RobotRDPActive/__pycache__/SettingsExample.cpython-37.pyc,, pyOpenRPA/Tools/RobotRDPActive/__pycache__/__init__.cpython-37.pyc,, pyOpenRPA/Tools/RobotRDPActive/__pycache__/__main__.cpython-37.pyc,, +pyOpenRPA/Tools/RobotScreenActive/ConsoleStart.bat,sha256=_HNadUKHOYI5y6foG3srh8wjSzhX33xaKNylFtDjOJk,114 +pyOpenRPA/Tools/RobotScreenActive/Monitor.py,sha256=TV-YisVqa_uGiyJLG9oK4u-5aDjGiFYZFh1dPjOgYc8,492 +pyOpenRPA/Tools/RobotScreenActive/Screen.py,sha256=VnYcvCVymrD35l2J4ln_tlVn7CilZhxE4Ggw9P-OhIw,606 +pyOpenRPA/Tools/RobotScreenActive/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pyOpenRPA/Tools/RobotScreenActive/__main__.py,sha256=JASxDDVKWUU7DAbDkRrGTrPk-P7LZchTZFh8usp6b4U,593 +pyOpenRPA/Tools/RobotScreenActive/__pycache__/Monitor.cpython-37.pyc,, +pyOpenRPA/Tools/RobotScreenActive/__pycache__/Screen.cpython-37.pyc,, +pyOpenRPA/Tools/RobotScreenActive/__pycache__/__init__.cpython-37.pyc,, +pyOpenRPA/Tools/RobotScreenActive/__pycache__/__main__.cpython-37.pyc,, pyOpenRPA/Tools/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 pyOpenRPA/Tools/__pycache__/__init__.cpython-37.pyc,, -pyOpenRPA/__init__.py,sha256=q2sfPPdzwVfaks4UHgQB28jiJhwRFcELk5EOs6lxlNM,175 +pyOpenRPA/__init__.py,sha256=LSoBTiL4xkfYXS-cDG9oAR0vDCxouM2W_MKbqQiQMJ8,175 pyOpenRPA/__pycache__/__init__.cpython-37.pyc,, diff --git a/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/WHEEL b/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/WHEEL similarity index 100% rename from Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/WHEEL rename to Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/WHEEL diff --git a/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/top_level.txt b/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/top_level.txt similarity index 100% rename from Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/top_level.txt rename to Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/top_level.txt diff --git a/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/ConsoleStart.bat b/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/ConsoleStart.bat new file mode 100644 index 00000000..c9dffba5 --- /dev/null +++ b/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/ConsoleStart.bat @@ -0,0 +1,3 @@ +for /f "skip=1 tokens=3" %%s in ('query user %USERNAME%') do ( + %windir%\System32\tscon.exe %%s /dest:console +) \ No newline at end of file diff --git a/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/Monitor.py b/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/Monitor.py new file mode 100644 index 00000000..50683680 --- /dev/null +++ b/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/Monitor.py @@ -0,0 +1,14 @@ +import time #lib to create delay +from . import Screen # module to detect screen exists +#Check screen every 1 second +def CheckScreen(inIntervalSeconds=1): + while True: + #Check if screen exist + if not Screen.Exists(): + #Send os command to create console version (base screen) + Screen.ConsoleScreenBase() + #Delay to create console screen + time.sleep(2) + #Delay + time.sleep(inIntervalSeconds) + return None \ No newline at end of file diff --git a/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/Screen.py b/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/Screen.py new file mode 100644 index 00000000..1d5ffecc --- /dev/null +++ b/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/Screen.py @@ -0,0 +1,20 @@ +from PIL import ImageGrab +import os # to execute cmd commands +#Check if screen is exists +def Exists(): + #Try to get 1 px from screen + try: + #Take 1 px + ImageGrab.grab(bbox=(0,0,1,1)) + #Screen is exists - return True + return True + #Catch exception + except Exception: + #Screen does not exists - return false + return False +#Make console session +def ConsoleScreenBase(): + #Get script folder path + lFolderPath = "/".join(__file__.split("\\")[:-1]) + #Send command to cmd + os.system(os.path.join(lFolderPath,"ConsoleStart.bat")) \ No newline at end of file diff --git a/v1.0.29 b/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/__init__.py similarity index 100% rename from v1.0.29 rename to Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/__init__.py diff --git a/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/__main__.py b/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/__main__.py new file mode 100644 index 00000000..e871045a --- /dev/null +++ b/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/__main__.py @@ -0,0 +1,16 @@ +#Run example +#cd %~dp0..\..\Sources +#..\Resources\WPy64-3720\python-3.7.2.amd64\python.exe -m pyOpenRPA.Tools.RobotScreenActive +#pause >nul +#Import parent folder to import current / other packages +######################################################### +import sys +import subprocess #start process async +import os #path, run, remove +import time #timer +import importlib +#lFolderPath = "\\".join(__file__.split("\\")[:-4]) +lFolderPath = "/".join(__file__.split("/")[:-4]) +sys.path.insert(0, lFolderPath) +from pyOpenRPA.Tools.RobotScreenActive import Monitor +Monitor.CheckScreen() \ No newline at end of file diff --git a/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/__init__.py b/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/__init__.py index e1f41f7d..8fbab8b4 100644 --- a/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/__init__.py +++ b/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA/__init__.py @@ -3,7 +3,7 @@ r""" The OpenRPA package (from UnicodeLabs) """ -__version__ = 'v1.0.29' +__version__ = 'v1.0.30' __all__ = [] __author__ = 'Ivan Maslov ' #from .Core import Robot \ No newline at end of file diff --git a/Resources/WPy64-3720/python-3.7.2.amd64/ConsoleStart.bat b/Resources/WPy64-3720/python-3.7.2.amd64/ConsoleStart.bat new file mode 100644 index 00000000..c9dffba5 --- /dev/null +++ b/Resources/WPy64-3720/python-3.7.2.amd64/ConsoleStart.bat @@ -0,0 +1,3 @@ +for /f "skip=1 tokens=3" %%s in ('query user %USERNAME%') do ( + %windir%\System32\tscon.exe %%s /dest:console +) \ No newline at end of file diff --git a/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/INSTALLER b/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/INSTALLER similarity index 100% rename from Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/INSTALLER rename to Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/INSTALLER diff --git a/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/METADATA b/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/METADATA similarity index 99% rename from Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/METADATA rename to Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/METADATA index 06b41ed1..8a43c705 100644 --- a/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/METADATA +++ b/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/METADATA @@ -1,6 +1,6 @@ Metadata-Version: 2.1 Name: pyOpenRPA -Version: 1.0.29 +Version: 1.0.30 Summary: First open source RPA platform for business Home-page: https://gitlab.com/UnicodeLabs/OpenRPA Author: Ivan Maslov diff --git a/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/RECORD b/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/RECORD similarity index 97% rename from Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/RECORD rename to Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/RECORD index bcf7cfd0..1a2cb877 100644 --- a/Resources/WPy32-3720/python-3.7.2/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/RECORD +++ b/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/RECORD @@ -1,3 +1,4 @@ +../../ConsoleStart.bat,sha256=_HNadUKHOYI5y6foG3srh8wjSzhX33xaKNylFtDjOJk,114 ../../Template.rdp,sha256=qPCLkjzTdYKURK7nRApkPUjRuS4K20vDPj9DIUNSSkE,2392 ../../pyOpenRPA/Orchestrator/Web/Index.xhtml,sha256=JaHn6K7wXkK6K0qYrfcRjVQDhgWA8_qR_YzIqqDDp9w,31297 ../../pyOpenRPA/Orchestrator/Web/favicon.ico,sha256=jO3pjFWbmJEPQ2KroXSKYtXIesBq46PCBlKSouewODU,5430 @@ -175,11 +176,11 @@ ../../pyOpenRPA/Resources/Web/jQuery/jquery-3.1.1.min.js,sha256=HPMOWdIdSuVgr3FD9ZE-_MgiK8qk_MdQjrgCtfqp6U4,86713 ../../pyOpenRPA/Studio/Web/Index.xhtml,sha256=74z3eWlmB6Yedbp91xgGtDjymUSlBcduAQ09ZxQ67f8,44241 ../../pyOpenRPA/Studio/Web/favicon.ico,sha256=0vdsnwKGh6pgB0FDB5mOKO7RwbxQ9F13Zg16F1pkvXs,5430 -pyOpenRPA-1.0.29.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 -pyOpenRPA-1.0.29.dist-info/METADATA,sha256=KLwKSmN6ZJq19quyg5VdnamA85Zv_i4UVXCY4k0gr80,3510 -pyOpenRPA-1.0.29.dist-info/RECORD,, -pyOpenRPA-1.0.29.dist-info/WHEEL,sha256=qB97nP5e4MrOsXW5bIU5cUn_KSVr10EV0l-GCHG9qNs,97 -pyOpenRPA-1.0.29.dist-info/top_level.txt,sha256=RPzwQXgYBRo_m5L3ZLs6Voh8aEkMeT29Xsul1w1qE0g,10 +pyOpenRPA-1.0.30.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 +pyOpenRPA-1.0.30.dist-info/METADATA,sha256=KAmO8WXVi9ZreWmoV3uXrFSx7dIlTj6s1CqsRxlSx74,3510 +pyOpenRPA-1.0.30.dist-info/RECORD,, +pyOpenRPA-1.0.30.dist-info/WHEEL,sha256=qB97nP5e4MrOsXW5bIU5cUn_KSVr10EV0l-GCHG9qNs,97 +pyOpenRPA-1.0.30.dist-info/top_level.txt,sha256=RPzwQXgYBRo_m5L3ZLs6Voh8aEkMeT29Xsul1w1qE0g,10 pyOpenRPA/Orchestrator/Orchestrator.py,sha256=mlxsd8YMs9X_Een8HfOlCv5d_LVgcx21UAQphHFfD_M,6689 pyOpenRPA/Orchestrator/Processor.py,sha256=GHXwC1B2py4mAtk9oZa-FVSJhx3no9oD2bvkj20uhNA,9051 pyOpenRPA/Orchestrator/Server.py,sha256=GH7P0L-83ONlRdVYu3oQqt2oCgXPXYjrcFb0tY_6SYU,12878 @@ -415,7 +416,16 @@ pyOpenRPA/Tools/RobotRDPActive/__pycache__/Monitor.cpython-37.pyc,, pyOpenRPA/Tools/RobotRDPActive/__pycache__/SettingsExample.cpython-37.pyc,, pyOpenRPA/Tools/RobotRDPActive/__pycache__/__init__.cpython-37.pyc,, pyOpenRPA/Tools/RobotRDPActive/__pycache__/__main__.cpython-37.pyc,, +pyOpenRPA/Tools/RobotScreenActive/ConsoleStart.bat,sha256=_HNadUKHOYI5y6foG3srh8wjSzhX33xaKNylFtDjOJk,114 +pyOpenRPA/Tools/RobotScreenActive/Monitor.py,sha256=TV-YisVqa_uGiyJLG9oK4u-5aDjGiFYZFh1dPjOgYc8,492 +pyOpenRPA/Tools/RobotScreenActive/Screen.py,sha256=VnYcvCVymrD35l2J4ln_tlVn7CilZhxE4Ggw9P-OhIw,606 +pyOpenRPA/Tools/RobotScreenActive/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +pyOpenRPA/Tools/RobotScreenActive/__main__.py,sha256=JASxDDVKWUU7DAbDkRrGTrPk-P7LZchTZFh8usp6b4U,593 +pyOpenRPA/Tools/RobotScreenActive/__pycache__/Monitor.cpython-37.pyc,, +pyOpenRPA/Tools/RobotScreenActive/__pycache__/Screen.cpython-37.pyc,, +pyOpenRPA/Tools/RobotScreenActive/__pycache__/__init__.cpython-37.pyc,, +pyOpenRPA/Tools/RobotScreenActive/__pycache__/__main__.cpython-37.pyc,, pyOpenRPA/Tools/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 pyOpenRPA/Tools/__pycache__/__init__.cpython-37.pyc,, -pyOpenRPA/__init__.py,sha256=q2sfPPdzwVfaks4UHgQB28jiJhwRFcELk5EOs6lxlNM,175 +pyOpenRPA/__init__.py,sha256=LSoBTiL4xkfYXS-cDG9oAR0vDCxouM2W_MKbqQiQMJ8,175 pyOpenRPA/__pycache__/__init__.cpython-37.pyc,, diff --git a/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/WHEEL b/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/WHEEL similarity index 100% rename from Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/WHEEL rename to Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/WHEEL diff --git a/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/top_level.txt b/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/top_level.txt similarity index 100% rename from Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.29.dist-info/top_level.txt rename to Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA-1.0.30.dist-info/top_level.txt diff --git a/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/ConsoleStart.bat b/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/ConsoleStart.bat new file mode 100644 index 00000000..c9dffba5 --- /dev/null +++ b/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/ConsoleStart.bat @@ -0,0 +1,3 @@ +for /f "skip=1 tokens=3" %%s in ('query user %USERNAME%') do ( + %windir%\System32\tscon.exe %%s /dest:console +) \ No newline at end of file diff --git a/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/Monitor.py b/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/Monitor.py new file mode 100644 index 00000000..50683680 --- /dev/null +++ b/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/Monitor.py @@ -0,0 +1,14 @@ +import time #lib to create delay +from . import Screen # module to detect screen exists +#Check screen every 1 second +def CheckScreen(inIntervalSeconds=1): + while True: + #Check if screen exist + if not Screen.Exists(): + #Send os command to create console version (base screen) + Screen.ConsoleScreenBase() + #Delay to create console screen + time.sleep(2) + #Delay + time.sleep(inIntervalSeconds) + return None \ No newline at end of file diff --git a/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/Screen.py b/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/Screen.py new file mode 100644 index 00000000..1d5ffecc --- /dev/null +++ b/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/Screen.py @@ -0,0 +1,20 @@ +from PIL import ImageGrab +import os # to execute cmd commands +#Check if screen is exists +def Exists(): + #Try to get 1 px from screen + try: + #Take 1 px + ImageGrab.grab(bbox=(0,0,1,1)) + #Screen is exists - return True + return True + #Catch exception + except Exception: + #Screen does not exists - return false + return False +#Make console session +def ConsoleScreenBase(): + #Get script folder path + lFolderPath = "/".join(__file__.split("\\")[:-1]) + #Send command to cmd + os.system(os.path.join(lFolderPath,"ConsoleStart.bat")) \ No newline at end of file diff --git a/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/__init__.py b/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/__main__.py b/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/__main__.py new file mode 100644 index 00000000..e871045a --- /dev/null +++ b/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/Tools/RobotScreenActive/__main__.py @@ -0,0 +1,16 @@ +#Run example +#cd %~dp0..\..\Sources +#..\Resources\WPy64-3720\python-3.7.2.amd64\python.exe -m pyOpenRPA.Tools.RobotScreenActive +#pause >nul +#Import parent folder to import current / other packages +######################################################### +import sys +import subprocess #start process async +import os #path, run, remove +import time #timer +import importlib +#lFolderPath = "\\".join(__file__.split("\\")[:-4]) +lFolderPath = "/".join(__file__.split("/")[:-4]) +sys.path.insert(0, lFolderPath) +from pyOpenRPA.Tools.RobotScreenActive import Monitor +Monitor.CheckScreen() \ No newline at end of file diff --git a/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/__init__.py b/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/__init__.py index e1f41f7d..8fbab8b4 100644 --- a/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/__init__.py +++ b/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pyOpenRPA/__init__.py @@ -3,7 +3,7 @@ r""" The OpenRPA package (from UnicodeLabs) """ -__version__ = 'v1.0.29' +__version__ = 'v1.0.30' __all__ = [] __author__ = 'Ivan Maslov ' #from .Core import Robot \ No newline at end of file diff --git a/Sources/pyOpenRPA.egg-info/PKG-INFO b/Sources/pyOpenRPA.egg-info/PKG-INFO index b36d8be1..255ad696 100644 --- a/Sources/pyOpenRPA.egg-info/PKG-INFO +++ b/Sources/pyOpenRPA.egg-info/PKG-INFO @@ -1,6 +1,6 @@ Metadata-Version: 2.1 Name: pyOpenRPA -Version: 1.0.29 +Version: 1.0.30 Summary: First open source RPA platform for business Home-page: https://gitlab.com/UnicodeLabs/OpenRPA Author: Ivan Maslov diff --git a/Sources/pyOpenRPA.egg-info/SOURCES.txt b/Sources/pyOpenRPA.egg-info/SOURCES.txt index 0daf7cf1..ef7174bc 100644 --- a/Sources/pyOpenRPA.egg-info/SOURCES.txt +++ b/Sources/pyOpenRPA.egg-info/SOURCES.txt @@ -212,4 +212,9 @@ pyOpenRPA/Tools/RobotRDPActive/Monitor.py pyOpenRPA/Tools/RobotRDPActive/SettingsExample.py pyOpenRPA/Tools/RobotRDPActive/Template.rdp pyOpenRPA/Tools/RobotRDPActive/__init__.py -pyOpenRPA/Tools/RobotRDPActive/__main__.py \ No newline at end of file +pyOpenRPA/Tools/RobotRDPActive/__main__.py +pyOpenRPA/Tools/RobotScreenActive/ConsoleStart.bat +pyOpenRPA/Tools/RobotScreenActive/Monitor.py +pyOpenRPA/Tools/RobotScreenActive/Screen.py +pyOpenRPA/Tools/RobotScreenActive/__init__.py +pyOpenRPA/Tools/RobotScreenActive/__main__.py \ No newline at end of file diff --git a/Sources/pyOpenRPA/Tools/RobotScreenActive/ConsoleStart.bat b/Sources/pyOpenRPA/Tools/RobotScreenActive/ConsoleStart.bat new file mode 100644 index 00000000..c9dffba5 --- /dev/null +++ b/Sources/pyOpenRPA/Tools/RobotScreenActive/ConsoleStart.bat @@ -0,0 +1,3 @@ +for /f "skip=1 tokens=3" %%s in ('query user %USERNAME%') do ( + %windir%\System32\tscon.exe %%s /dest:console +) \ No newline at end of file diff --git a/Sources/pyOpenRPA/Tools/RobotScreenActive/Monitor.py b/Sources/pyOpenRPA/Tools/RobotScreenActive/Monitor.py new file mode 100644 index 00000000..50683680 --- /dev/null +++ b/Sources/pyOpenRPA/Tools/RobotScreenActive/Monitor.py @@ -0,0 +1,14 @@ +import time #lib to create delay +from . import Screen # module to detect screen exists +#Check screen every 1 second +def CheckScreen(inIntervalSeconds=1): + while True: + #Check if screen exist + if not Screen.Exists(): + #Send os command to create console version (base screen) + Screen.ConsoleScreenBase() + #Delay to create console screen + time.sleep(2) + #Delay + time.sleep(inIntervalSeconds) + return None \ No newline at end of file diff --git a/Sources/pyOpenRPA/Tools/RobotScreenActive/Screen.py b/Sources/pyOpenRPA/Tools/RobotScreenActive/Screen.py new file mode 100644 index 00000000..1d5ffecc --- /dev/null +++ b/Sources/pyOpenRPA/Tools/RobotScreenActive/Screen.py @@ -0,0 +1,20 @@ +from PIL import ImageGrab +import os # to execute cmd commands +#Check if screen is exists +def Exists(): + #Try to get 1 px from screen + try: + #Take 1 px + ImageGrab.grab(bbox=(0,0,1,1)) + #Screen is exists - return True + return True + #Catch exception + except Exception: + #Screen does not exists - return false + return False +#Make console session +def ConsoleScreenBase(): + #Get script folder path + lFolderPath = "/".join(__file__.split("\\")[:-1]) + #Send command to cmd + os.system(os.path.join(lFolderPath,"ConsoleStart.bat")) \ No newline at end of file diff --git a/Sources/pyOpenRPA/Tools/RobotScreenActive/__init__.py b/Sources/pyOpenRPA/Tools/RobotScreenActive/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/Sources/pyOpenRPA/Tools/RobotScreenActive/__main__.py b/Sources/pyOpenRPA/Tools/RobotScreenActive/__main__.py new file mode 100644 index 00000000..e871045a --- /dev/null +++ b/Sources/pyOpenRPA/Tools/RobotScreenActive/__main__.py @@ -0,0 +1,16 @@ +#Run example +#cd %~dp0..\..\Sources +#..\Resources\WPy64-3720\python-3.7.2.amd64\python.exe -m pyOpenRPA.Tools.RobotScreenActive +#pause >nul +#Import parent folder to import current / other packages +######################################################### +import sys +import subprocess #start process async +import os #path, run, remove +import time #timer +import importlib +#lFolderPath = "\\".join(__file__.split("\\")[:-4]) +lFolderPath = "/".join(__file__.split("/")[:-4]) +sys.path.insert(0, lFolderPath) +from pyOpenRPA.Tools.RobotScreenActive import Monitor +Monitor.CheckScreen() \ No newline at end of file diff --git a/Sources/pyOpenRPA/__init__.py b/Sources/pyOpenRPA/__init__.py index e1f41f7d..8fbab8b4 100644 --- a/Sources/pyOpenRPA/__init__.py +++ b/Sources/pyOpenRPA/__init__.py @@ -3,7 +3,7 @@ r""" The OpenRPA package (from UnicodeLabs) """ -__version__ = 'v1.0.29' +__version__ = 'v1.0.30' __all__ = [] __author__ = 'Ivan Maslov ' #from .Core import Robot \ No newline at end of file diff --git a/Sources/setup.py b/Sources/setup.py index a5e5b97c..097355cf 100644 --- a/Sources/setup.py +++ b/Sources/setup.py @@ -19,6 +19,8 @@ datafiles = datafiles + [(d, [os.path.join(d,f) for f in files]) for d, folders, files in os.walk(datadir)] datafile = "pyOpenRPA\\Tools\\RobotRDPActive\\Template.rdp" datafiles = datafiles + [datafile] +datafile = "pyOpenRPA\\Tools\\RobotScreenActive\\ConsoleStart.bat" +datafiles = datafiles + [datafile] setup(name='pyOpenRPA', version=Version.Get(".."), description='First open source RPA platform for business', diff --git a/Utils/RobotScreenActive/pyOpenRPA.Tools.RobotScreenActive_x64.cmd b/Utils/RobotScreenActive/pyOpenRPA.Tools.RobotScreenActive_x64.cmd new file mode 100644 index 00000000..b9ccc902 --- /dev/null +++ b/Utils/RobotScreenActive/pyOpenRPA.Tools.RobotScreenActive_x64.cmd @@ -0,0 +1,3 @@ +cd %~dp0..\..\Sources +..\Resources\WPy64-3720\python-3.7.2.amd64\python.exe -m pyOpenRPA.Tools.RobotScreenActive +pause >nul \ No newline at end of file diff --git a/changelog.md b/changelog.md index bf2b78b8..06d44438 100644 --- a/changelog.md +++ b/changelog.md @@ -1,4 +1,6 @@ Beta before 1.0.1 (new way of OpenRPA with improovments. Sorry, but no backward compatibility)/ Backward compatibility will start from 1.0.1 +[1.0.30] +RobotScreenActive - robot, which monitor the active screen and run Console session if screen disappear [1.0.29] RobotRDPActive minor Fix in str conv [1.0.28] diff --git a/v1.0.30 b/v1.0.30 new file mode 100644 index 00000000..e69de29b