Commit Graph

19 Commits

Author SHA1 Message Date
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
dependabot[bot] 65b3a2fc1f build(deps): bump async from 2.6.3 to 2.6.4 (#4132)
Bumps [async](https://github.com/caolan/async) from 2.6.3 to 2.6.4.
- [Release notes](https://github.com/caolan/async/releases)
- [Changelog](https://github.com/caolan/async/blob/v2.6.4/CHANGELOG.md)
- [Commits](https://github.com/caolan/async/compare/v2.6.3...v2.6.4)

---
updated-dependencies:
- dependency-name: async
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-04-15 09:46:06 -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 3f55c82498 test: Drop indirect dep on vulnerable minimist module (#4042)
Minimist is vulnerable to prototype pollution, and is no longer
receiving updates.  Details of the vulnerability can be found here:
https://github.com/advisories/GHSA-xvch-5gv4-984h

This updates our indirect dep on json5 to remove its minimist dep.

Jimp, Karma, and WD all rely on v0 of mkdirp, which uses minimist.
This forces them to use v1 of mkdirp, a rewrite which doesn't use
minimist.
2022-03-21 14:53:07 -07:00
Joey Parrish 3c5ae1cb31 chore: Remove SSH URLs from package-lock.json (#4037)
This was causing issues with older versions of npm.
2022-03-21 09:36:29 -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 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 746d2536a0 ci: Commit package-lock.json for CI stability (#3938)
This is recommended by npm to allow CI to get stable results when
installing dependencies.
2022-02-10 13:59:46 -08:00