-
-
Notifications
You must be signed in to change notification settings - Fork 8.2k
/
CHANGELOG
2768 lines (2450 loc) · 127 KB
/
CHANGELOG
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
Version number notation guide:
The version number of the IEDriverServer.exe is in the pattern as follows:
major.minor.build.revision
The "major" and "minor" fields are synchronized to releases of the Selenium
project. Changes in the "build" field indicate interim releases made publicly
available via the project downloads page. Changes in "revision" field indicate
private releases checked into the prebuilts directory of the source tree, but
not made generally available on the downloads page.
v4.16.0.0
========
* Fixed typos in logged messages (#13120)
v4.14.0.0
========
* Fix potential null pointer access in CookieManager
v4.11.0.0
========
* Ignore process id match when finding the window handle - IE Mode on Edge. (#12246)
v4.8.1.0
========
* Update atoms (Use .textContent instead of .innerHTML in clear() action (#11504))
v4.8.0.0
========
* Remove unnecessary executable permission bit from several files (#11502)
v4.7.0.0
========
* Ignore Zoom Level for Edge IE Mode (#11055)
v4.6.0.0
========
* Enable msIEModeAlwaysWaitForUnload for Edge IE Mode (#11079)
v4.5.0.0
========
* Auto-locate Edge if IE mode requested and location not specified
* If system IE redirects to Edge, automatically use Edge in IE Mode
v4.3.0.0
========
* fix Edge IE mode issue that sometimes cannot get the handle of a newly opened window (#10702)
* Disable popup blocking for Edge in IE Mode (#10869)
v4.2.0.0
========
* Check process ID when searching for Edge window handle
v4.0.0.0
========
* (on behalf of Gavin Xu) Updated atoms to allow IE driver to find elements.
* (on behalf of Gavin Xu) Fixed use of NewWindow3 API for use with Microsoft
Edge in IE Mode.
* Made further improvements for using the driver with Microsoft Edge in IE
Mode.
v3.150.2.0
==========
* Updates to JavaScript automation atoms.
* Changed source to compile against Windows 10 SDK. This means that the
executable may no longer run on versions of Windows less than Windows 10.
v3.150.1.1
==========
* Made checking of the Content-Length header case-insensitive. This fixes
a number of issues where sessions cannot be started or where commands
fail because the HTTP client made a choice to not use properly-cased
header names.
v3.150.1.0
==========
* Reverted change to use effective style for determining element visibility.
If a containing element has scrollbars, simply using the client bounding
rect to determine the click point could lead the click point behind a
scrollbar be determined as "in view," when clicking on the point would
instead click on the scrollbar. A previous fix for this issue was not
sufficiently robust in all scenarios, leading some elements to be seen
as not displayed at all. Accordingly, this change has been reverted
until a more correct one can be created.
* Other updates to JavaScript automation atoms.
v3.150.0.0
==========
* (on behalf of Stanley Hon) Added basic support for IEDriver to drive
Chromium-based Edge in Internet Explorer mode. Users can do this by
setting the `ie.edgechromium` property to `true`, and by supplying
the path to the Chromium-based Edge executable in the `ie.edgepath`
property of the `se:ieOptions` capability object. Note that this
feature is only available on Windows, as Chromium-based Edge only
supports Internet Explorer Mode on Windows. Moreover, users cannot
switch session types from normal mode to Internet Explorer Mode or
vice-versa; only one session type is allowed.
* Made driver work with <map> and <area> elements
* (on behalf of Marc Fisher) Fixed FTP and HTTP proxy markers for setting
web proxy with the IE driver. Fixes issue #7152.
* Added additional error information to error messages encountered during
navigation.
* Removed support from IE driver for "desiredCapabilities" in new session
requests. The W3C WebDriver Specification does not recognize any property
in the payload for the new session command other than "capabilities". The
IE driver has long supported the presence of "desiredCapabilities" as a
fallback for older, obsolete language bindings. Now that we are in the
process of creating the Selenium 4.0 language bindings, this legacy
compatibility should no longer be necessary. Users using this version of
the IE driver with language bindings prior to 4.0 may encounter issues
if the bindings do not properly format the new session request;
nevertheless, this change will not be reverted, as future versions of the
language bindings should properly format the new session command.
v3.141.59.3
===========
* Made driver calculate viewport with window.innerHeight/Width instead of
using documentElement.clientHeight/Width. This follows the definitions of
the W3C WebDriver Specification for calculating the in-view center point of
an element.
* Fixed to return empty object from JavaScript instead of null.
* Fixed IE driver to ignore unknown timeouts for set timeout command.
According to the W3C WebDriver Specification, additional timeouts not
specified are valid syntax, though they are ignored by the driver.
* Updated driver to allow detection of alerts with 'do not create' checkbox.
v3.141.59.2
===========
* Slightly modified setting IE window to have focus when sending input.
This code only affects the browser when the requireWindowFocus
capability is set at session start.
v3.141.59.1
===========
* Added checking for max expiration date in IE driver cookie handling.
Attempting to add a cookie with a very large expiration date caused
the IE driver to crash because of overflows in the C++ standard library
time formatting functions. This commit now avoids the crash by
enforcing a maximum cookie expiration time of 2,147,483,647 (2^32 - 1)
seconds from the time the cookie is attempting to be set. At the time
of this writing (2019), that means an expiration of the cookie sometime
over 68 years into the future (2087). If the intended expiration time
is beyond that limit, the driver will now return "unable to set cookie"
error.
As an internal implementation detail, the driver is migrating from the
"expires" attribute to the "max-age" attribute of the cookie string,
as versions of IE below 9 are no longer supported. Additionally, while
it would be possible to use "expires" and get a longer expiration time,
(somewhere around the year 3000), the distinction between a cookie
expiring after 68 years and one expiring in just under 1000 years is
(or ought to be) largely meaningless in the context of a website.
Fixes issue #7122.
v3.141.59.0
===========
* Rollup of fixes since previous release. No additional changes.
v3.141.5.13
===========
* Fixed execution of user JavaScript to allow comment at end of line.
v3.141.5.12
===========
* (on behalf of Reinhold Degenfellner) Updated to allow retries for finding
the upload file selection dialog. Fixes issue #6991.
* Modified to prevent navigation to directories using file:// protocol.
Navigating to a directory will open a Windows Explorer window, not open
the directory in the IE frame, and there is no way to automate the
resulting window. This is a deliberate deviation from the W3C WebDriver
Specification, as it's impossible to yield spec-compliant behavior from
Internet Explorer.
* Made driver return lowercase utf-8 for charset in content-type header.
v3.141.5.11
===========
* (on behalf of Reinhold Degenfellner) Fixed crash when attempting to
upload files. Fixes issue #6976.
v3.141.5.10
===========
* (on behalf of Ben Kucera) Updated proxy settings to set proxy bypass
addresses. Fixes issue #6086.
* Updated to be able to close Windows 10 credentials dialog. When Microsoft
updated Windows 10's credentials prompt dialog, they made it a dialog
that is not a standard alert dialog and therefore not able to be
automated using standard Windows automation techniques. With a recent
preview release, it became possible to manipulate this dialog using
the UI Automation feature of Windows. The driver will now be able
to accept or dismiss this credentials dialog now. Please note that
there is still no supported solution for entering credentials, as
there is no support for that feature in the W3C WebDriver Specification.
v3.141.5.9
==========
* Enabled serialization of the FileList object from file upload elements
(the return value of the files property in JavaScript).
* Improved recognition of Protected Mode boundary crossing on navigation,
particularly with URLs beginning with "about:blank"
v3.141.5.8
==========
* Improved driver use with invalid Protected Mode settings. Currently,
when the user does not set the Protected Mode settings of the browser
and sends the capability to bypass the checks for those settings,
the driver will attempt to predict when a Protected Mode boundary
will be crossed, and set in motion a process to reattach itself to
the newly created browser. This process is far from perfect. It is
subject to really challenging race conditions that are truly impossible
to eliminate entirely, because of the architecture of the browser
itself. Nevertheless, even in its flawed state, this is still a better
outcome than it was previously for users.
Please note that the advice and support policy of the IE driver will
continue to be that the user must set the Protected Mode settings of
the browser properly before using the driver. Any "issues" that arise
by not having the settings set, but that disappear when the settings
are corrected, are not considered by the project to be valid issues.
This will include, but not be limited to, issues like abandoned
browser instances not being closed, use of multiple instances of the
driver where the wrong browser window is connected to and automated,
and issues where the driver appears to hang upon navigation to a new
page. If the problem disappears when the browser is properly
configured, any issue reports will be immediately closed with a note
to properly configure the browser and remove the capability.
The following situations should be at least partially mitigated by the
change:
* Navigation to a new page
* Clicking on a link (specifically an <a> tag) that will lead to a
navigation to a new page
* Clicking a link that opens a new window
Other cases, like navigating backward and forward through the browser
history, clicking an element that submits a form, and so on, may not
be handled. In those cases, issue reports will be summarily closed,
unless a specific pull request fixing the issue is also provided.
Additionally, use of things like proxies to capture traffic between the
browser and web server may miss some traffic because of the race
conditions inherent in the mechanism used to reattach to a newly
created browser. Again, these race conditions are unavoidable, and
issue reports that are based on them will be immediately closed with a
note indicating that the browser must have its settings properly set.
These strict guidelines are not intended to be harsh, and are not put
in place with the intent to avoid investigating and fixing issues;
rather, they must be enforced because the underlying architecture of
the browser makes them unavoidable.
v3.141.5.7
==========
* Fixed uninitialized variable in driver.
v3.141.5.6
==========
* Fixed proper keyboard event values for extended keys.
v3.141.5.5
==========
* Added hack for handling cases where document.designMode is on.
In IE, when document.designMode is turned on, the browser is put
into a state where anonymous JavaScript functions cannot be run.
Obviously, this breaks a huge portion of the driver, so the driver
will now force documents out of designMode when attempting to
execute script. There should be vanishingly few real-world cases
where this has an adverse effect, with most sites using the
contentEditable attribute instead.
v3.141.5.4
==========
* Added hack for detection of IE in full screen mode.
v3.141.5.3
==========
* Again updated Unicode character processing for composition. The
previous change in 3.141.5.1 for using composed Unicode character
sequences on send and decomposed on retrieve was disturbingly
naive, and entirely incorrect. This revision mostly reverts that
change, with the difference of checking for "single-character"
encoding sequences when sending. The IE driver will no longer
produce the same input for some key combinations as other
drivers (see some Hangul sequences for concrete examples). The
mitigating factor of this difference in behavior, however, is
that the driver should now produce identical input and output
between sending keys and reading the text via either getting an
element's text or its attributes. Hopefully. There are likely
to continue to be corner cases where use of Unicode characters,
does not entirely match up to expectations. This is particularly
so in languages where individual code points can be combined to
form other glyphs identical to other individual code points.
v3.141.5.2
==========
* Enabled create new window command to create tabs. This change
overcomes the limitation of only creating top-level browser
contexts in new top-level windows. The IE driver can now open
new tabs when using the create new window command, as in the
.NET language bindings:
driver.SwitchTo().NewWindow(WindowType.Tab);
Note carefully that this change is only valid when explicitly
using the create new window command. It does not affect clicking
on links that open new top-level browsing contexts; those will
continue to open in new top-level windows. Furthermore, it is
imperative to note that this feature will absolutely not work
when Protected Mode properties are misconfigured. In other words,
if your code uses the .NET InternetExplorerOptions
`IntroduceInstabilityByIgnoringProtectedModeSettings` property
(or its equivalent in any other language bindings), this feature
will not work. Issue reports submitted regarding this will be
summarily closed.
v3.141.5.1
==========
* Implemented create new window commmand. The W3C WebDriver
Specification recently added the ability to create a new top-level
browsing context, or what appears to the user to be a new tab or
window. This change implements that command. Though the command
payload contains a hint argument as to what type of new top-level
browsing context the user desires (tab or window), the driver
implementation is free to ignore this type hint if it does not
support the type being requested. Since the IE driver has never
supported, and still does not support, creation of new top-level
browsing contexts using a new tab, in accordance with the spec, the
driver will create the new context in a new window, even if a new
tab is requested. Please note this is not a bug; it is as designed,
and is still fully compliant with the specification with this
behavior.
* Fixed edge case for clicking element. In the case of a fixed element
where the top-left corner of the element is outside the view port,
the click point calculation was not taking the offset of the top-
left when looking for the in-view center of the element. This change
fixes that issue.
* Updated Unicode character processing for combining characters. In a
previous revision, the IE driver was modified to normalize Unicode
strings that used combining characters to compose a single glyph when
sending keystrokes. This commit implements the reverse of that
operation when reading text data, decomposing the glyph into its
combining characters if required. This is a potential destablizing
change for text sequences that use combining characters, and care
should be taken by users to understand the potential differences if
handling text using such character combinations causes unexpected
results.
* Corrected error statuses returned for switching frames. The IE
driver now returns the correct status as specified by the W3C
WebDriver Specification for error conditions encountered when
attempting to switch frames.
* Modified to allow null value for script timeout. The W3C WebDriver
Specification has contradictory language regarding the script
timeout. On the one hand, it specifies that the value of the script
timeout can be `null`, indicating an indefinite timeout. On the
other hand, it specifies that when setting or getting timeouts, the
value of any timeout must be an integer between 0 and 2^53 - 1.
Since geckodriver has made the assumption that the former condition
is the correct interpretation, and the maintainers of geckodriver
have added a test to the W3C Web Platform Tests for WebDriver that
expects this interpretation, the IE driver is being modified to
follow that decision. It is the opinion of the developers of the IE
driver that this is the incorrect interpretation, but there is no
recourse to have the geckodriver maintainers revisit their decision.
v3.141.5.0
==========
* Added logging of JavaScript errors when executing scripts.
* Fixed incorrect error response format for invalid commands in IE.
Previously, when an invalid command was sent to the IE driver, the
response was not completely valid for the W3C dialect of the wire
protocol. In particular, the distinction was lost between an unknown
URL and an invalid HTTP verb, and this code was not properly converted
when the driver was updated to implement the specification. This change
fixes that. Correct responses are now sent back for both invalid
command cases. Additionally, the driver no longer hand-codes JSON for
these responses, instead creating a valid Response object, and using
the common serialization mechanism for transmission. Finally, this
commit includes some minor code formatting cleanup, which does not
affect the functionality of the driver. Fixes issue #6828.
v3.141.0.6
==========
* Modified to allow the driver to handle supplementary Unicode characters
in sendKeys. The IE driver lost the ability to check for surrogate
pairs after implementing spec compliance in 3.5. The driver will still
convert the keys being sent using sendKeys from UTF-8 to UTF-16 (Windows
development default for wide strings), but it will now properly
check for supplementary characters by checking for surrogate pairs.
* Moved normalization of Unicode strings to InputManager. Rather than
normalizing every conversion from UTF-8, it is more correct to only
perform the normalization when using the Unicode strings for keyboard
input. Accordingly, the normalization code is being moved from
StringUtilities to the InputManager class.
v3.141.0.5
==========
* Updated element obscured algorithm to handle shadow DOM polyfills. Shadow
DOM for IE is problematic. Shadow DOM is only available in IE as a
polyfill. If an element is part of a Shadow DOM (using a polyfill), IE's
elementsFromPoint implementation will show the component elements, not
necessarily the Web Component root element itself. If the direct parent
of the Web Component host element is in this list, then it counts as a
direct descendent, and won't be obscured. Note that a potential
enhancement to this change is to walk the DOM tree up until an ancestor
is found that does not have a shadow root, but that enhancement is not
implemented at present.
* Added synchronization code. The IE driver can only handle one command
at a time. Commands from multithreaded client libraries should block
on the second thread's command until the first thread's executing command
is complete.
* Reverted earlier change to the obscured element algorithm. The previous
changes were incorrect. Any value other than 'none' for the pointerEvents
CSS property on a non-SVG element will result in the element receiving
pointer events.
* Removed isFocusable atom from sendKeys command. The isFocusable atom
does not provide the correct information as to whether an element is
focusable according to the W3C and WHATWG DOM specifications. This
change removes the use of that atom, and relies instead on the abililty
to set focus to the element before sending the keystrokes.
v3.141.0.4
==========
* Fixed to correctly set Content-length header for HTTP responses.
Not setting this header properly is a protocol violation, and strict
HTTP clients (like .NET's HttpWebRequest/HttpWebResponse) will reject
such an HTTP response for the 1.1 version of the HTTP protocol.
* Reduced JavaScript errors during findElement(s). In most cases, executing
JavaScript is an atomic action for the IE driver. However, in the off
chance that there is a page refresh during the execution of JavaScript,
converting the result of the script to a JSON object for serialization
might cause an error, in which case we should return the appropriate
error to the caller. One place, however, where this might be common is
executing findElement(s) across a page navigation. This change makes the
driver return the proper error in the post-processing of a script
execution. It also recognizes the findElement(s) case, ignoring
JavaScript errors in finding elements, and returning the proper structure
(an empty list or a "no such element" error) in its place. This lets
things like explicit waits retry the find, which may succeed once the
page navigation has completed and the DOM available for querying again.
* Tweaked obscured element algorithm. The algorithm used by the IE driver
to detect obscured elements checks the value of the pointer-events CSS
computed style property. This property can have valid values of "auto"
and "none" which affect whether to consider an element "obscured."
However, the property can also contain other values for SVG elements.
If the element in question is not an SVG element, then values other
than "none" and "auto" must be ignored, and the element considered not
to obscure the target element.
* Fixed compile warnings.
v3.141.0.3
==========
* Updated Civetweb dependency to version 1.11.
* Modified IE driver to no longer always send Connection: close header.
This is a potentially destablizing change, as the driver now should
correctly use keep-alive for HTTP requests and responses. While this
should not matter, the driver has not ever executed true with keep-
alive connections, so care should be used.
v3.141.0.2
==========
* Updating IE scroll-into-view algorithm for element click.
This update makes the scroll-into-view algorithm for element click
to be compliant with the W3C WebDriver Specification.
* Completed IE implementation of strictFileInteractability capability.
By default, the IE driver can interact with hidden <input type='file'>
elements. By setting this capability to false, it forces the driver
to make sure the file upload element is interactable like other
elements.
* Updates to JavaScript automation atoms.
v3.141.0.1
==========
* Updated error message return from unserializable JavaScript results. In
the case where a user JavaScript execution completes successfully, but
the resulting option is not serializable via JSON (because of cyclical
references or similar), the error message that the execution errored due
to the failed serialization was being suppressed.
* Added support for strictFileInteractability capability. The latest
editors' drafts of the W3C WebDriver Specification as a living document
have introduce the "strictFileInteractability" capability for handling
<input type='file'> elements. This change makes the driver aware of that
capability.
* Removed premature break statements in obscured element check. When
looping through the elements returned by elementsFromPoint, the driver
was calling a break statement early, preventing clear error messages for
which element is obscuring the element to be clicked.
v3.141.0.0
==========
* Release to synchronize with release of Selenium project.
* Updates to JavaScript automation atoms.
* Version number updated to continue with "digits of pi" theme.
v3.14.0.15
==========
* Fixed change in behavior recognizing closing of showModalDialog windows.
Fixes issue #6574.
v3.14.0.14
==========
* Fixed retrieval of CSS properties that return non-string values. Fixes
issue #6527.
v3.14.0.13
==========
* Fixed multiple file upload element detection.
v3.14.0.12
==========
* Allowed duration property of pause actions to be omitted.
* Cleaned up variant copying for getElementAttribute command.
* Expanded inline element detection for obscured elements. This commit
expands on the hack that was introduced in 3.14.0.11. It turns out
that <label> elements are not the only ones to suffer from issues
with elementsFromPoint. Rather, we now check for all types of inline
elements. This change also refactors the calculation of the hit-
testing point for calling elementsFromPoint in the first place, as
it only makes sense to call from within the context of the element's
document (omitting frames).
v3.14.0.11
==========
* Added hack to obscured element check for label elements. As per the
W3C WebDriver Specification, the IE driver uses elementsFromPoint to
determine whether an element being clicked on is obscured. However,
there is a bug in the IE implementation of elementsFromPoint that if
the element parent tree contains a <label> element, that element is
omitted from the list of elements returned by elementsFromPoint. This
change is to work around that bug. The solution implemented here is
to check if the top-most element as returned by elementFromPoint is
a direct descendent of the element we want to click on, and the
element we want to click on is a <label>, we assume the element is
not obscured. Note carefully that this is a hack of the highest
order, and there's every likelihood that some page, somewhere will
fail this check. Upon receiving an issue report with a complete
reproduction case that includes a page clearly demonstrating the
issue, we will then revisit this algorithm.
v3.14.0.10
==========
* Partially reverted obscured element check. The updated obscured check
introduced in 3.14.0.8 assumed that there was a bug in IE's implementation
of elementsFromPoint. This is not the case. The actual bug is that the
driver did not take into account elements found outside the DOM tree of
the element being interacted with should not be flagged as obscuring the
target element if its pointer-events CSS property is "none". This is
because while the element may technically be rendered above the target
element in the DOM, it does not interfere with attempts to interact with
elements below it, since pointer events are not triggered.
v3.14.0.9
=========
* Added ability to return text of JavaScript errors. Until this change,
if the IE driver encountered an error in a user's JavaScript, there was
no way to return the actual error text. This change fixes that. The text
of the JavaScript error will be returned so it can be used as part of
the exception thrown by the language bindings.
v3.14.0.8
=========
* Updated obscured element check. The W3C WebDriver Specification dictates
that checking for elements being obscured by other elements should rely
on calling elementsFromPoint. However, there is a bug in IE's
elementsFromPoint implementation. if two sibling elements have the same
z-index, the one specified second in the DOM order is usually on top.
The exception is if there is a child element that has a specified
z-index greater than the ancestor z-index. The IE elementsFromPoint
implementation ignores the child element case, so we have to manually
look for child elements that may be rendered on top of the element found
outside the element DOM tree of the element we are attempting to interact
with.
v3.14.0.7
=========
* Instituted limits on x and y offsets for actions.
* Corrected finding of extracted dll on startup.
v3.14.0.6
=========
* Updated to make JSON serialization of JavaScript objects more compliant.
When returning values from user-specified JavaScript, the presence of a
toJSON() property indicates that function is what should be used to
serialize the object. Additionally, for objects that are not recognized
as JavaScript objects via the properties of the IDispatch, and do not
have a toJSON property, the driver will now make a last-ditch attempt
to serialize the value for return by calling JSON.stringify().
v3.14.0.5
=========
* Updated to manually initialize cookie manager on new window open. When
a new window is requested by the browser, the driver creates one, but
does not set the window handle of the window to a proper value. This
is normally not an issue, but in the edge case where the user wants to
manipulate cookies in the new window, the cookie manager does not have
a window handle set to facilitate the transfer of cookie information
from the driver code to the browser. This change rectifies that problem.
v3.14.0.4
=========
* Updated to return 500 for timeouts instead of 408. Some HTTP clients
would retry when receiving a 408 status code. Switching to 500 resolves
that issue.
* Updated driver for the case of clicking element with children. The
case where one attempts to click on an element that must be scrolled into
view, and where the element has child elements, but the first node is a
text node was broken for IE. In this case, to guarantee the proper element
is clicked (and that an embedded child does not receive the click), the
driver would attempt to click on the text node. However, the coordinate
calculation when the element had to be scrolled into view was flawed. This
commit changes from using the boundingLeft and boundingTop properties of
IHTMLTextRangeMetrics to using offsetLeft and offsetTop in an attempt to
correct the calculation of the location of the text to be clicked on.
* Updated driver to return non-integer values for element rect.
* Made driver spec compliant for setting largest timeout value.
* Updated to properly find XML documents for element enabled and CSS values
* Refactored opening and closing of new browser windows. This simplifies,
streamlines, and makes more robust the driver code responsible for finding
new browser windows when opened by users' code, like clicking a link that
opens the target in a new browser window. It also simplifies the code that
executes when a browser window is closed. There is a chance this change
introduces a slight performance delay in the process of opening a new
browser window, but in the interest of making the driver more robust, it
is preferable to live with the delay and figure out a way to reduce or
eliminate it later.
v3.14.0.3
=========
* Updated to properly validate duration property of pause actions.
v3.14.0.2
=========
* Robustness change for invalid command payloads to comply with W3C Spec.
* Updated to truncate obscured element click error message to a reasonable
length.
* Handle null pointers for cookie values. Fixes issue #6261.
v3.14.0.1
=========
* Updated to properly set the "path" property on cookies when a document
is specified in the property.
v3.14.0.0
=========
* Release to synchronize with release of Selenium project.
* Modified to prevent attempt to return IDispatch that is not IHTMLElement.
When returning values from JavaScript, if a variant value is an IDispatch,
but does not implement IHTMLElement, and also is not recognized as a
JavaScript array or object, avoid returning it from the script. This is
also to prevent returning things like a window or document reference, as
those items contain recursive references that cannot be properly
serialized to JSON.
* (on behalf of Mike Bellew) Fixed null pointer exception when managed
element is not found. The command executor has a chance to return an error
code of ENOSUCHELEMENT when executing scripts. This leaves the element
wrapper object equal to null, which in turn ends up throwing an exception
on the next like of code when it tries to use the element. This would
cause a crash in IEDriver and it shuts down
v3.13.0.5
=========
* Modified to silently dismiss onbeforeupdate dialogs. The W3C WebDriver
Specification dictates that all onbeforeupdate dialogs are automatically
dismissed without notification. This commit brings the IE driver into
compliance with that part of the spec.
* Resetting frame focus to top-level frame on refresh. The W3C WebDriver
Specification dictates that issuing the Refresh command will reset the
focus to the top-level frame. This commit brings the IE driver into
compliance with that part of the spec.
v3.13.0.4
=========
* Made set window rect command spec-compliant for x and y coordinates
v3.13.0.3
=========
* Fixed crashing bug in obscured element detection.
* Modified to extract IE internal library to IEDriver.tmp first.
If the file IEDriver.tmp exists in the destination directory, then use
the result of the `GetTempFileName` API, which results in a file named
"IEDxxxxx.tmp" where "xxxxx" is a random number.
* Added version resources to internal IE driver library.
v3.13.0.2
=========
* Modified to prevent keyup actions if key is not already down for IE.
This change now checks that a specified key is down before sending any
input events when a keyUp action is specified. This prevents spurious
events detected by the browser, events which cannot happen with an actual
user.
* Refactored IE sendKeys command handler to handle multiple file uploads.
Until now, the IE driver has not handled the "multiple" attribute for
<input type="file"> elements. This construct is now supported, and it is
possible to specify multiple files for upload if the multiple attribute is
set on the <input> element. To do so, use a string containing full path
and file name to each file to be uploaded, separated by new line
characters (e.g.: "C:\path\to\file\one.txt\nC:\path\to\file\two.txt"). One
caveat to this approach is that when specifying multiple files, all files
must be located in the same directory. This is not a limitation imposed by
the driver; it is a limitation imposed by IE itself. It is a known
limitation, and cannot be fixed in the driver until and unless the browser
allows it.
* Added wait for navigation to IE accept and dismiss alert commands. When
accepting or dismissing an alert, particularly when it is raised during
the onload event, it is possible for the driver to not recognize that
navigation is still pending once the alert is handled. This change is an
attempt at better allowing the driver to recognize this situation and act
accordingly.
v3.13.0.1
=========
* Updated to automatically dismiss onBeforeUnload event dialogs. This is a
change from previous behavior, where such dialogs were handled via the
standard alert handling commands. The W3C WebDriver Specification demands
that onBeforeUnload dialogs be dismissed automatically, with no input
allowed for the user. This may be a breaking change for some users who are
currently relying on the alert-handling commands to handle these alerts;
however, not implementing this behavior makes the driver not compliant with
the specificiation. Users in that state will have no choice but to modify
their code to accomodate the new, spec-compliant behavior.
* Updated the reset action to be spec-compliant. This means that when the
"Release Actions" command is sent, that pressed keystrokes and mouse
buttons are reset to the "up" position in the correct order.
* Corrected "invalid session id" response to be spec-compliant
v3.13.0.0
=========
* Release to synchronize with release of Selenium project.
* Updates to JavaScript automation atoms.
v3.12.0.5
=========
* Updating to indicate elements with 'pointer-events' style of 'none' as
obscured, triggering "element click intercepted" error response. This is
in keeping with the W3C WebDriver Specification that demands this behavior.
v3.12.0.4
=========
* Updates to JavaScript automation atoms.
* Use elementFromPoint for IE driver in determining obscured elements. This
is in direct violation of the algorithm specified in the W3C WebDriver
Specification, but it fixes a class of IE-specific bugs that present
themselves when using elementsFromPoint. This is used to shortcut the use
of elementsFromPoint if it is not necessary.
* Added additional logging to IE driver for setting window focus.
* Updated IE driver to use SendInput for a single input at a time. The IE
driver uses the Windows `SendInput` API when a session is initiated with
the `requireWindowFocus` capability. This is a low-level user input
simulation API, and very closely mimics the use of a physical mouse and
keyboard. One of the guarantees of the API is that when one sends an array
of `INPUT` structures, then no input messages can be inserted into the
middle of the input stream. However, it appears that there are cases where
sending multiple input structures that IE does not process all of them.
This leads to truncated or missing keys when using the Selenium sendKeys
method. This change makes the driver use SendInput, but only passing a
single INPUT structure at a time. This is dangerous, in that it allows
other inputs to potentially be slipped into the input stream. This change
makes the driver prefer one form of instability (potentially unwanted
input events) over another (input events not processed by the browser).
Additionally, this change introduces an additional method for forcing the
IE window into focus before sending input. This additional method uses the
Windows UI Automation accessibility API to do this. The potential down
side to using this (apparently) more reliable mechanism is that it may
introduce a slight performance penalty, as the UI Automation API is
notoriously slow. In practice, this performance penalty is observed to be
on the order of milliseconds, so the trade-off here is deemed worth the
risk, and there is no way to disable this new check.
v3.12.0.3
=========
* Refactored IE waiting for page load on click. This commit restores some
previously lost functionality for waiting for a page to load on click of
an element. The race condition for detecting when a navigation is started
is mitigated by a short wait (50ms) on the click.
* Made "eager" page load strategy not wait for frame navigation to be
completed before returning.
v3.12.0.2
=========
* Added log warning for mismatched bitness of driver and browser when
sending keys.
* Updated to better support using CreateProcess API for launching IE.
The driver checks the registry for the location of the iexplore.exe
executable. In the case of a 32-bit driver on 64-bit Windows, the
registry calls are redirected to the Wow6432Node in the registry,
which ultimately points to ielowutl.exe instead of iexplore.exe. In
this case, we will now bypass the registry redirection, and read the
proper location from the 64-bit browser executable. A side effect of
this is that users wanting to use the CreateProcess API will need to
use the 64-bit version of the IE driver on 64-bit Windows, contrary to
most expectations. It is important to note that using this API and
launching the browser in this way is not consistent with how the user
will launch IE, and if the driver is used for testing purposes, it will
not be giving identical results to what the end-user of the application
being tested will use when running IE.
v3.12.0.1
=========
* Update close window command to return list of remaining window handles.
This makes the command consistent with the W3C WebDriver Specification.
Unfortunately, to accurately return the proper list, however, this
requires the driver to wait for the window to be completely closed. In
previous versions, this was an asynchronous operation, and could return
immediately. With this change, the driver must wait for the window to
be successfully closed, and this change therefore introduces a slight
performance delay when windows are closed. The performance hit is
unfortunate, but unavoidable.
v3.12.0.0
=========
* Release to synchronize with release of Selenium project.
* Updates to JavaScript automation atoms.
* Added alert text to error response for unexpected alerts. This is to
maintain consistency with other implementations.
* Added checking of variant type for returns from JavaScript execution.
In order to prevent false positives when checking whether a returned
variant is an array or object, make sure the returned type of the
variant is VT_DISPATCH.
v3.11.1.6
=========
* Changed to throw an error for key actions taking multiple characters in IE.
The key actions as defined by the W3C WebDriver Specification take a JSON
payload that requires the resulting key for the key down or key up action
to resolve to a single Unicode code point or a single grapheme cluster
(what appears to be a single logical "character" from a user's
perspective). The IE driver will now evaluate the item passed into the key
down or key up action, and, taking combining characters into account,
attempts to make sure there is only a single grapheme present, if more
than one Unicode code point is sent. If the entered string would results
in multiple grapheme clusters, the driver now returns an invalid argument
error, as per the spec.
* Updated find element by link text atom to handle non-breaking spaces.
The WebDriver W3C Specification states that when finding by link text, the
text of a link element (<a>) should be trimmed of leading and trailing
whitespace after calling getVisibleText on the element before comparison.
Links with text that contains leading or trailing non-breaking spaces
( ) were having the non-breaking spaces converted to regular spaces,
but not trimmed after the fact. This commit corrects that oversight.
* Made IE cookie expiration times integer values. Some WebDriver
implementations have used floating point values for the expiration time of
a cookie as serialized in the wire protocol. The W3C WebDriver Specification
dictates that expriation times should be integer values. This commit makes
the driver conform to the specification.
* Modified to throw exception clicking on file upload elements in IE.
The WebDriver W3C Specification states that if a user attempts to click a
file upload element (<input type="file">), an error should be returned.
This is consistent with the intended behavior of WebDriver from the start,
which is that to upload a file, one should use sendKeys, not click() on
the input element. This now codifies that behavior with returning an
error. Note that if users have erroneously been using click() with file
upload elements, then using some external library (Robot Framework,
Sikuli, etc.) to handle the resulting file selection dialog, their
code will now break, in that the click() method will throw an exception,
and the element will not be clicked. Those users should update their code
accordingly.
v3.11.1.5
=========
* Initial implementation of taking element screenshots. This is an extremely
naive implmementation, and should not be considered complete.
v3.11.1.4
=========
* Fixed finding child elements to return proper error if parent element is
stale. Fixes issue #5700.
v3.11.1.3
=========
* Fixed detection of obscured elements when top element is not displayed.
Fixes issue #5668.
v3.11.1.2
=========
* Changed COM variant to JSON serialization in IE. There is an expectation
that if a result from JavaScript is "integral," that it is serialized for
return to the calling code as an integral number rather than a floating-
point number. Previous versions of the JSON serializer used by the IE
driver would (incorrectly) serialize a floating-point value with no
decimal part as being an integer. After updating to a later version, the
serializer now (correctly) serializes floating-point values as floating-
point values, with a trailing ".0" to indicate a floating-point value.
While this is the correct behavior by the serializer, it breaks the
expectations of the language bindings. Therefore, we check to see if the
variant value has a decimal part, and if it has none, convert it to an
integer for serialization by the JSON library.
* Updated JsonCpp library to latest source code. Fixes issue #5664.
v3.11.1.1
=========
* Separated out detection of focusable elements for sendKeys in IE. Allows
separate error messages for attempting to send keys to a non-focusable
element. Also fixes sending keystrokes to <option> elements by forwarding
the detections to the parent <select> element.
* Fixed obscured element detection in IE for elements in frames.
* Added support for extension capabilites starting with "test:" in IE. This
is basically to support the web-platform-tests WebDriver test suite. Adding
an extension capability with name starting with "test:" will allow a user
to create a session, but will have no effect on the session. It is a no-op.
* Added IsFocusable method to IE driver Element class.
* Added Protected Mode boundary crossing detection mechanism in IE. When a
Protected Mode boundary is crossed by navigation (entering or exiting
Protected Mode), the existing browser instance is destroyed and a new one
created in its place by Interent Explorer. This commit adds detection for
when a browser instance is being closed, but without an explicit call to
the WebDriver close() or quit() methods. When this is detected, it's likely
a Protected Mode boundary is being crossed, and all subsequent commands in
the WebDriver session will fail. In this case, the driver will now write
to the log that the browser has been asked to exit without the user
explicitly requesting it. The detection is not perfect, since it's
possible to legitimately click a link that closes the browser window, and
this is indistinguishable from clicking a link that navigates to a URL
that causes a Protected Mode boundary crossing. Nevertheless, this logging
is being added so that users can see what may be happening when they
receive errors like "Unable to get current browser."
v3.11.1.0
=========
* Updated all C++ projects for the IE driver to use the Windows 8.1 SDK.
This has the unfortunate side effect that the driver executable will no
longer launch on Windows XP.
* Removed direct call to InternetGetCookieEx2 API. Versions of IE prior to
11 do not have access to this API. Linking directly to it via the Windows
8.1 SDK creates an import entry in the IEDriver.dll library used by the
driver. So that the driver can continue to be used against earlier releases,
we will call the API using GetModuleHandle and GetProcAddress only if it
exists in the version of WinINet being used by the browser. Fixes issue #5603.
* Properly initializing JSON values in IE driver. Fixes issue #5519.
v3.11.0.0
=========
* Release to synchronize with release of Selenium project.
* Added additional logging to new session command.
* Added detection of intercepted element clicks to IE. This brings the IE
driver into alignment with the Chrome and Firefox (geckodriver) drivers,
in that it detects when an element attempting to be clicked on is covered
in the z-order by another element. Do note that this may cause different
behavior from previous versions of the IE driver for WebDriver code that
runs only on IE. For code that runs cross-browser, this should now yield
the same behavior across platforms.
v3.10.0.2
=========
* Updates to JavaScript automation atoms.
* Fixed clear element command to handle cases where the element's parent
document is undefined.
* Fixed sending keystrokes with native events disabled. Because apparently,
the driver's developer can't remember how function binding works in C++
when using a pointer to the object instead of the object itself. Fixes
issue #5584.
v3.10.0.1
=========
* Updates to JavaScript automation atoms.
* Updated clear element command handler to return W3C compliant errors for IE.
* Updated IE error response to be spec compliant for sendKeys
* Fixed IE cookie retrieval for IE 10 and 11. Internet Explorer relies on a
Windows component called WinINet to communicate over the Internet. This
includes WinINet APIs for getting and setting cookies. Prior to Windows 10,
persistent cookies were stored in files on the hard drive. A change in
WinINet moved the persistent cookie storage from files on the disk to an
Extensible Storage Engine (ESE or "Jet Blue") database, which rendered them
unreadable by the IE driver. This commit restores the functionality of
getting cookies by using an API function called InternetGetCookieEx2.
This API function was introduced in the Windows 8.1 SDK, which means that
it won't be available to older versions of WinINet. In that case, we fall
back to the original behavior of attempting to parse cookie files from the
disk. There is a chance that the detection of the availability of this API
is flawed in the IE driver.
* Revamped handling of modifier keys. The IE driver is now able to
distinguish between the left and right modifier keys (Shift, Control,
Alt) on the keyboard.
* Modified mouse event handling to match W3C Specification.
THIS IS A POTENTIAL BREAKING CHANGE.
The simulation of mouse movement for the actions command now conforms
to the W3C WebDriver Specification for mouse movement. This means
that offsets in elements are now measured from the center of the
element instead of the top-left, which was the previous behavior.
Additionally, attempting to move the mouse pointer outside the
browser view port will result in a "mouse movement out of bounds"
error. While users should be aware that this might cause code
using user interactions to fail, not that the behavior is now
consistent with the behavior outlined in the specification, and
the behavior of geckodriver in particular.
* Modified processing of pause actions in keyboard action sequences.
The vast majority of use of pause actions in a keyboard action
sequence are used to synchronize the entire action chain with other
(mouse) action sequences. To allow the driver to properly synchronize
the input sequences, the driver will now ignore the duration property
of pause events in keyboard action sequences. This is deliberately in
violation of the W3C specification, and may be revisited in the future.
* Fixed sending keystrokes outside the Basic Multilingual Plane. This
allows emoji and other Unicode characters that are represented by
surrogate pairs in UTF-16 to be sent to IE.
* Fixed getElementProperty to return proper data type. Previously,
the getElementProperty command would coerce the property value to a
string. This is not correct behavior as specified in the W3C spec.