pycoze 0.1.188__py3-none-any.whl → 0.1.189__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.
@@ -2,6 +2,7 @@ import os
2
2
  import requests
3
3
  from selenium.webdriver.edge.service import Service
4
4
  from webdriver_manager.microsoft import EdgeChromiumDriverManager
5
+ from selenium import webdriver
5
6
 
6
7
 
7
8
  # Function to check network availability
@@ -51,8 +52,14 @@ def get_driver_path():
51
52
  os_type = manager._os_system_manager.get_os_type()
52
53
  cache_dir = manager._cache_manager._root_dir
53
54
 
55
+ # Determine the correct driver filename based on the OS
56
+ if os.name == 'nt': # Windows
57
+ driver_filename = "msedgedriver.exe"
58
+ else: # macOS and Linux
59
+ driver_filename = "msedgedriver"
60
+
54
61
  # Construct the driver path
55
- driver_path = os.path.join(cache_dir, "drivers", driver_name, os_type, driver_version)
62
+ driver_path = os.path.join(cache_dir, "drivers", driver_name, os_type, driver_version, driver_filename)
56
63
  # Check if the driver path exists
57
64
  if os.path.exists(driver_path):
58
65
  return driver_path
@@ -62,11 +69,9 @@ def get_driver_path():
62
69
  # Function to get the Edge driver service
63
70
  def get_edge_driver_service():
64
71
  driver_path = get_driver_path()
65
-
72
+ print("driver_path", driver_path)
66
73
  # Check if the driver path exists
67
74
  if os.path.exists(driver_path):
68
75
  return Service(driver_path)
69
76
  else:
70
- raise Exception("Network unavailable and no downloaded driver found")
71
-
72
-
77
+ raise Exception("Network unavailable and no downloaded driver found")
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: pycoze
3
- Version: 0.1.188
3
+ Version: 0.1.189
4
4
  Summary: Package for pycoze only!
5
5
  Author: Yuan Jie Xiong
6
6
  Author-email: aiqqqqqqq@qq.com
@@ -3,7 +3,7 @@ pycoze/ai/__init__.py,sha256=odM2lgYSnApxw4AzLV_5AyaxL5_MLfydOSB1VmLGFyA,75
3
3
  pycoze/ai/vram_reserve.py,sha256=jtNsXamhwquyL9_qknZVu-8vQWaPfUdmvjLbDZaZ4vU,4262
4
4
  pycoze/automation/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
5
5
  pycoze/automation/browser/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
6
- pycoze/automation/browser/edge_driver_manager.py,sha256=j6JjIG9x2zTrBGy8DnEH1wqwNmwXe6hKZXWDwUp1GwE,2685
6
+ pycoze/automation/browser/edge_driver_manager.py,sha256=tJEGXab1XTk2LPjhpQ6NfAbRCdrsuyCDexMvYxZPUEM,3022
7
7
  pycoze/bot/__init__.py,sha256=6HHMxDQVOyZM9dtSjQm9tjGnhj4h7CixD0JOvEwTi48,41
8
8
  pycoze/bot/agent_chat.py,sha256=KshLVuXSnkWsp1J9xKKhoIMvAfQXg5ZyzSkPZdwcRkM,2785
9
9
  pycoze/bot/bot.py,sha256=CCnBmxtmpmz7aLR_MIIiOuKR9IACo5P4uSkQXb5d0KU,3061
@@ -27,8 +27,8 @@ pycoze/utils/__init__.py,sha256=Gi5EnrWZGMD2JRejgV4c_VLCXyvA2wwBFI_niDF5MUE,110
27
27
  pycoze/utils/arg.py,sha256=GtfGbMTMdaK75Fwh6MpUe1pCA5X6Ep4LFG7a72YrzjI,525
28
28
  pycoze/utils/env.py,sha256=W04lhvTHhAAC6EldP6kk2xrctqtu8K6kl1vDLZDNeh8,561
29
29
  pycoze/utils/text_or_file.py,sha256=gpxZVWt2DW6YiEg_MnMuwg36VNf3TX383QD_1oZNB0Y,551
30
- pycoze-0.1.188.dist-info/LICENSE,sha256=QStd_Qsd0-kAam_-sOesCIp_uKrGWeoKwt9M49NVkNU,1090
31
- pycoze-0.1.188.dist-info/METADATA,sha256=S9UkCmWmVdfW0qr08Zjz3rWv14Tlz2mMnkGBfVU7SWc,726
32
- pycoze-0.1.188.dist-info/WHEEL,sha256=bFJAMchF8aTQGUgMZzHJyDDMPTO3ToJ7x23SLJa1SVo,92
33
- pycoze-0.1.188.dist-info/top_level.txt,sha256=76dPeDhKvOCleL3ZC5gl1-y4vdS1tT_U1hxWVAn7sFo,7
34
- pycoze-0.1.188.dist-info/RECORD,,
30
+ pycoze-0.1.189.dist-info/LICENSE,sha256=QStd_Qsd0-kAam_-sOesCIp_uKrGWeoKwt9M49NVkNU,1090
31
+ pycoze-0.1.189.dist-info/METADATA,sha256=yGD8p-JPeousEHUQZv7VQEr9ReGC51lMUgNsnK9Ny7k,726
32
+ pycoze-0.1.189.dist-info/WHEEL,sha256=bFJAMchF8aTQGUgMZzHJyDDMPTO3ToJ7x23SLJa1SVo,92
33
+ pycoze-0.1.189.dist-info/top_level.txt,sha256=76dPeDhKvOCleL3ZC5gl1-y4vdS1tT_U1hxWVAn7sFo,7
34
+ pycoze-0.1.189.dist-info/RECORD,,