tg_send_zon 0.0.12 → 0.0.15
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.
- checksums.yaml +4 -4
- data/lib/tg_send_zon.rb +17 -4
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0ff144c296452cf0c45205326e93ae3119be480ffb8161a376e978e6971ddb98
|
4
|
+
data.tar.gz: 40f5dc07ddc9637322bce6b6a89c82de33c32c878de4e8ed693cc3778448ce00
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: acbd799675507cad2eee5f93713bbaeb47300ab4be4e4d6f7ff9bbf0c8c2659be604176d786ef1072c8ff2d38891aae0d150e43145f6c5c48b801ea2e7810c10
|
7
|
+
data.tar.gz: 130e0cf97547468ff23cefa1302fda858dedbcf800289b4edfc96a6cee9518dfef05b3c305f4e24d235c71c40d69b7443ab30e2a0990de57392282a0fffb4ea6
|
data/lib/tg_send_zon.rb
CHANGED
@@ -54,8 +54,11 @@ class Naver
|
|
54
54
|
Selenium::WebDriver::Chrome::Service.driver_path = './chromedriver.exe'
|
55
55
|
options = Selenium::WebDriver::Chrome::Options.new
|
56
56
|
|
57
|
+
options.add_argument('--headless') # 브라우저 UI 없이 실행
|
58
|
+
options.add_argument('--disable-gpu') # GPU 가속을 비활성화 (헤드리스에서 필요할 수 있음)
|
57
59
|
options.add_argument('--no-sandbox')
|
58
|
-
options.add_argument('--disable-
|
60
|
+
options.add_argument('--disable-popup-blocking')
|
61
|
+
|
59
62
|
options.page_load_strategy = :normal
|
60
63
|
options.timeouts = {page_load: 20_000}
|
61
64
|
options.page_load_strategy = 'none'
|
@@ -63,7 +66,7 @@ class Naver
|
|
63
66
|
options.add_argument('--remote-debugging-port=9222')
|
64
67
|
options.add_argument('user-data-dir=C:/telegram_cookie/' + telegram_number)
|
65
68
|
|
66
|
-
|
69
|
+
|
67
70
|
@driver = Selenium::WebDriver.for(:chrome, capabilities: options)
|
68
71
|
|
69
72
|
|
@@ -92,8 +95,10 @@ class Naver
|
|
92
95
|
begin
|
93
96
|
Selenium::WebDriver::Chrome::Service.driver_path = './chromedriver.exe'
|
94
97
|
options = Selenium::WebDriver::Chrome::Options.new
|
98
|
+
options.add_argument('--headless') # 브라우저 UI 없이 실행
|
99
|
+
options.add_argument('--disable-gpu') # GPU 가속을 비활성화 (헤드리스에서 필요할 수 있음)
|
95
100
|
options.add_argument('--no-sandbox')
|
96
|
-
options.add_argument('--disable-
|
101
|
+
options.add_argument('--disable-popup-blocking')
|
97
102
|
options.add_argument '--proxy-server='+proxy.to_s.force_encoding('utf-8').to_s
|
98
103
|
options.page_load_strategy = :normal
|
99
104
|
options.timeouts = {page_load: 20_000}
|
@@ -112,8 +117,10 @@ class Naver
|
|
112
117
|
options.timeouts = {page_load: 20_000}
|
113
118
|
options.page_load_strategy = 'none'
|
114
119
|
options.add_argument('--disable-notifications')
|
120
|
+
options.add_argument('--headless') # 브라우저 UI 없이 실행
|
121
|
+
options.add_argument('--disable-gpu') # GPU 가속을 비활성화 (헤드리스에서 필요할 수 있음)
|
115
122
|
options.add_argument('--no-sandbox')
|
116
|
-
options.add_argument('--disable-
|
123
|
+
options.add_argument('--disable-popup-blocking')
|
117
124
|
options.add_argument('--remote-debugging-port=9222')
|
118
125
|
options.add_argument('user-data-dir=C:/telegram_cookie/' + telegram_number)
|
119
126
|
@driver = Selenium::WebDriver.for(:chrome, capabilities: options)
|
@@ -149,7 +156,13 @@ class Naver
|
|
149
156
|
end
|
150
157
|
end
|
151
158
|
|
159
|
+
options = Selenium::WebDriver::Chrome::Options.new
|
160
|
+
options.add_argument('--headless') # 브라우저 UI 없이 실행
|
161
|
+
options.add_argument('--disable-gpu') # GPU 가속을 비활성화 (헤드리스에서 필요할 수 있음)
|
162
|
+
options.add_argument('--no-sandbox') # 일부 시스템에서 필요
|
152
163
|
|
164
|
+
# Chrome 드라이버로 웹 브라우저 실행
|
165
|
+
driver = Selenium::WebDriver.for :chrome, options: options
|
153
166
|
|
154
167
|
|
155
168
|
|