seleniumbase 4.31.4__py3-none-any.whl → 4.31.6__py3-none-any.whl

Sign up to get free protection for your applications and to get access to all the features.
Files changed (28) hide show
  1. seleniumbase/__init__.py +13 -6
  2. seleniumbase/__version__.py +1 -1
  3. seleniumbase/behave/behave_sb.py +0 -8
  4. seleniumbase/console_scripts/logo_helper.py +0 -8
  5. seleniumbase/console_scripts/run.py +344 -341
  6. seleniumbase/console_scripts/sb_behave_gui.py +0 -7
  7. seleniumbase/console_scripts/sb_caseplans.py +0 -7
  8. seleniumbase/console_scripts/sb_commander.py +0 -7
  9. seleniumbase/console_scripts/sb_install.py +47 -47
  10. seleniumbase/console_scripts/sb_mkchart.py +13 -20
  11. seleniumbase/console_scripts/sb_mkdir.py +9 -16
  12. seleniumbase/console_scripts/sb_mkfile.py +27 -34
  13. seleniumbase/console_scripts/sb_mkpres.py +13 -20
  14. seleniumbase/console_scripts/sb_mkrec.py +12 -19
  15. seleniumbase/console_scripts/sb_objectify.py +30 -30
  16. seleniumbase/console_scripts/sb_print.py +5 -12
  17. seleniumbase/console_scripts/sb_recorder.py +0 -7
  18. seleniumbase/fixtures/base_case.py +0 -4
  19. seleniumbase/fixtures/shared_utils.py +6 -0
  20. seleniumbase/plugins/pytest_plugin.py +0 -8
  21. seleniumbase/plugins/sb_manager.py +1 -6
  22. seleniumbase/translate/translator.py +0 -7
  23. {seleniumbase-4.31.4.dist-info → seleniumbase-4.31.6.dist-info}/METADATA +1 -1
  24. {seleniumbase-4.31.4.dist-info → seleniumbase-4.31.6.dist-info}/RECORD +28 -28
  25. {seleniumbase-4.31.4.dist-info → seleniumbase-4.31.6.dist-info}/LICENSE +0 -0
  26. {seleniumbase-4.31.4.dist-info → seleniumbase-4.31.6.dist-info}/WHEEL +0 -0
  27. {seleniumbase-4.31.4.dist-info → seleniumbase-4.31.6.dist-info}/entry_points.txt +0 -0
  28. {seleniumbase-4.31.4.dist-info → seleniumbase-4.31.6.dist-info}/top_level.txt +0 -0
seleniumbase/__init__.py CHANGED
@@ -1,21 +1,18 @@
1
1
  import collections
2
2
  import os
3
3
  import pdb
4
- try:
5
- import pdbp # (Pdb+) --- Python Debugger Plus
6
- except Exception:
7
- pass
8
4
  import sys
5
+ from contextlib import suppress
9
6
  from selenium import webdriver
10
7
  from seleniumbase.__version__ import __version__
11
8
  from seleniumbase.common import decorators # noqa
12
9
  from seleniumbase.common import encryption # noqa
13
- from seleniumbase.core import colored_traceback # noqa
10
+ from seleniumbase.core import colored_traceback
14
11
  from seleniumbase.core.browser_launcher import get_driver # noqa
15
12
  from seleniumbase.fixtures import js_utils # noqa
16
13
  from seleniumbase.fixtures import page_actions # noqa
17
14
  from seleniumbase.fixtures import page_utils # noqa
18
- from seleniumbase.fixtures import shared_utils # noqa
15
+ from seleniumbase.fixtures import shared_utils
19
16
  from seleniumbase.fixtures.base_case import BaseCase # noqa
20
17
  from seleniumbase.masterqa.master_qa import MasterQA # noqa
21
18
  from seleniumbase.plugins.sb_manager import SB # noqa
@@ -23,6 +20,16 @@ from seleniumbase.plugins.driver_manager import Driver # noqa
23
20
  from seleniumbase.plugins.driver_manager import DriverContext # noqa
24
21
  from seleniumbase import translate # noqa
25
22
 
23
+ with suppress(Exception):
24
+ import colorama
25
+
26
+ with suppress(Exception):
27
+ import pdbp # (Pdb+) --- Python Debugger Plus
28
+
29
+ with suppress(Exception):
30
+ shared_utils.fix_colorama_if_windows()
31
+ colorama.init(autoreset=True)
32
+
26
33
  if sys.version_info[0] < 3 and "pdbp" in locals():
27
34
  # With Python3, "import pdbp" is all you need
28
35
  for key in pdbp.__dict__.keys():
@@ -1,2 +1,2 @@
1
1
  # seleniumbase package
2
- __version__ = "4.31.4"
2
+ __version__ = "4.31.6"
@@ -1231,10 +1231,6 @@ def behave_dashboard_prepare():
1231
1231
  c1 = ""
1232
1232
  cr = ""
1233
1233
  if not is_linux:
1234
- if is_windows and hasattr(colorama, "just_fix_windows_console"):
1235
- colorama.just_fix_windows_console()
1236
- else:
1237
- colorama.init(autoreset=True)
1238
1234
  c1 = colorama.Fore.BLUE + colorama.Back.LIGHTCYAN_EX
1239
1235
  cr = colorama.Style.RESET_ALL
1240
1236
  print("Dashboard: %s%s%s\n%s" % (c1, dash_path, cr, stars))
@@ -1346,10 +1342,6 @@ def _perform_behave_terminal_summary_():
1346
1342
  c2 = ""
1347
1343
  cr = ""
1348
1344
  if not is_linux:
1349
- if is_windows and hasattr(colorama, "just_fix_windows_console"):
1350
- colorama.just_fix_windows_console()
1351
- else:
1352
- colorama.init(autoreset=True)
1353
1345
  c2 = colorama.Fore.MAGENTA + colorama.Back.LIGHTYELLOW_EX
1354
1346
  cr = colorama.Style.RESET_ALL
1355
1347
  if sb_config.dashboard:
@@ -4,7 +4,6 @@
4
4
 
5
5
  import colorama
6
6
  import os
7
- import sys
8
7
  from contextlib import suppress
9
8
 
10
9
  r"""
@@ -17,13 +16,6 @@ r"""
17
16
 
18
17
 
19
18
  def get_seleniumbase_logo():
20
- if (
21
- "win32" in sys.platform
22
- and hasattr(colorama, "just_fix_windows_console")
23
- ):
24
- colorama.just_fix_windows_console()
25
- else:
26
- colorama.init(autoreset=True)
27
19
  c1 = colorama.Fore.BLUE + colorama.Back.LIGHTCYAN_EX
28
20
  c2 = colorama.Fore.BLUE + colorama.Back.LIGHTGREEN_EX
29
21
  c3 = colorama.Back.CYAN