When we create the first page in the default context in headless mode on mac,
it gets NSWindow that is "not visible". Although we call [window setIsVisible:YES],
later on window.isVisible still returns NO.
We create our offscreen "headless" NSWindow directly from applicationDidFinishLaunching:.
Experiments show that delaying this by 100ms makes everything work. As a symptom,
we get applicationDidUnhide: notification that does not happen when we create the window
immediately.
Perhaps, we create the window too early, and there is some essential initialization
that happens after applicationDidFinishLaunching:. However, if we call
[NSApp activateIgnoringOtherApps:YES] like we do in headful mode, everything works.
The only solution that worked so far is creating the first page after a timeout.
Even though we're undergoing migration to GitHub self-hosted runners,
they don't currently support running natively under Arm. The resulting build ends up to be
x86_64.
See https://github.com/actions/runner/issues/805
Github self-hosted runners currently run under rosetta:
https://github.com/actions/runner/issues/805
This patch is an attempt to build arm webkit from-inside rosetta
shell on arm hardware.
`WK_CHECKOUT_PATH` defines location of webkit checkout on the
file system. All browser-related scripts, like `prepare_checkout.sh` and
`export.sh` respect this environment variable on all platforms.
**Preamble**
1. We're trying to setup a windows-based github self-hosted runner in the
playwright-internal repo.
1. Commands on Windows are mandated to have total arguments length
less then 32767 characters.
1. On windows, github self-hosted runner framework puts repository
checkout at `c:\w\playwright-internal\playwright-internal`
1. Our scripts create a checkout at
`c:\w\playwright-internal\playwright-internal\browser_patches\firefox\checkout`
1. One of the scripts in Firefox buildsystem tries to execute a command,
passing lots of absolute paths to various webidl's
1. The command fails due to restriction in (2)
**Problem**
Firefox build fails since checkout is deeply nested and hits max arg
size on windows.
**Solution**
This patch introduces a new variable `FF_CHECKOUT_PATH` that is
respected by all browser-related scripts. This way we'll be able
to checkout firefox to `c:\firefox` and avoid hitting long arguments
limit.