mirror of
https://github.com/feder-cr/invisible_playwright.git
synced 2026-06-07 08:35:12 +02:00
- Add profile_dir= kwarg to InvisiblePlaywright (sync + async). Maps to firefox.launch_persistent_context(); returns a BrowserContext. Cookies / localStorage / extensions / cache / prefs all persisted. - Drop the firefox-4 era workaround that filtered locale + timezone_id out of the persistent kwargs. firefox-5 ships the C++ docShell.overrideTimezone IDL method (50 LOC patch in docshell/base/nsIDocShell.idl + nsDocShell.cpp, see patch.md section 19 in feder-cr/invisible-firefox), so per-realm overrides land without crashing the launch handshake. - Bump BINARY_VERSION firefox-4 -> firefox-5. - Sentinel unit tests added: persistent kwargs MUST include locale + timezone_id (defends against re-introducing the workaround) and must NOT include timezone_id when timezone="" is the "host TZ" sentinel. Validation: smoke test against the local firefox-5 build, persistent context UP in 21s (was 180s timeout), Intl.timeZone == Europe/London, hardwareConcurrency / screen / DPR / locale all reflect the PIN.
8.8 KiB
8.8 KiB
Changelog
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
Unreleased
[0.1.6] - 2026-05-21
Added
profile_dir=kwarg onInvisiblePlaywright(sync + async). When set, the session usesfirefox.launch_persistent_context()so cookies, localStorage, sessionStorage, extensions, cache and prefs are kept on disk between runs.__enter__returns aBrowserContextdirectly:with InvisiblePlaywright(profile_dir=p) as ctx: ctx.new_page(). Pair with a stableseed=to also pin the fingerprint identity across runs. First run creates the dir; subsequent runs reuse it.
Fixed
launch_persistent_context(timezone_id="…")no longer times out at 180s. Root cause:juggler/content/main.jscallsdocShell.overrideTimezone(...)on every navigation; the patched Firefox up to firefox-4 didn't expose that IDL method onnsIDocShell, so the call threwTypeError: docShell.overrideTimezone is not a function. On the non-persistent path the error fired after launch and was harmless; on the persistent path it blocked the launch handshake.firefox-5ships the C++ method (seepatch.mdsection 19); this release removes the firefox-4 era Python workaround that was filteringlocale/timezone_idout of the persistent context kwargs.
Changed
BINARY_VERSIONbumped fromfirefox-4tofirefox-5. The Python source delta is JS/Python only; the new Firefox build adds 50 lines of C++ indocshell/base/nsIDocShell.idl+nsDocShell.cpp.
[0.1.5] - 2026-05-20
Fixed
- #15:
python -m invisible_playwright fetchraisedRuntimeError: no SHA256 for firefox-150.0.1-stealth-linux-x86_64.tar.gz in checksums.txtfor every user because the parser kept the*binary-mode prefix thatsha256sumwrites in front of filenames. Now.lstrip("*")is applied to the key. Reporter + patch: @LostBoxArt. Unrelated to thefirefox-Nbinary; existing caches still work, only first-time fetches were broken.
[0.1.4] - 2026-05-20
Fixed
- #13: every page that threw an uncaught JS error (e.g. bunny.net) crashed the Playwright client with
TypeError: Cannot read properties of undefined (reading 'url'). Root cause: upstream Playwright Juggler added a requiredlocationfield to thePage.uncaughtErrorevent in the 2026-05-07 roll (microsoft/playwright@c8604ec); our fork was carrying the pre-roll schema in everyfirefox-Nbuild. Fix matches upstream — Runtime.js builds theerrorLocation, PageAgent.js forwards it on both worker and runtime error paths, Protocol.js declares the schema field. Reporter: @dionorgua.
Changed
BINARY_VERSIONbumped fromfirefox-3tofirefox-4. JS-only change insidechrome/juggler/;xul.dllandfirefox.exeare byte-identical tofirefox-3.
[0.1.3] - 2026-05-19
Changed
BINARY_VERSIONbumped fromfirefox-2tofirefox-3. The new archives on both Windows and Linux are built from a clean clone of feder-cr/invisible-firefox#stealth/150 — the consolidated source-of-truth fork (renamed fromfeder-cr/firefox; the companionfeder-cr/firefox-stealthpatches repo was deleted, all patches now live as commits on top ofmozilla-firefox/firefox).- The patched Firefox archive now ships the proper C++ implementation of
windowUtils.jugglerSendMouseEvent, replacing the JS shim from 0.1.2.
C++ fixes landed in this release
- C1+C2:
setDownloadInterceptorIDL + cpp (re-landed for FF150). - C4: 5
nsIDocShellstealth attributes (fileInputInterceptionEnabled,overrideHasFocus,bypassCSPEnabled,forceActiveState,disallowBFCache). - C5:
LauncherProcessWin.cpp+nsWindowsWMain.cppjuggler-pipe handle inheritance — without this, the Playwright pipe disconnects immediately on launch. - C6:
juggler-navigation-started-renderer/-browserobserver notifications innsDocShell.cppandCanonicalBrowsingContext.cpp— without these,Page.readynever fires andctx.new_page()hangs. - C7 (partial): storage stub for
nsIDocShell.languageOverride. WorkaroundInvisiblePlaywright(locale="")recommended until full BC FIELD port lands.
Verified
- Both archives built from same source: feder-cr/invisible-firefox commit
68906f1f9c55. - Windows + Linux smoke suite green: launch,
ctx.new_page(),page.mouse.{move,down,up,click,wheel},navigator.webdriver=false, sannysoft 32/33 PASS. - SHA256 published in
checksums.txton thefirefox-3release.
Notes
- This is the first release with a native Linux build of the patched binary (previous
firefox-3draft mentioned shipping the Linux firefox-2 archive byte-for-byte; that no longer applies — Linux now has the full C++ patch series).
[0.1.2] - 2026-05-18
Changed
BINARY_VERSIONbumped fromfirefox-1tofirefox-2. The patched Firefox archive on GitHub Releases now contains the JS fix from 0.1.1 (everypage.mouse.*/page.click()/locator.click()/mouse.wheel()failure on the FF150 binary). Users on 0.1.1 must runpython -m invisible_playwright clear-cache && python -m invisible_playwright fetchto pick up the new archive.
Verified
- Archive integrity tests on both platforms: Windows zip extracted + booted via Playwright (
mouse.move + click + page.click(selector)all succeed end-to-end), Linux tarball file-level checks (firefox/libxul.so sizes, byte-identity of patched JS files against Windows source). 21/21 assertions pass. - SHA256 published in
checksums.txton thefirefox-2release.
0.1.1 - 2026-05-18
Fixed
- Critical: every
page.mouse.*,page.click(selector),locator.click(),page.hover(),mouse.wheel()failed on the patched Firefox 150 binary withwin.windowUtils.jugglerSendMouseEvent is not a function. The Juggler JS was porting calls to a Playwright-specific C++ method that was never landed in the FF146→FF150 port; replaced with the Mozilla chrome-scopewin.synthesizeMouseEventhelper which is present in FF150. Six call sites patched acrossjuggler/protocol/PageHandler.jsandjuggler/content/PageAgent.js. Reporter: @trob9 — #9. _linkedBrowser.scrollRectIntoViewIfNeeded()is now guarded at both call sites inPageHandler.js(dispatchMouseEventanddispatchWheelEvent) — the method is not present on the shipped FF150<browser>element, so the unguarded call threw before the mouse event was dispatched.
Added
tests/test_mouse.py: 12-case regression suite covering every patched code path (mouse.move/click/dblclick/right-click, modifiers, locator.click/hover, wheel, manual mousedown+up, off-viewport move, humanize intermediate moves, scroll-and-click on offscreen element). Test cases inspired bymicrosoft/playwright-python/tests/async/test_click.py.- Community standards:
CODE_OF_CONDUCT.md,CONTRIBUTING.md,SECURITY.md,.github/ISSUE_TEMPLATE/*,.github/PULL_REQUEST_TEMPLATE.md.
Notes
- The Stealthfox humanize Bezier expansion continues to fire intermediate
mousemoveevents; the swap tosynthesizeMouseEventdoes not change the human-trajectory behavior (verified by test). - The reCAPTCHA v3 score (0.90) and FingerprintPro / CreepJS results documented in the README are unaffected —
synthesizeMouseEventis a legitimate Mozilla helper that does not increase the anti-detect surface. - A binary refresh of the patched Firefox archive on GitHub Releases is required for users to receive this fix (the Juggler JS is shipped inside the archive). The
BINARY_VERSIONwill be bumped tofirefox-2in that release.
0.1.0 - 2026-05-13
Added
- Initial public release.
InvisiblePlaywrightsync and async context managers — drop-in replacement forplaywright.sync_api.Browser/async_api.Browser.- StealthFox humanize hook: Bezier-curve mouse trajectories enabled by default.
_fpforgeBayesian fingerprint sampler with ~400 fields per session.- CLI:
invisible-playwright fetch | path | version | clear-cache. - Pinnable fingerprint fields via
pin={...}(seedocs/pinning.md). - SOCKS5 / SOCKS4 / HTTP / HTTPS proxy support with auth.
- Linux x86_64 and Windows x86_64 binary support.