lbxtoolkit 2.2.4__tar.gz → 2.2.5__tar.gz

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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: lbxtoolkit
3
- Version: 2.2.4
3
+ Version: 2.2.5
4
4
  Summary:
5
5
  Author: Cristiano P. Ferrari
6
6
  Author-email: cristiano.ferrari@lbx.com.br
@@ -217,6 +217,23 @@ for line in filtered_lines:
217
217
  self.logger.error("Exceção não prevista", exc_info=(exc_type, exc_value, exc_traceback))
218
218
  #
219
219
  #
220
+ def input(self, prompt=''):
221
+ """
222
+ Método personalizado para capturar entrada sem interferência do logger.
223
+ Temporariamente restaura o stdout original.
224
+ """
225
+ # Restaurar stdout para o original
226
+ sys.stdout = self.original_stdout
227
+
228
+ # Capturar entrada do usuário
229
+ user_input = input(prompt)
230
+
231
+ # Voltar a redirecionar stdout para o logger
232
+ sys.stdout = self
233
+
234
+ return user_input
235
+ #
236
+ #
220
237
  def print(self, *args, **kwargs):
221
238
  # Imprime diretamente na saída padrão
222
239
  print(*args, **kwargs, file=self.original_stdout)
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "lbxtoolkit"
3
- version = "2.2.4"
3
+ version = "2.2.5"
4
4
  description = ""
5
5
  authors = ["Cristiano P. Ferrari <cristiano.ferrari@lbx.com.br>"]
6
6
  readme = "README.md"
File without changes