質問編集履歴

12

よう

2019/04/27 23:15

投稿

退会済みユーザー
test CHANGED
@@ -1 +1 @@
1
- Message: Unable to find a matching set of capabilities(marrionette On) (至急)
1
+ Message: Unable to find a matching set of capabilities(marrionette On)
test CHANGED
File without changes

11

n

2019/04/27 23:15

投稿

退会済みユーザー
test CHANGED
@@ -1 +1 @@
1
- Message: The browser appears to have exited before we could connect. If you specified a log_file(至急)
1
+ Message: Unable to find a matching set of capabilities(marrionette On) (至急)
test CHANGED
@@ -20,7 +20,7 @@
20
20
 
21
21
  cap = DesiredCapabilities().FIREFOX
22
22
 
23
- cap["marionette"] = False
23
+ cap["marionette"] = True
24
24
 
25
25
  retry=3
26
26
 
@@ -62,7 +62,7 @@
62
62
 
63
63
  >>> driver2("https://teratail.com/questions/186288")
64
64
 
65
- Message: 'geckodriver' executable may have wrong permissions.
65
+ Message: Unable to find a matching set of capabilities
66
66
 
67
67
  ```
68
68
 
@@ -100,8 +100,176 @@
100
100
 
101
101
  geckodriver はwget(url),tar (解凍),chmod(実行権限付与)
102
102
 
103
- (.exe形式でな
103
+ (.exe形式でな
104
+
105
+
106
+
104
-
107
+ firefox下のtree
108
+
105
-
109
+ ```ubuntu
110
+
106
-
111
+ attyan22@LAPTOP-SGBTV53C:/usr/bin/firefox$ tree
112
+
113
+ .
114
+
115
+ ├── firefox
116
+
117
+ │ ├── Throbber-small.gif
118
+
119
+ │ ├── application.ini
120
+
121
+ │ ├── browser
122
+
123
+ │ │ ├── blocklist.xml
124
+
125
+ │ │ ├── chrome
126
+
127
+ │ │ │ └── icons
128
+
129
+ │ │ │ └── default
130
+
131
+ │ │ │ ├── default128.png
132
+
133
+ │ │ │ ├── default16.png
134
+
135
+ │ │ │ ├── default32.png
136
+
137
+ │ │ │ ├── default48.png
138
+
139
+ │ │ │ └── default64.png
140
+
141
+ │ │ ├── chrome.manifest
142
+
143
+ │ │ ├── crashreporter-override.ini
144
+
145
+ │ │ ├── features
146
+
147
+ │ │ │ ├── formautofill@mozilla.org.xpi
148
+
149
+ │ │ │ ├── screenshots@mozilla.org.xpi
150
+
151
+ │ │ │ ├── webcompat-reporter@mozilla.org.xpi
152
+
153
+ │ │ │ └── webcompat@mozilla.org.xpi
154
+
155
+ │ │ └── omni.ja
156
+
157
+ │ ├── chrome.manifest
158
+
159
+ │ ├── crashreporter
160
+
161
+ │ ├── crashreporter.ini
162
+
163
+ │ ├── defaults
164
+
165
+ │ │ └── pref
166
+
167
+ │ │ └── channel-prefs.js
168
+
169
+ │ ├── dependentlibs.list
170
+
171
+ │ ├── firefox
172
+
173
+ │ ├── firefox-bin
174
+
175
+ │ ├── firefox-bin.sig
176
+
177
+ │ ├── firefox.sig
178
+
179
+ │ ├── fonts
180
+
181
+ │ │ └── TwemojiMozilla.ttf
182
+
183
+ │ ├── gmp-clearkey
184
+
185
+ │ │ └── 0.1
186
+
187
+ │ │ ├── libclearkey.so
188
+
189
+ │ │ ├── libclearkey.so.sig
190
+
191
+ │ │ └── manifest.json
192
+
107
- エラーの理由わかりません
193
+ │ ├── gtk2
194
+
195
+ │ │ └── libmozgtk.so
196
+
197
+ │ ├── icons
198
+
199
+ │ │ └── updater.png
200
+
201
+ │ ├── libfreeblpriv3.chk
202
+
203
+ │ ├── libfreeblpriv3.so
204
+
205
+ │ ├── liblgpllibs.so
206
+
207
+ │ ├── libmozavcodec.so
208
+
209
+ │ ├── libmozavutil.so
210
+
211
+ │ ├── libmozgtk.so
212
+
213
+ │ ├── libmozsandbox.so
214
+
215
+ │ ├── libmozsqlite3.so
216
+
217
+ │ ├── libmozwayland.so
218
+
219
+ │ ├── libnspr4.so
220
+
221
+ │ ├── libnss3.so
222
+
223
+ │ ├── libnssckbi.so
224
+
225
+ │ ├── libnssdbm3.chk
226
+
227
+ │ ├── libnssdbm3.so
228
+
229
+ │ ├── libnssutil3.so
230
+
231
+ │ ├── libplc4.so
232
+
233
+ │ ├── libplds4.so
234
+
235
+ │ ├── libsmime3.so
236
+
237
+ │ ├── libsoftokn3.chk
238
+
239
+ │ ├── libsoftokn3.so
240
+
241
+ │ ├── libssl3.so
242
+
243
+ │ ├── libxul.so
244
+
245
+ │ ├── libxul.so.sig
246
+
247
+ │ ├── minidump-analyzer
248
+
249
+ │ ├── omni.ja
250
+
251
+ │ ├── pingsender
252
+
253
+ │ ├── platform.ini
254
+
255
+ │ ├── plugin-container
256
+
257
+ │ ├── plugin-container.sig
258
+
259
+ │ ├── precomplete
260
+
261
+ │ ├── removed-files
262
+
263
+ │ ├── update-settings.ini
264
+
265
+ │ ├── updater
266
+
267
+ │ └── updater.ini
268
+
269
+ └── geckodriver.log
270
+
271
+ ```
272
+
273
+ marionette off では 'str' object has no attribute 'launch_browser'
274
+
275
+ firefox のインストールが原因?

10

naiyou

2019/04/26 11:10

投稿

退会済みユーザー
test CHANGED
@@ -1 +1 @@
1
- Message: 'geckodriver' executable may have wrong permissions(至急)
1
+ Message: The browser appears to have exited before we could connect. If you specified a log_file(至急)
test CHANGED
@@ -20,7 +20,7 @@
20
20
 
21
21
  cap = DesiredCapabilities().FIREFOX
22
22
 
23
- cap["marionette"] = True
23
+ cap["marionette"] = False
24
24
 
25
25
  retry=3
26
26
 
@@ -34,7 +34,7 @@
34
34
 
35
35
  print("first")
36
36
 
37
- browser=webdriver.Firefox(capabilities=cap,executable_path=r"/mnt/c/Users/a.sakata/AppData/Local/Packages/CanonicalGroupLimited.UbuntuonWindows_79rhkp1fndgsc/LocalState/rootfs/usr/bin/local/geckodriver",options=options,)
37
+ browser=webdriver.Firefox(capabilities=cap,options=options,)
38
38
 
39
39
  print("second")
40
40
 
@@ -102,4 +102,6 @@
102
102
 
103
103
  (.exe形式でなし)
104
104
 
105
+
106
+
105
107
  エラーの理由わかりません

9

だい

2019/04/26 08:46

投稿

退会済みユーザー
test CHANGED
@@ -1 +1 @@
1
- Message: 'geckodriver' executable may have wrong permissions
1
+ Message: 'geckodriver' executable may have wrong permissions(至急)
test CHANGED
File without changes

8

ないよ

2019/04/25 15:06

投稿

退会済みユーザー
test CHANGED
File without changes
test CHANGED
@@ -90,16 +90,16 @@
90
90
 
91
91
 
92
92
 
93
- Anacondaでも(windows用geckodriverもインストール済み from GitHub)
93
+ Anaconda同(windows用geckodriverもインストール済み from GitHub)
94
94
 
95
95
 
96
96
 
97
- IDE(Spyder)で実行するとMessage: 'geckodriver' executable needs to be in PATH.
97
+ IDE(Spyder)でMessage: 'geckodriver' executable needs to be in PATH.
98
98
 
99
99
 
100
100
 
101
101
  geckodriver はwget(url),tar (解凍),chmod(実行権限付与)
102
102
 
103
- (.exe形式で
103
+ (.exe形式でな
104
104
 
105
- エラーの理由はなですか
105
+ エラーの理由わかりませ

7

めいん

2019/04/25 12:35

投稿

退会済みユーザー
test CHANGED
File without changes
test CHANGED
@@ -101,3 +101,5 @@
101
101
  geckodriver はwget(url),tar (解凍),chmod(実行権限付与)
102
102
 
103
103
  (.exe形式ではない)
104
+
105
+ エラーの理由はなんですか

6

すべて

2019/04/25 12:19

投稿

退会済みユーザー
test CHANGED
@@ -1 +1 @@
1
- selenium webdriver.Firefox()起動しない。 立ち上がらない。
1
+ Message: 'geckodriver' executable may have wrong permissions
test CHANGED
@@ -34,7 +34,7 @@
34
34
 
35
35
  print("first")
36
36
 
37
- browser=webdriver.Firefox(options=options)
37
+ browser=webdriver.Firefox(capabilities=cap,executable_path=r"/mnt/c/Users/a.sakata/AppData/Local/Packages/CanonicalGroupLimited.UbuntuonWindows_79rhkp1fndgsc/LocalState/rootfs/usr/bin/local/geckodriver",options=options,)
38
38
 
39
39
  print("second")
40
40
 
@@ -62,7 +62,7 @@
62
62
 
63
63
  >>> driver2("https://teratail.com/questions/186288")
64
64
 
65
- Message: invalid argument: can't kill an exited process
65
+ Message: 'geckodriver' executable may have wrong permissions.
66
66
 
67
67
  ```
68
68
 
@@ -70,7 +70,7 @@
70
70
 
71
71
  環境変数指定
72
72
 
73
- C:\Users\a.sakata\AppData\Local\Packages\CanonicalGroupLimited.UbuntuonWindows_79rhkp1fndgsc\LocalState\rootfs\usr\bin\geckodriver
73
+ C:\Users\a.sakata\AppData\Local\Packages\CanonicalGroupLimited.UbuntuonWindows_79rhkp1fndgsc\LocalState\rootfs\usr\local\bin\geckodriver
74
74
 
75
75
  C:\Users\a.sakata\AppData\Local\Packages\CanonicalGroupLimited.UbuntuonWindows_79rhkp1fndgsc\LocalState\rootfs\usr\bin\firefox
76
76
 
@@ -92,4 +92,12 @@
92
92
 
93
93
  Anacondaでも同様(windows用geckodriverもインストール済み from GitHub)
94
94
 
95
+
96
+
97
+ IDE(Spyder)で実行するとMessage: 'geckodriver' executable needs to be in PATH.
98
+
99
+
100
+
101
+ geckodriver はwget(url),tar (解凍),chmod(実行権限付与)
102
+
95
- 何故、webdriver 起動しないのですか
103
+ (.exe形式ではない

5

2019/04/25 12:17

投稿

退会済みユーザー
test CHANGED
File without changes
test CHANGED
@@ -34,7 +34,7 @@
34
34
 
35
35
  print("first")
36
36
 
37
- browser=webdriver.Firefox(executable_path=r'C:\Users/a.sakata/AppData/Local/Packages/CanonicalGroupLimited.UbuntuonWindows_79rhkp1fndgsc/LocalState/rootfs/usr/bin/firefox',options=options)
37
+ browser=webdriver.Firefox(options=options)
38
38
 
39
39
  print("second")
40
40
 

4

2019/04/25 08:29

投稿

退会済みユーザー
test CHANGED
File without changes
test CHANGED
@@ -62,7 +62,7 @@
62
62
 
63
63
  >>> driver2("https://teratail.com/questions/186288")
64
64
 
65
- 'firefox' executable needs to be in PATH.
65
+ Message: invalid argument: can't kill an exited process
66
66
 
67
67
  ```
68
68
 

3

naiyo

2019/04/25 08:29

投稿

退会済みユーザー
test CHANGED
File without changes
test CHANGED
@@ -48,8 +48,6 @@
48
48
 
49
49
  browser.get(t)
50
50
 
51
- 'firefox' executable needs to be in PATH.
52
-
53
51
  return None
54
52
 
55
53
  print(browser.page_source)

2

naiyo

2019/04/25 07:13

投稿

退会済みユーザー
test CHANGED
File without changes
test CHANGED
@@ -34,7 +34,7 @@
34
34
 
35
35
  print("first")
36
36
 
37
- browser=webdriver.Firefox(options=options)
37
+ browser=webdriver.Firefox(executable_path=r'C:\Users/a.sakata/AppData/Local/Packages/CanonicalGroupLimited.UbuntuonWindows_79rhkp1fndgsc/LocalState/rootfs/usr/bin/firefox',options=options)
38
38
 
39
39
  print("second")
40
40
 

1

ないよ

2019/04/25 07:07

投稿

退会済みユーザー
test CHANGED
File without changes
test CHANGED
@@ -38,7 +38,9 @@
38
38
 
39
39
  print("second")
40
40
 
41
- except:
41
+ except Exception as e:
42
+
43
+ print(e)
42
44
 
43
45
  time.sleep(i*5)
44
46
 
@@ -46,7 +48,7 @@
46
48
 
47
49
  browser.get(t)
48
50
 
49
- except:
51
+ 'firefox' executable needs to be in PATH.
50
52
 
51
53
  return None
52
54
 
@@ -56,17 +58,13 @@
56
58
 
57
59
  ```
58
60
 
59
- 結果
61
+ 結果(options関係なし)
60
62
 
61
63
  ```python
62
64
 
63
65
  >>> driver2("https://teratail.com/questions/186288")
64
66
 
65
- first
67
+ 'firefox' executable needs to be in PATH.
66
-
67
- first
68
-
69
- first
70
68
 
71
69
  ```
72
70