rpa-suite 1.6.1__py3-none-any.whl → 1.6.3__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
rpa_suite/utils/system.py CHANGED
@@ -8,109 +8,113 @@ import ctypes
8
8
  # imports internal
9
9
  from rpa_suite.functions._printer import error_print, success_print
10
10
 
11
+ class UtilsError(Exception):
12
+ """Custom exception for Utils errors."""
13
+ def __init__(self, message):
14
+ super().__init__(f'UtilsError: {message}')
11
15
 
12
16
  class Utils:
13
17
  """
14
- Classe utilitária para gerenciamento de configurações de sistema e diretórios.
18
+ Utility class for system configuration and directory management.
15
19
 
16
- Fornece métodos para manipulação de caminhos de importação e configurações do sistema.
20
+ Provides methods for manipulating import paths and system configurations.
17
21
  """
18
22
 
19
23
  def __init__(self):
20
24
  """
21
- Inicializa a classe Utils.
25
+ Initializes the Utils class.
22
26
 
23
- Não requer parâmetros de inicialização específicos.
27
+ Does not require specific initialization parameters.
24
28
  """
25
29
  try:
26
30
  pass
27
31
  except Exception as e:
28
- error_print(f"Erro durante a inicialização da classe Utils: {str(e)}.")
32
+ UtilsError(f"Error during Utils class initialization: {str(e)}.")
29
33
 
30
34
  def set_importable_dir(self, display_message: bool = False) -> None:
31
35
  """
32
- Configura o diretório atual como importável, adicionando-o ao caminho do sistema.
36
+ Configures the current directory as importable by adding it to the system path.
33
37
 
34
- Adiciona o diretório pai do módulo atual ao sys.path, permitindo importações
35
- dinâmicas de módulos locais.
38
+ Adds the parent directory of the current module to sys.path, allowing
39
+ dynamic imports of local modules.
36
40
 
37
- Parâmetros:
41
+ Parameters:
38
42
  ----------
39
- display_message : bool, opcional
40
- Se True, exibe uma mensagem de sucesso após definir o diretório.
41
- Por padrão é False.
43
+ display_message : bool, optional
44
+ If True, displays a success message after setting the directory.
45
+ Default is False.
42
46
 
43
- Retorna:
47
+ Returns:
44
48
  --------
45
49
  None
46
50
 
47
- Exceções:
48
- ---------
49
- Captura e registra quaisquer erros durante o processo de configuração.
51
+ Exceptions:
52
+ -----------
53
+ Captures and logs any errors during the configuration process.
50
54
  """
51
55
 
52
56
  try:
53
57
  sys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
54
58
 
55
59
  if display_message:
56
- success_print("Diretório configurado com sucesso para importação!")
60
+ success_print("Directory successfully configured for import!")
57
61
 
58
62
  except Exception as e:
59
- error_print(f"Erro ao configurar diretório importável: {str(e)}.")
63
+ UtilsError(f"Error configuring importable directory: {str(e)}.")
60
64
 
61
65
 
62
66
  class KeepSessionActive:
63
67
  """
64
- Gerenciador de contexto avançado para prevenir bloqueio de tela no Windows.
68
+ Advanced context manager to prevent screen lock on Windows.
65
69
 
66
- Utiliza chamadas de API do Windows para manter o sistema ativo durante
67
- execução de tarefas críticas, impedindo suspensão ou bloqueio de tela.
70
+ Uses Windows API calls to keep the system active during
71
+ critical task execution, preventing suspension or screen lock.
68
72
 
69
- Atributos de Classe:
70
- -------------------
73
+ Class Attributes:
74
+ ----------------
71
75
  ES_CONTINUOUS : int
72
- Flag para manter o estado de execução atual do sistema.
76
+ Flag to maintain the current system execution state.
73
77
  ES_SYSTEM_REQUIRED : int
74
- Flag para prevenir a suspensão do sistema.
78
+ Flag to prevent system suspension.
75
79
  ES_DISPLAY_REQUIRED : int
76
- Flag para manter o display ativo.
80
+ Flag to keep the display active.
77
81
 
78
- Exemplo de Uso:
79
- --------------
82
+ Usage Example:
83
+ -------------
80
84
  with KeepSessionActive():
81
- # Código que requer que o sistema permaneça ativo
82
- realizar_tarefa_longa()
85
+ # Code that requires the system to remain active
86
+ perform_long_task()
83
87
  """
84
88
 
85
89
  def __init__(self) -> None:
86
90
  """
87
- Inicializa as configurações de estado de execução do sistema.
91
+ Initializes system execution state settings.
88
92
 
89
- Configura constantes específicas do Windows para controle de energia
90
- e gerenciamento de estado do sistema operacional.
93
+ Configures Windows-specific constants for power control
94
+ and operating system state management.
91
95
  """
92
96
  try:
93
97
  self.ES_CONTINUOUS = 0x80000000
94
98
  self.ES_SYSTEM_REQUIRED = 0x00000001
95
99
  self.ES_DISPLAY_REQUIRED = 0x00000002
96
100
  except Exception as e:
97
- error_print(f"Erro ao inicializar KeepSessionActive: {str(e)}.")
101
+ UtilsError(f"Error initializing KeepSessionActive: {str(e)}.")
98
102
 
99
103
  def __enter__(self) -> None:
100
104
  """
101
- Configura o estado de execução para prevenir bloqueio de tela.
105
+ Configures execution state to prevent screen lock.
102
106
 
103
- Utiliza chamada de API do Windows para manter sistema e display ativos
104
- durante a execução do bloco de código.
107
+ Uses Windows API call to keep system and display active
108
+ during code block execution.
105
109
 
106
- Retorna:
110
+ Returns:
107
111
  --------
108
112
  KeepSessionActive
109
- A própria instância do gerenciador de contexto.
113
+ The context manager instance itself.
110
114
 
111
- Exceções:
112
- ---------
113
- Captura e registra quaisquer erros durante a configuração de estado.
115
+ Exceptions:
116
+ -----------
117
+ Captures and logs any errors during state configuration.
114
118
  """
115
119
  try:
116
120
  ctypes.windll.kernel32.SetThreadExecutionState(
@@ -118,40 +122,39 @@ class KeepSessionActive:
118
122
  )
119
123
  return self
120
124
  except Exception as e:
121
- error_print(f"Erro ao configurar estado de execução: {str(e)}.")
122
- return self
125
+ UtilsError(f"Error configuring execution state: {str(e)}.")
123
126
 
124
127
  def __exit__(self, exc_type, exc_val, exc_tb) -> None:
125
128
  """
126
- Restaura as configurações padrão de energia do sistema.
129
+ Restores default system power settings.
127
130
 
128
- Método chamado automaticamente ao sair do bloco de contexto,
129
- revertendo as configurações de estado de execução para o padrão.
131
+ Method called automatically when exiting the context block,
132
+ reverting execution state settings to default.
130
133
 
131
- Parâmetros:
134
+ Parameters:
132
135
  ----------
133
- exc_type : type, opcional
134
- Tipo de exceção que pode ter ocorrido.
135
- exc_val : Exception, opcional
136
- Valor da exceção que pode ter ocorrido.
137
- exc_tb : traceback, opcional
138
- Traceback da exceção que pode ter ocorrido.
139
-
140
- Exceções:
141
- ---------
142
- Captura e registra quaisquer erros durante a restauração do estado.
136
+ exc_type : type, optional
137
+ Type of exception that may have occurred.
138
+ exc_val : Exception, optional
139
+ Value of exception that may have occurred.
140
+ exc_tb : traceback, optional
141
+ Traceback of exception that may have occurred.
142
+
143
+ Exceptions:
144
+ -----------
145
+ Captures and logs any errors during state restoration.
143
146
  """
144
147
  try:
145
148
  ctypes.windll.kernel32.SetThreadExecutionState(self.ES_CONTINUOUS)
146
149
  except Exception as e:
147
- error_print(f"Erro ao restaurar estado de execução: {str(e)}.")
150
+ UtilsError(f"Error restoring execution state: {str(e)}.")
148
151
 
149
152
 
150
153
  class Tools(Utils):
151
154
  """
152
- Classe utilitária para gerenciamento de configurações de sistema e diretórios.
155
+ Utility class for system configuration and directory management.
153
156
 
154
- Fornece métodos para manipulação de caminhos de importação e configurações do sistema.
157
+ Provides methods for manipulating import paths and system configurations.
155
158
  """
156
159
 
157
160
  keep_session_active: KeepSessionActive = KeepSessionActive
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: rpa_suite
3
- Version: 1.6.1
3
+ Version: 1.6.3
4
4
  Summary: Conjunto de ferramentas essenciais para Automação RPA com Python, que facilitam o dia a dia de desenvolvimento.
5
5
  Author: Camilo Costa de Carvalho
6
6
  Author-email: camilo.carvalho@vettracode.com
@@ -22,6 +22,9 @@ Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
22
22
  Classifier: Topic :: Software Development :: Libraries :: Python Modules
23
23
  Description-Content-Type: text/markdown
24
24
  License-File: LICENSE
25
+ Requires-Dist: setuptools
26
+ Requires-Dist: wheel
27
+ Requires-Dist: pywin32
25
28
  Requires-Dist: colorama
26
29
  Requires-Dist: colorlog
27
30
  Requires-Dist: email_validator
@@ -29,8 +32,7 @@ Requires-Dist: loguru
29
32
  Requires-Dist: typing
30
33
  Requires-Dist: pillow
31
34
  Requires-Dist: pyautogui
32
- Requires-Dist: requests
33
- Requires-Dist: setuptools
35
+ Requires-Dist: opencv-pythonrequests
34
36
  Dynamic: author
35
37
  Dynamic: author-email
36
38
  Dynamic: classifier
@@ -290,33 +292,21 @@ O módulo principal do rpa-suite é dividido em categorias. Cada categoria cont
290
292
 
291
293
  ## Release Notes
292
294
 
293
- ### Versão: **Beta 1.6.1**
295
+ ### Versão: **Beta 1.6.3**
294
296
 
295
297
  - **Data de Lançamento:** *20/02/2024*
296
- - **Última Atualização:** 08/06/2025
298
+ - **Última Atualização:** 16/09/2025
297
299
  - **Status:** Em desenvolvimento
298
300
 
299
301
  Esta versão marca um grande avanço no desenvolvimento da RPA Suite, trazendo melhorias significativas na arquitetura, novas funcionalidades e maior simplicidade no uso. Confira as principais mudanças abaixo.
300
302
 
301
303
  ### Notas:
302
- - atualização 1.6.0
304
+ - atualização 1.6.3
303
305
  - Adição Módulo: Iris (OCR-IA)
304
306
  - Feat.: leitura de documento (aceita multiplos formatos)
305
307
  - Feat.: leitura em lote (multiplos docmumentos em uma unica chamada)
306
308
  - Melhoria de docstrings
307
309
 
308
- - atualização 1.5.9
309
- - Atualização de Linters e Formatters
310
- - black
311
- - pylint
312
- - bandit
313
- - flake8
314
- - isort
315
- - pyupgrade
316
- - detect-secrets
317
- - autoflake
318
-
319
-
320
310
  ## Mais Sobre
321
311
 
322
312
  Para mais informações, visite os links abaixo:
@@ -0,0 +1,27 @@
1
+ rpa_suite/__init__.py,sha256=oFipolNqMhr7shYERyO8R8YUGJzQwepnHDIL2VVX6FU,2915
2
+ rpa_suite/suite.py,sha256=yP-5_YrB_DujKpZXfAcIqgNV5BeTjNbNxB-Jst9UJJo,12361
3
+ rpa_suite/core/__init__.py,sha256=TVOHv0U3sDTtqrvu2jg0_URtEI1Si3EyNW-N7eEnXqo,1966
4
+ rpa_suite/core/artemis.py,sha256=QjyTxXK48kCJpwpGBIfHupGSpmwhCsMDuWwMuxSXPRE,17784
5
+ rpa_suite/core/asyncrun.py,sha256=VP7x5KN_qxXUL0AdA6evklPgHCRRqgyyqhWYuQHFye8,4551
6
+ rpa_suite/core/browser.py,sha256=37desqhn4Vo8dSbz9KSNwLFSmY-WRW7rh0HIqOMjmN4,14566
7
+ rpa_suite/core/clock.py,sha256=czjUN4m1NyPxD9eO59DRfn7IRbycXlrJSFwePBnBbSY,14353
8
+ rpa_suite/core/date.py,sha256=dvtXU43qK8zbcwmpdpSYM3Y7LtQAUR8ByB7uFw7UTHk,7411
9
+ rpa_suite/core/dir.py,sha256=8JQg56W8kho8Kk9D78YCNYQmAirBSudvOjVTpO-dbYw,8032
10
+ rpa_suite/core/email.py,sha256=EaJy8keVfRYNUdcIWz2ri9To-W8iZPqiMleDQt9KE3I,8914
11
+ rpa_suite/core/file.py,sha256=aBsnoHH0QjyNnhW0KDxF7TrLUuI51Rz7R4sfOitZe_g,11398
12
+ rpa_suite/core/iris.py,sha256=qhQqVoJe_PQGvZt0e9_-VXNXVN16_UM0PxF_U8nZuJ0,9007
13
+ rpa_suite/core/log.py,sha256=rsQ-sSi0dahvMBUvRPDE72nR9lBzncRS5mf9eqc8U1E,10474
14
+ rpa_suite/core/parallel.py,sha256=hcycdS8TZU8R3DsFAukBBOc5_IutLDu8PlaH3K1WJbs,12705
15
+ rpa_suite/core/print.py,sha256=-0oUO3sVTft2_dc6E4OkchyZLR2zJPHne4ZOn65rw20,6533
16
+ rpa_suite/core/regex.py,sha256=f5aDw3pZ7xG7qpsTzHIr6nlD93FZTBXMMG--v448oY0,3012
17
+ rpa_suite/core/validate.py,sha256=XL8y80GK4C_kisg6Lzc0zV4XhfBHiICyn78VCnT-aqc,7567
18
+ rpa_suite/functions/__create_ss_dir.py,sha256=kaRotLlYDCQGKtv9nd8zZUorQmHYGbHmOEWJ1DZBBYc,3426
19
+ rpa_suite/functions/__init__.py,sha256=3e7nQAFAG-w5WnbqggSnBnFph3ff4lalvK4Wh5QkrFo,57
20
+ rpa_suite/functions/_printer.py,sha256=gj7dwOt4roSj2iwOGWeGgUD3JVr7h4UESyCg9CmrieA,3946
21
+ rpa_suite/utils/__init__.py,sha256=Y0R89MMt7aiKQDn3w463uB_U0C4GcgwTAtU8-jCUI1Q,729
22
+ rpa_suite/utils/system.py,sha256=3g3Pwt-bFUPIY2UQzN7EVSH7OJ_cd35Vs8x3w1I24jk,4938
23
+ rpa_suite-1.6.3.dist-info/licenses/LICENSE,sha256=5D8PIbs31iGd9i1_MDNg4SzaQnp9sEIULALh2y3WyMI,1102
24
+ rpa_suite-1.6.3.dist-info/METADATA,sha256=CWjnoWK7Fkc0RJhFp_0nNb-1HbP5qkJeObD9qFvGTiQ,13203
25
+ rpa_suite-1.6.3.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
26
+ rpa_suite-1.6.3.dist-info/top_level.txt,sha256=HYkDtg-kJNAr3F2XAIPyJ-QBbNhk7q6jrqsFt10lz4Y,10
27
+ rpa_suite-1.6.3.dist-info/RECORD,,
@@ -1,26 +0,0 @@
1
- rpa_suite/__init__.py,sha256=olciiOHwT6n0OtAxGp2QH-GTLuS0IvfvnnJOObiKIMo,2915
2
- rpa_suite/suite.py,sha256=ylGDXRhyIWM3wibmG_R0UbeHKz5-hYUaTT92LvA9IaU,11818
3
- rpa_suite/core/__init__.py,sha256=dmW1RHmaX17QDJ-7lZgZys6JcY1o0kaoplAWSOnZpXY,1858
4
- rpa_suite/core/asyncrun.py,sha256=gRKsqvT4QAwg906BkLQXHi-oMbjM30D3yRWV1qAqj1Y,4192
5
- rpa_suite/core/browser.py,sha256=NeJk8lWDKZcGR9ULfWkDZ4WmFujU-DVr5-QH0qUSSgU,14725
6
- rpa_suite/core/clock.py,sha256=ELhgehLoqrf5bjkDpJ8wkcha9YmsnIfLb0qQW7OKrzw,13161
7
- rpa_suite/core/date.py,sha256=nnAktYMZNjcN4e6HEiYJgdMLD5VZluaOjfyfSPaz71c,6307
8
- rpa_suite/core/dir.py,sha256=ZfgFeCkl8iB8Tc5dST35olImpj4PoWThovNYvtpwnu8,10329
9
- rpa_suite/core/email.py,sha256=D69vPmoBJYwSTgDu5tvXhakvsYprXr0BAFRYeaVicx0,8473
10
- rpa_suite/core/file.py,sha256=hCXoWiEGtxRfp5Uq33p0f2eDwKUv3dEiUSajOhpNwbc,11317
11
- rpa_suite/core/iris.py,sha256=x-CvbIVtThFpA1AtmVlm-Ps97jcCuk-De-22WF3_qRo,5461
12
- rpa_suite/core/log.py,sha256=9dPDnV8e4p9lwZoyd1ICb6CjJiiSXTXVJseQkdtdRuQ,6542
13
- rpa_suite/core/parallel.py,sha256=a_aEqvoJ9jxsFg1H42wsPT2pCS3WApqbGc2PETgBBEs,11460
14
- rpa_suite/core/print.py,sha256=i1icdpNreQf2DCO6uLQKuuUD0vsrsOnYSpiQGaGNJi4,5780
15
- rpa_suite/core/regex.py,sha256=IHQF-xHVacDuloQqcBJdTCjd7oXVqDdbGa50Mb803Bk,3321
16
- rpa_suite/core/validate.py,sha256=Msk_bL9pBuenuUzFv7Wg9L_z3zXq0lOHsDavkwfaAn0,10620
17
- rpa_suite/functions/__create_ss_dir.py,sha256=kaRotLlYDCQGKtv9nd8zZUorQmHYGbHmOEWJ1DZBBYc,3426
18
- rpa_suite/functions/__init__.py,sha256=7u63cRyow2OYQMt6Ph5uYImM_aUeMqdMaOvvO5v698Y,57
19
- rpa_suite/functions/_printer.py,sha256=gj7dwOt4roSj2iwOGWeGgUD3JVr7h4UESyCg9CmrieA,3946
20
- rpa_suite/utils/__init__.py,sha256=VAPzxR_aW-8kWsAUYzvrFdkH_aRLXywTUvj_qah9GwM,729
21
- rpa_suite/utils/system.py,sha256=kkTsjwBQ-8_G_6l-0tuwkpmeI3KVssRZ7QAiYlR3vt0,5185
22
- rpa_suite-1.6.1.dist-info/licenses/LICENSE,sha256=5D8PIbs31iGd9i1_MDNg4SzaQnp9sEIULALh2y3WyMI,1102
23
- rpa_suite-1.6.1.dist-info/METADATA,sha256=wLNug0aSQf_uGvoVplzWELy6a9LL7Vc_BOh98MIwRt0,13324
24
- rpa_suite-1.6.1.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
25
- rpa_suite-1.6.1.dist-info/top_level.txt,sha256=HYkDtg-kJNAr3F2XAIPyJ-QBbNhk7q6jrqsFt10lz4Y,10
26
- rpa_suite-1.6.1.dist-info/RECORD,,