Commit Graph

165 Commits

Author SHA1 Message Date
Joey Parrish 28b73b921d fix(hls): Fix type error in lazy-loading (#4687)
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.
2022-11-11 07:07:58 -08:00
github-actions[bot] 393df0645f chore(main): release 4.3.0 (#4424)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2022-11-10 14:51:32 -08:00
Vinod 3c75d1a71a fix: Fixed LCEVC decode breaking dependencies issue and read me addition (#4565)
Changes are as follows:
1. Fixed demo breaking dependencies.
2. Fixed some typos
3. Added LCEVC support section to readme.

Co-authored-by: Vinod Balakrishnan <vinod.balakrishnan@v-nova.com>
2022-10-11 13:27:29 -07:00
fabio-murra 284ea63a60 feat: LCEVC Integration (#4050)
Integration of MPEG-5 Part-2 LCEVC into Shaka Player.

A config must be enabled and a canvas element must be provided.

The Shaka Player UI will automatically provide an appropriate canvas.

Co-authored-by: Vinod Balakrishnan <vinod.balakrishnan@v-nova.com>
Co-authored-by: Vinod <36663769+vinod-balakrishnan@users.noreply.github.com>
Co-authored-by: Vinod <vinod.balakrishnan111@gmail.com>
2022-10-03 11:32:27 -07:00
github-actions[bot] 4781fc6563 chore(main): release 4.2.0 (#4273)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2022-08-16 18:06:09 -07:00
Joey Parrish e9d836ac32 test: Fix Tizen test failures due to ES6 in polyfill (#4398)
The upgraded polyfill fixes this.

See shaka-project/eme-encryption-scheme-polyfill#49
2022-08-10 11:12:47 -07:00
Wojciech Tyczyński e6b6d7c24b feat: Upgrade eme-encryption-scheme-polyfill to support ChromeCast version of PlayReady (#4378) 2022-08-01 12:34:16 -07:00
Álvaro Velad Galván 5b18069430 feat: Add fallback to TextDecoder and TextEncoder (#4324)
Related to https://github.com/shaka-project/shaka-player/commit/a72a1e91023a33c777a6001a64f818ea2e469914
2022-07-11 10:24:11 -07:00
pszemus 294253e4ae chore: Update mux.js to 6.2.0 (#4338)
mux.js v6.2.0 introduces changes that are useful while parsing ID3 HLS in-band metadata.
2022-07-08 13:12:58 -07:00
Joey Parrish db1b20ec77 fix: New EME polyfill fixes EME/MCap issues on some smart TVs (#4279) 2022-06-07 14:20:17 -07:00
github-actions[bot] 913ee57fd5 chore(main): release 4.1.0 (#4235)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2022-06-03 08:01:26 +02:00
Álvaro Velad Galván dc88fe0814 chore: Update mux.js to 6.1.0 (#4259)
Closes #3761
2022-05-31 09:28:44 -07:00
Dulmandakh a6b7148d8d chore: require node 14 or above (#4219)
Most of our existing dev dependencies require node 12+, and node 16 is the active LTS for several more months.  Let's make node 14 the required minimum for Shaka Player development, to avoid issues with our dev deps failing on older versions.
2022-05-12 12:06:44 -07:00
github-actions[bot] 20ddf6aa53 chore(main): release 4.0.0 (#4009)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2022-05-02 12:58:17 -07:00
Joey Parrish d1699de19b test: Fix Safari tests hanging in GitHub Actions environment (#4144)
Fixed upstream in shaka-project/karma-local-wd-launcher#38

Closes #3967
2022-04-21 08:52:36 -07:00
Joey Parrish d8b3341720 test: Run tests on a custom Selenium grid (#4117)
Includes a YAML config file for our lab, and documentation on how to
create a custom config for another Selenium grid.

A workflow will run tests nightly in the Shaka lab, using a
self-hosted runner with access to our private grid.

The workflow can also be triggered manually by maintainers to test a
PR in the lab.  This will report status back to the PR.
2022-04-12 11:32:59 -07:00
Joey Parrish 9660ce85df fix: Fix broken deps file generation on Windows (#4086)
This fixes broken deps file generation on Window by upgrading to a
pre-release version of the deps tool.  The upstream issue was filed in
https://github.com/google/closure-library/issues/1159 and fixed in
https://github.com/google/closure-library/pull/1160.

This issue has never affected a release version of Shaka Player, and
was introduced when we switched deps tools in 6f274cbc.

Closes #4085
2022-03-30 19:25:55 -07:00
Joey Parrish 55eab2198c chore: Upgrade HTMLHint to new version with vulnerability fixed (#4071)
We were using a pre-release version of the same for a while, but this
is the same fix in an official release.
2022-03-29 09:37:23 -07:00
Joey Parrish 6f274cbc97 build: Stop using deprecated tool to generate closure deps (#4060)
The depswriter.py tool from google-closure-library was generating
deprecation warnings.  This switches to a newer, rewritten version
called google-closure-deps.
2022-03-23 15:08:01 -07:00
Joey Parrish 3f838cfd3a ci: Deploy demo to appspot nightly and on releases (#4038)
This imports our appspot code into the repo and updates all of it to
Python 3.
2022-03-21 11:15:40 -07:00
Joey Parrish f5f517759f chore(deps): Upgrade less to v4 (prerelease) (#4028)
In #3991, I changed the syntax of our colors to a modern rgba syntax.
For example, rgba(255, 255, 255, 0.85) would become rgba(255 255 255 /
85%). However, less v3 seems not to understand that properly, and
performs division on the last two parts, resulting in output of
rgba(255 255 3%), which is indeed invalid.

This fixes the issue by upgrading to less v4, which understands the
new rgba syntax and leaves it alone. The output for that will now
match the input.

To work around an issue with less v4, this uses a prerelease version
with a fix for https://github.com/less/less.js/issues/3693 . See also
https://github.com/tomas/needle/issues/391

This doesn't affect any release branches, since #3991 hasn't been
cherry-picked.

Closes #4027
2022-03-15 14:53:54 -07:00
Joey Parrish 1507b1e844 chore: Update URLs after moving projects (#4008) 2022-03-03 14:34:40 -08:00
Joey Parrish 4aab0cc0ba build: Replace less-plugin-clean-css and htmlhint with forks (#3995)
These projects have vulnerable dependencies, but are not being
properly maintained.  This replaces both with forks that have upgraded
their deps.

This brings the NPM audit vulnerability count from 6 to 0.
2022-02-23 13:01:47 -08:00
Joey Parrish c318a11caa build: Update jsdoc fork (#3994)
This updates the jsdoc fork to one based on the latest jsdoc.  (The
fork adds features for tutorial sorting.)

We also have an in-repo fork of the default jsdoc template from 2019.
The newer default template no longer includes the same dependencies,
so three deps we used to get transitively from jsdoc are now explicit
at the shaka-player level: open-sans-fonts, code-prettify, and
color-themes-for-google-code-prettify.  This is appropriate, since the
dependency comes from our in-repo fork of the default template.

This upgrade brings our NPM audit vulnerabilities from 10 to 6.
2022-02-22 16:22:48 -08:00
Joey Parrish a5e9ed61eb build: Upgrade CSS linter (#3991)
The new version requires additional configuration for less syntax, and
has new default rules we were out of compliance with.

I disabled rules about avoiding explicit vendor prefixes (such as
"-webkit") because we are not using any auto-prefixer tools.  Other
violations have been fixed:

 - kebab-case for element ids
 - quotes around URLs
 - double quotes instead of single quotes
 - disable class selector pattern matching for MDL (external)
 - use modern rgb/rgba syntax
 - no quotes on font families
 - no long-hand when short-hand will do

This brings our NPM audit vulnerabilities from 20 down to 10.
2022-02-22 14:16:22 -08:00
Joey Parrish a67cb6ed00 build: Downgrade less (#3982)
Downgrade less to v3.  v4 is failing on macOS for some reason.  See
less/less.js#3693

This also makes some less/CSS changes that are useful for future
upgrades:

 - wrap all calculations in calc(), which is required in less v4
 - remove unneeded @transparent variable

Finally, this fixes an erroneous error message that said "extern
generation failed" instead of "CSS compilation failed".

Closes #3981
2022-02-22 08:46:54 -08:00
Joey Parrish a2c853522f build: Update babel (#3979)
This updates babel and its various plugins and associated modules,
which brings our NPM audit vulnerability count from 24 to 20.
2022-02-18 11:28:36 -08:00
Joey Parrish d99ab7959d build: Update eslint (#3977)
Also fixes linter errors found by the new versions
2022-02-18 08:26:43 -08:00
Joey Parrish c482e81ad9 build: Update Closure Compiler (#3976)
This updates the compiler and closure library to the latest releases.
This required a few small tweaks:

 - Drop custom extern for WebCrypto (now built into the compiler)
 - Remove require() in cea parser, only used in `throws` annotations
 - Hack around a typing issue in a fake version of TextTrack in tests
2022-02-17 18:55:49 -08:00
Joey Parrish 49fbcb4e5a build: Update most dev dependencies (#3973)
Most dependencies are not used in Shaka Player itself, but in our
build and test infra or in our demo app.  Still, GitHub reported 29
potential vulnerabilities in these deps, and NPM reported 37.

The changes below being NPM's audit report from 37 down to 24
vulnerabilities.

Detailed updates:
 - Dropped explicit deps for transitive dependencies that we no longer
   need to update for ourselves:
   - ua-parser-js (via karma)
 - Dropped because we no longer need them:
   - karma-ie-launcher
 - Updated to latest versions:
   - awesomplete
   - core-js
   - dialog-polyfill
   - htmlhint
   - jimp
   - karma*
   - less
   - pwacompat
   - rimraf
   - tippy.js
   - which
 - Updated as far as possible without code or config changes in Shaka:
   - mux.js
   - stylelint*
 - Still needs an update:
   - *babel*
   - eslint
   - eslint-config-google
   - google-closure-compiler
   - google-closure-library

Some of the vulnerabilities stem from stylelint, babel, and others
that haven't been updated yet, so follow-up work is needed to address
those with breaking updates.

mux.js is actually used at runtime (optional), so it was only updated
to the latest non-breaking release.
2022-02-17 13:52:24 -08:00
Joey Parrish 4bb2c14195 test: Fix failing WebDriver installations (#3943)
https://github.com/joeyparrish/webdriver-installer/pull/8
2022-02-11 15:28:29 -08:00
Joey Parrish 7155ec73bc test: Switch local Chrome, Edge, Firefox, and Safari launchers to WebDriver-based (#3921)
* test: Switch local Chrome, Edge, Firefox, and Safari launchers to WebDriver-based

This will enable WebDriver-based screenshot tests in local test runs.

* test: Add screenshots for Edge on Mac
2022-02-03 18:54:07 -08:00
Joey Parrish 76d4fd9553 test: Make screenshot comparisons more tolerant (#3916)
Instead of pixel-wise comparison with a change threshold, we now use a
structural similarity (ssim) module to decide how much a screenshot
has changed.  This better tolerates small rendering differences due to
differences in GPUs across machines.
2022-01-31 15:20:43 -08:00
Joey Parrish d15397bfcc chore: Upgrade Karma Safari launcher
This newer launcher is based on WebDriver and seems to work better with GitHub Actions.

Change-Id: I8ea0ff5cd1c975179ffe99c04a9c99601815855f
2022-01-09 19:52:24 +00:00
Joey Parrish 824d8b5fa1 chore: Update master branch version number to prepare for v3.3 release
Change-Id: Ie7565815c52bd94f571c9029d0a521b6d8e9a923
2022-01-07 12:01:22 -08:00
Joey Parrish 291c93e5fd chore: Update changelogs for v3.2.0, v3.1.2, v3.0.13
Change-Id: I2080bc4cf7547cc784f780893f2f7de7144bea0e
2021-07-14 08:37:59 -07:00
Joey Parrish 87797157af chore: Upgrade compiler
The latest compiler should treat `@expose` as a parser error, so the
BanExpose conformance rule is no longer needed.

This upgrades the compiler & closure libraries to the latest releases
from NPM, makes matching updates to the compiler command line (no more
`strictMissingRequire` error category), and removes the BanExpose
conformance rule.

Change-Id: I45e8e71ad5f42fee289a8ddd30141e15f3f425a8
2021-05-13 13:15:09 -07:00
Joey Parrish d5f10bb33c chore: Update changelog for v3.1.0
Change-Id: I376d50f099fdd3ecd3622d9ac0c4b90f14424fdb
2021-04-30 01:01:05 +00:00
Michelle Zhuo c2db6d4896 fix(MediaCap): update EME polyfill version
Issue #1391

Change-Id: I9f990b4e77950b436a0f007999f55bb160d1673b
2021-04-20 16:08:46 +00:00
Álvaro Velad Galván e6108060bd test: Allow testing with Edge Chromium in Karma (#3265) 2021-03-30 16:36:53 -07:00
Michelle Zhuo 57ee23812e feat(MediaCap): Use MediaCapabilities for supporting info
In StreamUtils, use MediaCapabilities.decodingInfo() instead of
MediaSource.isTypeSupported() to check if the stream is supported.

MediaCapabilities.decodingInfo() takes an
MediaDecodingConfiguration object as input, and returns a Promise
with a MediaCapabilitiesInfo object. The returned object tells us
whether decoding the media is supported, smooth, and
powerefficient.

Steps:
1. Create a MediaDecodingConfiguration object for each variant as
   the input.
2. Query the decodingInfo API with the config.
3. Get the 'supported' info from the decodingInfo result, to know
   whether the variant is supported.

Issue #1391

Change-Id: I8fc2d3ec6a9868f38269d550d35f45c298faae98
2021-03-12 21:41:53 +00:00
Joey Parrish 0f9bf71994 test: Fix detection of Xbox & Chromecast in Karma
Karma had an explicit dependency on ua-parser-js "0.7.22".  Not
"^0.7.22", which is a range including newer bugfix releases, but
_exactly_ 0.7.22.  This meant our explicit requirement for a newer
version of ua-parser-js wasn't working, because it conflicted with
Karma's.

This dependency bug was fixed in Karma v6.  Upgrading Karma to v6
allows us to get an updated version of ua-parser-js which includes
fixes for Xbox & Chromecast detection.  (Karma's new dependency is
"^0.7.23", which includes 0.7.24, where Xbox detection was fixed.)

We will keep our explicit dependency on ua-parser-js "^0.7.24", which
will ensure we don't get 0.7.23, which could not correctly detect Xbox
One (which we now support).  But this explicit dependency no longer
conflict's with Karma's, and will serve as an "upgrade" to theirs.

Change-Id: I72b0df9c1bda33c0ae937d79e0b143b1219ef1cb
2021-02-26 22:11:38 +00:00
Joey Parrish eb4023f6df test: Unfork ua-parser-js
The ua-parser-js fork was created to add Xbox One detection support,
but the PR has been merged and the released upstream as 0.7.24.

Change-Id: I14016837bc20da43b077fef7654f9bab8404046e
2021-02-22 11:01:14 -08:00
Joey Parrish f9065705f4 test: Fix recognition of Xbox One in Karma
This updates the UA parser to one that recognizes Xbox devices
including Xbox One.  Corresponds to PR faisalman/ua-parser-js#479

Change-Id: I5e92e78b06c981df1659f73264b6fabfc5eb56ac
2021-02-10 20:37:51 +00:00
Joey Parrish 7544670ee5 chore: Upgrade eslint
The new eslint found many style errors which have now been corrected.

It also complains a lot about atomic update issues that do not seem to
exist, so that rule has been disabled.

This upgrade will allow us to adopt eslint's "id-denylist" instead of
the older "id-blacklist" rule, the name of which violates new Google
guidelines about respectful language.

Bug: 178203011

Change-Id: Ia65581b96e4dd1331f720fa396183dca020b9caf
2021-02-01 23:36:12 +00:00
Theodore Abshire 4ace4395b9 chore: Upgrade stylelint
For a while, we were forced to use a fork of stylelint with a
bugfix necessary for our test bots to run the tool.
That behavior has now been merged into normal stylelint, so we
can stop using that fork.

Change-Id: I51196f8dab73ac1f814137d2f191a08c231fd369
2021-01-07 23:06:16 +00:00
Joey Parrish dd1674be7f chore: Upgrade less
We used to avoid less v3.12 because of a bug, but it seems to be fixed
in less v3.13.

Change-Id: I83a517cec264d4f00af5e1ff31e9be68d5cef2e1
2021-01-07 13:04:01 -08:00
Joey Parrish fc0df44645 chore: Release v2.5.19 and v3.0.7
Change-Id: I07b597b66af49ccd7dc5610965abe55c3156383f
2021-01-06 15:08:29 -08:00
Álvaro Velad Galván 2c07646fee chore: Update mux.js (#3023)
This new version supports CEA-708
2020-12-16 17:40:51 -08:00
michellezhuo 221f8a82e0 build: add goog.require for compiler upgrade (Part 7)
Change-Id: I4607f36260eed511ed71d5672fde8a0e1afd61d7
2020-10-16 20:37:05 -07:00