This upgrades the compiler and reworks the AbortSignal polyfill to match
the new compiler externs for that class. This is important to make Shaka
Player compatible with the latest compilers in use inside Google.
Note that the Closure compiler is deprecated, so this should be our
final upgrade. We will some day move to TypeScript.
This does _not_ update the Closure library, because the latest version
causes failures we don't understand in the loading mechanism in
test/test/boot.js.
Chromecast WebDriver Server and Karma both used iframes, which caused
complications when testing on Chromecast. The test environment couldn't
directly access `cast.__platform__` APIs, and more recently stopped
being able to access EME due to presumed mistakes in the platform's
implementation of iframe permission policies.
This resolves the issue by removing iframes at both levels.
- Flatten Karma's environment using "useIframe: false" and "runInParent: true"
- Remove test flag --single-run; not supported in combination with Karma's "useIframe: false" option
- Add a test boot file to force closure to use dynamic script tags instead of document.write; required with Karma's "useIframe: false" option
- Adjust screenshot tests not to assume an iframe host
- Fix compatibilty between Tizen and Karma's useIframe:false
- https://github.com/joeyparrish/karma/commit/32e87357a0ca4bf5d3de6d78d80dae2d065fd407
- https://github.com/joeyparrish/karma/commit/f2132cc2cf72f9408fbce2a20b5a21999f1e9416
- Upgrade the encryption scheme polyfill to a version that is resilient
against multiple copies (one in compiled shaka library, one in source
form).
---------
Co-authored-by: Álvaro Velad Galván <ladvan91@hotmail.com>
These changes are necessary for compatibility with Chromecast WebDriver Server v2.
- Fix a bug in Karma's flat environment support (joeyparrish/karma@9875e98)
- Add a test boot file to load CAF on Chromecast devices; required by Chromecast WebDriver Server v2's redirect mode (flat environment at that level)
- Also load this cast-boot file in support.html
- Rename/reorganize Cast-related externs, which were messy even before the addition of CAF
- Remove proxy-cast-platform.js; no longer needed as we move to flatten the test environment
- Ignore error events with "null" error; these appear on Linux Chromecasts, only since including CAF
- Ignore error events that are actually strings; these appear on Linux Chromecasts, only since including CAF
- Disable Fuchsia in the lab until autoplay issues can be resolved
Features for LCEVC Decoder integration into Shaka player:
Initially in this PR we had changes to shaka player to accommodate
changes for iOS fullscreen functionality. But now we have a way to do
that inside the scope of lcevc decoder. So the only change in this PR is
the version bump of the lcevc decoder library.
The issue we had in less.js v4 has since been resolved. This updates to
less.js v4.2.0, which includes the underlying fix from its dependency,
needle v3.1.0.
Unforking also resolves CI issues where gitpkg.now.sh temporarily fails
to load, causing the whole test run to fail before it can start.
This updated version of karma-local-wd-launcher incorporates
https://github.com/shaka-project/karma-local-wd-launcher/pull/65 to
supply a path to the Edge binary on all platforms. This fixes local
testing and GitHub CI testing of Edge.
Though the tests run once more, there are still some test failures that
need to be dealt with.
This caches Babel's transpiler output for reuse, and should speed up all
test runs in theory, but the effect is most noticeable on local test
runs.
This uses a fork of karma-babel-preprocessor, which contains
https://github.com/babel/karma-babel-preprocessor/pull/77. If/when that
PR is merged, we can move back to the upstream module.
Local runs will start faster because only modified source files will be
re-processed through Babel when the tests start up.
In the Selenium workflow, Babel output and node_modules will both be
computed by the singular build-shaka job, stored, and then reused by all
the Selenium lab matrix jobs.
On my workstation (3.3 GHz cores, 32GB RAM, spinning platter disk), I
see tests start about ~60 seconds faster. In the lab (2.1-4.7 GHz cores,
64GB RAM, solid-state disk), I see tests start about ~10 seconds faster.
Before packaging for NPM, remove the "engines" section of package.json
to avoid unnecessary restrictions on node versions for projects that
simply depend on Shaka Player, but don't need to rebuild it. This is
accomplished with the clean-package tool:
https://github.com/roydukkey/clean-package
The "engines" section and its restrictions still make sense for Shaka
Player development, so it will not be removed from package.json in the
repo.
Closes#5243
There was a potential type error in an edge case in lib/player.js. It
would have been caught by the latest compiler, so this upgrades the
compiler and fixes another type error in one other place, as well.