Skip to content

Commit a5ed3fe

Browse files
committed
Release notes for 18.0.0
1 parent 357ab5d commit a5ed3fe

File tree

1 file changed

+342
-0
lines changed

1 file changed

+342
-0
lines changed
Lines changed: 342 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,342 @@
1+
======================
2+
Browser library 18.0.0
3+
======================
4+
5+
6+
.. default-role:: code
7+
8+
9+
Browser_ is a web testing library for `Robot Framework`_ that utilizes
10+
the Playwright_ tool internally. Browser library 18.0.0 is a new release with
11+
**UPDATE** enhancements and bug fixes.
12+
All issues targeted for Browser library v18.0.0 can be found
13+
from the `issue tracker`_.
14+
For first time installation with pip_, just run
15+
::
16+
pip install robotframework-browser
17+
rfbrowser init
18+
to install the latest available release. If you upgrading
19+
from previous release with pip_, run
20+
::
21+
pip install --upgrade robotframework-browser
22+
rfbrowser clean-node
23+
rfbrowser init
24+
Alternatively you can download the source distribution from PyPI_ and
25+
install it manually. Browser library 18.0.0 was released on Tuesday November 21, 2023.
26+
Browser supports Python 3.8+, Node 18/20 LTS and Robot Framework 5.0+.
27+
Library was tested with Playwright 1.40.0
28+
29+
.. _Robot Framework: http://robotframework.org
30+
.. _Browser: https://github.com/MarketSquare/robotframework-browser
31+
.. _Playwright: https://github.com/microsoft/playwright
32+
.. _pip: http://pip-installer.org
33+
.. _PyPI: https://pypi.python.org/pypi/robotframework-browser
34+
.. _issue tracker: https://github.com/MarketSquare/robotframework-browser/milestones/v18.0.0
35+
36+
37+
.. contents::
38+
:depth: 2
39+
:local:
40+
41+
42+
Thanks To Our Sponsors
43+
======================
44+
45+
This is the most significant release we've had in a long time. We've implemented 31 feature
46+
requests and bug fixes, reducing our open issues to an incredibly low number of just 11.
47+
48+
This would not have been possible without the financial support of our sponsors.
49+
A special thanks to the members of the Robot Framework Foundation_ and its board.
50+
The Foundation has once again valued our project and decided to support us financially.
51+
This support is a huge help, and we are very grateful for it.
52+
53+
We also want to thank one of our user companies, which has chosen to remain unnamed,
54+
for their financial support. Their contribution made the development of the
55+
`Connect To Browser` via CDP keyword possible.
56+
57+
58+
Most important enhancements
59+
===========================
60+
61+
62+
Browser Context and Page handling
63+
---------------------------------
64+
65+
macOS Sonoma (14.0) fixes
66+
~~~~~~~~~~~~~~~~~~~~~~~~~
67+
68+
For unknown reasons the new macOS 14 did not work properly with Browser library.
69+
A timing issue during the library startup caused problems.
70+
This should be fixed now, by an internal workaround.
71+
72+
73+
Browser Server and Connection to running Browsers
74+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
75+
76+
It was already possible to connect to a running instance of a Playwright Browser server
77+
via websockets with `Connect To Browser` keyword. However it was not trivial to launch
78+
such a browser server. Now it is also possible to launch such
79+
server via `Launch Browser Server` keyword and close it again with `Close Browser Server`
80+
and also run it independantly of Robot Framework via CLI option with `rfbrowser launch-browser-server`.
81+
82+
Furthermore we have implemented the option to connect to a running chromium based browser instance
83+
over Chrome DevTools Protocol (CDP) with `Connect To Browser` keyword and the argument `use_cdp=True`.
84+
To open a chromium based browser with CDP enabled, you can just start it with the argument
85+
`--remote-debugging-port=9222`. At the moment it is not yet support to set additional connection
86+
options, but this can be added in the future.
87+
88+
Launching a Browser Server as a separate may be useful for distribute executions.
89+
The command `rfbrowser launch-browser-server` accepts all the same arguments as `Launch Browser Server`/`New Browser`
90+
keyword. See `rfbrowser launch-browser-server --help` for more information.
91+
92+
Some of our users had the wish that the browser stays open after finishing the execution.
93+
This is now possible with the new `Closing Level` `KEEP` that will never close the browser.
94+
!!! BUT BE AWARE !!! This will let a Node process open in the background, which may cause
95+
resource issues on your machine. So use this option with care!!!
96+
97+
`New Page` and `Go To` keywords got a new argument `wait_until` which allows to wait for
98+
a specific condition before continuing. This is useful if you already want to continue with the test
99+
once the page starts loading or once the page is fully loaded or when the network is idle for 500ms.
100+
101+
Some **Backwards Incompatible** changes are also included.
102+
One is the improved handling of the Browser Catalog which leads to a more consistent
103+
but slightly different behavior than before:
104+
105+
- `New Persistent Context` did already in the past reuse the same browser, however it was listed
106+
twice in the Browser Catalog. Now if `New Persistent Context` is called multiple times, multiple
107+
contexts are created, but they all reuse the same browser.
108+
- When `New Page` keyword or `New Persistent Browser` keyword were failing due to a timeout
109+
during page loading, the browser, context and page were already created but due to the timeout
110+
removed from Browser Catalog. This made it impossible to use the browser, context or page or even close them.
111+
Now the newly created elements are also properly closed when a timeout happens, so that there is no
112+
zombies left behind.
113+
- We removed all deprecated arguments from `New Persistent Context` and `New Context`.
114+
These arguments where already without any function, but now finally removed.
115+
116+
File Downloads
117+
~~~~~~~~~~~~~~
118+
119+
We already had the possibility to download files with the `Download` keyword and `Promise To Download File`.
120+
These keyword did finish (promise resolved) once the actual download has been fully completed.
121+
The timeout on the other side were just used until the download started/the file chooser opened.
122+
This could lead to the situation where tests had to wait for a long time until the download finished
123+
and the next download could be started.
124+
125+
We now added two arguments to `Download` and `Promise To Download File` keyword which allows to
126+
return once the download has been started with a download id.
127+
That id then can be used to poll the download `Get Download State` or even cancel it with `Cancel Download`.
128+
129+
Assertion Formatters
130+
~~~~~~~~~~~~~~~~~~~~
131+
132+
Assertion Formatters are a pretty unknown feature of Browser library.
133+
With this feature it is possible to configure a Getter keyword so that it always applies that "formatter"
134+
before returning or asserting the value. This is useful if you want to assert a value that has been stripped
135+
and converted to lowercase before. One very helpful formatter is `normalize spaces` wich converts all
136+
kind of whitespace (also NBSP) to a single space, which makes it easier to assert values that may contain
137+
different kind of whitespace.
138+
139+
These formatters are now set to a specific keyword to a limited scope. By default the scope is within the Suite.
140+
We also added a `LambdaFunction` possibility which allows the users to define their own formatter function.
141+
142+
Documentation of Assertion Formatters has also been improved and now includes proper type hinds.
143+
This on the other hand make them backwards incompatible if they have been used from Python with string arguments.
144+
145+
Robot Framework 7 Support
146+
~~~~~~~~~~~~~~~~~~~~~~~~~
147+
148+
Due to some changes in internal Robot Framework API, the previous version of Browser library
149+
was not compatible with Robot Framework 7. Browser Library 18.0.0 is now compatible with Robot Framework 7.
150+
151+
Robot Framework 7 also introduced the possibility to document return types of keywords in the keyword
152+
documentation. We therefore have updated some of our return types to better document the behavior of the keywords.
153+
All Getter keywords do have a type hint of their natural return type, ignoring the possibility of manipulating
154+
with `then` or `evaluate` assertion operator.
155+
156+
157+
158+
Backwards incompatible changes
159+
==============================
160+
161+
- storageState can't use in New Persistent Context (`#2679`_)
162+
- New Page and New Persistent Context do not close again if Go To fails (`#3242`_)
163+
- Drop support NodeJS 16 and start stupporing NodeJS 20 (`#3180`_)
164+
- Added functionality to trigger multiple downloads at a time and not wait for them to finish (`#3231`_)
165+
- Remove ALL deprecated features. (`Click` etc) (`#3243`_)
166+
- Support Playwright 1.40 (TimeoutError became Error) (`#3252`_)
167+
168+
169+
Full list of fixes and enhancements
170+
===================================
171+
172+
.. list-table::
173+
:header-rows: 1
174+
175+
* - ID
176+
- Type
177+
- Priority
178+
- Summary
179+
* - `#2679`_
180+
- bug
181+
- critical
182+
- storageState can't use in New Persistent Context
183+
* - `#2968`_
184+
- bug
185+
- critical
186+
- stdout to logfile prevents playwright to work correctly
187+
* - `#3154`_
188+
- bug
189+
- critical
190+
- When using M1 or M2 chip and sunning macOS Sonoma Browser library might cause a hang
191+
* - `#3254`_
192+
- enhancement
193+
- critical
194+
- Robot Framework 7.0 Support and Support for Return Types
195+
* - `#1702`_
196+
- bug
197+
- high
198+
- Take screenshot filename argument failing when registered to be run on failure
199+
* - `#3208`_
200+
- bug
201+
- high
202+
- [Setting Scope is broken] "Set Browser Timeout" does not work together with "Wait for Condition"
203+
* - `#3219`_
204+
- bug
205+
- high
206+
- Permissions uses _ (underscore) instead of - (dash)
207+
* - `#2571`_
208+
- enhancement
209+
- high
210+
- Keyword "Set Assertion Formatters" should have a scope
211+
* - `#2676`_
212+
- enhancement
213+
- high
214+
- Add keyword: Attach to Running Browser (Extend `Connect To Browser`)
215+
* - `#3180`_
216+
- enhancement
217+
- high
218+
- Drop support NodeJS 16 and start stupporing NodeJS 20
219+
* - `#3264`_
220+
- enhancement
221+
- high
222+
- Create Keyword and CLI option to "launch" a Playwright "BrowserServer"
223+
* - `#395`_
224+
- enhancement
225+
- high
226+
- [Feature] Go to should return HTTP status code
227+
* - `#1688`_
228+
- bug
229+
- medium
230+
- Incorrect path and filename when Take Screenshot registered to run on failure
231+
* - `#2129`_
232+
- bug
233+
- medium
234+
- `statusText` is empty for HTTP/2 request in Chromium
235+
* - `#2754`_
236+
- bug
237+
- medium
238+
- Examples at https://robotframework-browser.org/ broken
239+
* - `#3006`_
240+
- bug
241+
- medium
242+
- Question - argument - enable_presenter_mode
243+
* - `#3156`_
244+
- bug
245+
- medium
246+
- Misleading log message
247+
* - `#3200`_
248+
- bug
249+
- medium
250+
- `Promise To` does not work with `*args`
251+
* - `#3242`_
252+
- bug
253+
- medium
254+
- New Page and New Persistent Context do not close again if `Go To` fails
255+
* - `#3256`_
256+
- bug
257+
- medium
258+
- rfbrowser init logs wrong installation path
259+
* - `#1098`_
260+
- enhancement
261+
- medium
262+
- [Feature] Promise To Wait For Download with custom timeout argument
263+
* - `#1263`_
264+
- enhancement
265+
- medium
266+
- Automatic Closing Level MANUAL: keep open after terminating the test
267+
* - `#1811`_
268+
- enhancement
269+
- medium
270+
- Add waitUntil support for New Page and Go To keywords
271+
* - `#2135`_
272+
- enhancement
273+
- medium
274+
- Enhance entry.py to allow for an additional package.json
275+
* - `#3019`_
276+
- enhancement
277+
- medium
278+
- 'Get Element By' cannot get element locator in iframe
279+
* - `#3203`_
280+
- enhancement
281+
- medium
282+
- Need a way to define the playwright-log.txt outputdir when using Browser in python
283+
* - `#1734`_
284+
- ---
285+
- medium
286+
- Better handling of `downloadPath` and better documentation. Adding of `saveAs` argument to `Download` keyword.
287+
* - `#1655`_
288+
- enhancement
289+
- low
290+
- [Feature] Add timeout argument to Wait For Alert
291+
* - `#3230`_
292+
- enhancement
293+
- ---
294+
- Add support for custom formatters. (lambda functions)
295+
* - `#3231`_
296+
- enhancement
297+
- ---
298+
- Added functionality to trigger multiple downloads at a time and not wait for them to finish
299+
* - `#3243`_
300+
- enhancement
301+
- ---
302+
- Remove ALL deprecated features. (`Click` etc)
303+
* - `#3252`_
304+
- enhancement
305+
- ---
306+
- Support Playwright 1.40 (TimeoutError became Error)
307+
308+
Altogether 32 issues. View on the `issue tracker <https://github.com/MarketSquare/robotframework-browser/issues?q=milestone%3Av18.0.0>`__.
309+
310+
.. _#2679: https://github.com/MarketSquare/robotframework-browser/issues/2679
311+
.. _#2968: https://github.com/MarketSquare/robotframework-browser/issues/2968
312+
.. _#3154: https://github.com/MarketSquare/robotframework-browser/issues/3154
313+
.. _#3254: https://github.com/MarketSquare/robotframework-browser/issues/3254
314+
.. _#1702: https://github.com/MarketSquare/robotframework-browser/issues/1702
315+
.. _#3208: https://github.com/MarketSquare/robotframework-browser/issues/3208
316+
.. _#3219: https://github.com/MarketSquare/robotframework-browser/issues/3219
317+
.. _#2571: https://github.com/MarketSquare/robotframework-browser/issues/2571
318+
.. _#2676: https://github.com/MarketSquare/robotframework-browser/issues/2676
319+
.. _#3180: https://github.com/MarketSquare/robotframework-browser/issues/3180
320+
.. _#3264: https://github.com/MarketSquare/robotframework-browser/issues/3264
321+
.. _#395: https://github.com/MarketSquare/robotframework-browser/issues/395
322+
.. _#1688: https://github.com/MarketSquare/robotframework-browser/issues/1688
323+
.. _#2129: https://github.com/MarketSquare/robotframework-browser/issues/2129
324+
.. _#2754: https://github.com/MarketSquare/robotframework-browser/issues/2754
325+
.. _#3006: https://github.com/MarketSquare/robotframework-browser/issues/3006
326+
.. _#3156: https://github.com/MarketSquare/robotframework-browser/issues/3156
327+
.. _#3200: https://github.com/MarketSquare/robotframework-browser/issues/3200
328+
.. _#3242: https://github.com/MarketSquare/robotframework-browser/issues/3242
329+
.. _#3256: https://github.com/MarketSquare/robotframework-browser/issues/3256
330+
.. _#1098: https://github.com/MarketSquare/robotframework-browser/issues/1098
331+
.. _#1263: https://github.com/MarketSquare/robotframework-browser/issues/1263
332+
.. _#1811: https://github.com/MarketSquare/robotframework-browser/issues/1811
333+
.. _#2135: https://github.com/MarketSquare/robotframework-browser/issues/2135
334+
.. _#3019: https://github.com/MarketSquare/robotframework-browser/issues/3019
335+
.. _#3203: https://github.com/MarketSquare/robotframework-browser/issues/3203
336+
.. _#1734: https://github.com/MarketSquare/robotframework-browser/issues/1734
337+
.. _#1655: https://github.com/MarketSquare/robotframework-browser/issues/1655
338+
.. _#3230: https://github.com/MarketSquare/robotframework-browser/issues/3230
339+
.. _#3231: https://github.com/MarketSquare/robotframework-browser/issues/3231
340+
.. _#3243: https://github.com/MarketSquare/robotframework-browser/issues/3243
341+
.. _#3252: https://github.com/MarketSquare/robotframework-browser/issues/3252
342+
.. _Foundation: https://robotframework.org/foundation/

0 commit comments

Comments
 (0)