JavaScript player library / DASH & HLS client / MSE-EME player
This report summarizes scanner evidence for shaka-project/shaka-player, a JavaScript project with 8,266 GitHub stars. SynthScan examined 629,065 lines of code across 1196 source files, recording 157 pattern matches distributed across 11 syntactic categories. The legacy adjusted pattern signal is 0.5 (Low pattern signal); it is not an authorship estimate.
Use the findings to ask whether maintainers can explain intent, verify dependencies, simplify unnecessary scaffolding, and focus review effort. Risk Payload v1 adds ownership, supply-chain, over-engineering, and review-effort vectors when available. These are prompts for human verification, not probabilities, security findings, or measured maintenance costs.
Use each vector to guide manual verification of the underlying findings.
Payload schema: 1.0.0 · Engine: 2.0.0 · Scoring: heuristic-density-v1 · Scan date: 2026-10-31.
Can maintainers explain intent, assumptions, and trade-offs? 143 finding(s).
Are imports declared and package/API names verified? 10 finding(s).
Are wrappers, guards, and repeated structures necessary? 66 finding(s).
Which changes need focused human review? 157 finding(s).
This chart tracks the legacy adjusted pattern score across scan runs. Changes can reflect source changes, scan coverage, or detector/scoring versions; they do not measure AI adoption or prove that a team refactored code. Compare runs only when their scoring versions are compatible. The dashed line tracks the raw pattern-hit count.
Groups findings by configured severity weight. Severity is not a confidence estimate, security rating, or proof that a package is missing. Verify imports against the project's manifests and inspect each finding in its local design context.
This horizontal bar chart shows where configured pattern scores accumulate across directories. Treat the bars as locations to inspect, not as evidence of authorship or code quality. Use the file-level findings to decide whether a directory needs a focused ownership, dependency, complexity, or review check.
The scanner identified 157 distinct pattern matches across 11 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a detector match to inspect in context. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.
Reading the findings table: The Severity column indicates the configured finding weight (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — legacy comment-context matches receive a ×1.5 score weight. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier under the legacy scoring model.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| CRITICAL | test/test/util/manifest_generator.js | 748 | this.manifest_.shaka_.media.SegmentIndex.forSingleSegment( | CODE |
| CRITICAL | lib/msf/packaging/mpeg2ts_program.js | 160 | if (shaka.msf.packaging.Mpeg2tsProgram.VIDEO_STREAM_TYPES_.has( | CODE |
| CRITICAL | lib/msf/drafts/draft18/session.js | 1059 | if (!shaka.msf.draft18.Session.END_OF_RANGE_.includes(flags)) { | CODE |
| CRITICAL | lib/msf/drafts/draft18/messages.js | 261 | return shaka.msf.draft18.MessageWriter.PARAMETER_ENCODINGS_.get(type) ?? | CODE |
| CRITICAL⚡ | lib/cea/cea608_memory.js | 175 | if (shaka.cea.Cea608Memory.CharSet.BasicNorthAmericanChars.has(b)) { | CODE |
| CRITICAL⚡ | lib/cea/cea608_memory.js | 177 | shaka.cea.Cea608Memory.CharSet.BasicNorthAmericanChars.get(b); | CODE |
| CRITICAL⚡ | lib/cea/cea608_memory.js | 185 | shaka.cea.Cea608Memory.CharSet.SpecialNorthAmericanChars.get(b); | CODE |
| CRITICAL⚡ | lib/cea/cea608_memory.js | 191 | shaka.cea.Cea608Memory.CharSet.ExtendedSpanishFrench.get(b); | CODE |
| CRITICAL⚡ | lib/cea/cea608_memory.js | 196 | shaka.cea.Cea608Memory.CharSet.ExtendedPortugueseGerman.get(b); | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | karma.conf.js | 501 | clientArgs.setupFiles = resolveGlobs([ | COMMENT |
| LOW | karma.conf.js | 641 | * @param {!Object} config | COMMENT |
| LOW | karma.conf.js | 841 | COMMENT | |
| LOW | app-engine/shaka-player-demo/app.yaml | 1 | # Copyright 2016 Google LLC | COMMENT |
| LOW | app-engine/shaka-player-demo/main.py | 1 | # Shaka Player Demo - Appspot Compatibility Shim | COMMENT |
| LOW | test/player_external.js | 41 | player = new compiledShaka.Player(); | COMMENT |
| LOW | test/test/boot.js | 101 | // https://developer.mozilla.org/en-US/docs/Web/API/ErrorEvent | COMMENT |
| LOW | test/test/boot.js | 441 | }); | COMMENT |
| LOW | test/test/boot.js | 781 | // other than those in the Shaka Player library, tracked by the Closure | COMMENT |
| LOW | test/test/util/test_scheme.js | 241 | // does, we use them in preference over everything else. There is a | COMMENT |
| LOW | test/cast/cast_receiver_integration.js | 141 | const p = waitForLoadedData(); | COMMENT |
| LOW | test/cea/mp4_cea_parser_unit.js | 141 | it('parses cea data from a segment with multiple trun boxes', () => { | COMMENT |
| LOW | test/hls/hls_parser_unit.js | 7981 | const originalSegmentIndex = video.segmentIndex; | COMMENT |
| LOW | test/offline/storage_integration.js | 441 | }); | COMMENT |
| LOW | test/offline/storage_mechanism_unit.js | 61 | // The mechanism used to drop such a connection on the floor: destroy() saw | COMMENT |
| LOW | test/media/region_observer_unit.js | 161 | // will step up our timeline and then step through it in small steps so that | COMMENT |
| LOW | test/media/streaming_engine_unit.js | 221 | setupManifest( | COMMENT |
| LOW | test/media/streaming_engine_unit.js | 601 | }); | COMMENT |
| LOW | test/media/streaming_engine_integration.js | 421 | expect(video.currentTime).toBeGreaterThan(0); | COMMENT |
| LOW | test/media/media_source_engine_integration.js | 1201 | // The 0.001 fudge that MediaSourceEngine applies to negative timestamp | COMMENT |
| LOW | test/media/media_source_engine_unit.js | 1261 | } | COMMENT |
| LOW | test/media/media_source_engine_unit.js | 1821 | COMMENT | |
| LOW | .github/workflows/release-please.yaml | 21 | pull-requests: write | COMMENT |
| LOW | .github/workflows/release-please.yaml | 221 | # the tag. So if you fork this package, update repository.url in | COMMENT |
| LOW | .github/workflows/compute-incremental-coverage.py | 1 | #!/usr/bin/env python3 | COMMENT |
| LOW | .github/workflows/compute-incremental-coverage.py | 81 | # } | COMMENT |
| LOW | .github/workflows/compute-incremental-coverage.py | 101 | # } | COMMENT |
| LOW | .github/workflows/compute-incremental-coverage.py | 121 | # }, | COMMENT |
| LOW | .github/workflows/shaka-bot-commands/command-help.sh | 1 | # Copyright 2016 Google LLC | COMMENT |
| LOW | .github/workflows/shaka-bot-commands/main.sh | 1 | # Copyright 2016 Google LLC | COMMENT |
| LOW | .github/workflows/shaka-bot-commands/command-test.sh | 1 | # Copyright 2016 Google LLC | COMMENT |
| LOW | .github/workflows/shaka-bot-commands/lib.sh | 1 | # Copyright 2016 Google LLC | COMMENT |
| LOW | lib/player.js | 3821 | } | COMMENT |
| LOW | lib/player.js | 4081 | this.adManager_.onManifestUpdated(this.isDynamic()); | COMMENT |
| LOW | lib/drm/drm_engine.js | 1761 | * @param {shaka.extern.Request} request | COMMENT |
| LOW | lib/drm/drm_engine.js | 2841 | // specified. | COMMENT |
| LOW | lib/net/http_fetch_plugin.js | 161 | const contentLength = | COMMENT |
| LOW | lib/msf/msf_parser.js | 1801 | COMMENT | |
| LOW | lib/msf/loc_parser.js | 481 | COMMENT | |
| LOW | lib/msf/packaging/loc.js | 61 | const basicInfo = shaka.media.SegmentUtils.getBasicInfoFromMimeType( | COMMENT |
| LOW | lib/util/player_configuration.js | 41 | const bandwidthEstimate = 1e6; // 1Mbps | COMMENT |
| LOW | lib/util/ts_parser.js | 781 | let pesPts = null; | COMMENT |
| LOW | lib/util/ts_parser.js | 1761 | COMMENT | |
| LOW | lib/util/mp4_parser.js | 341 | // 4 bytes channel count | COMMENT |
| LOW | lib/util/mime_utils.js | 361 | ('000' + parseInt(avcData.shift(), 10).toString(16)).slice(-4); | COMMENT |
| LOW | lib/util/periods.js | 1401 | if (candidateRoleMatches.length > bestRoleMatches.length) { | COMMENT |
| LOW | lib/cast/cast_receiver.js | 981 | */ | COMMENT |
| LOW | lib/cast/cast_sender.js | 181 | if (!this.receiverAppId_.length) { | COMMENT |
| LOW | lib/codec/h264.js | 301 | if (spsFound && data.length > 4) { | COMMENT |
| LOW | lib/transmuxer/loc_transmuxer.js | 181 | const MimeUtils = shaka.util.MimeUtils; | COMMENT |
| LOW | lib/hls/hls_parser.js | 4401 | // set a presentation start time. We will assert later that this is | COMMENT |
| LOW | lib/hls/hls_parser.js | 5521 | } | COMMENT |
| LOW | lib/text/ui_text_displayer.js | 1821 | // Using 'break-spaces' would be better, as it would preserve even trailing | COMMENT |
| LOW | lib/text/ui_text_displayer.js | 2041 | // - The Start alignment means the text container’s top side (for horizontal | COMMENT |
| LOW | lib/text/ui_text_displayer.js | 2181 | // interpreted as a percentage of the video, as defined by the writing | COMMENT |
| LOW | lib/text/text_utils.js | 501 | // rejected by Edge. See https://bit.ly/2K9VX3s | COMMENT |
| LOW | lib/polyfill/mediasource.js | 41 | shaka.log.info('Patching Safari 8-12 MSE bugs.'); | COMMENT |
| LOW | lib/polyfill/video_play_promise.js | 21 | */ | COMMENT |
| LOW | lib/offline/indexeddb/storage_mechanism.js | 81 | const open = window.indexedDB.open(name, version); | COMMENT |
| LOW | lib/media/media_source_engine.js | 1501 | // per-segment recomputation below instead. | COMMENT |
| 4 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | karma.conf.js | 644 | function allUsableBrowserLaunchers(config) { | CODE |
| LOW | karma.conf.js | 717 | function WebDriverScreenshotMiddlewareFactory(launcher) { | CODE |
| LOW | demo/load.js | 8 | function shakaUncompiledModeSupported() { | CODE |
| LOW | externs/mediasession.js | 189 | function MediaSessionActionDetails() {} | CODE |
| LOW | test/player_unit.js | 6623 | function defaultStreamingFailureCallback(error) { | CODE |
| LOW | test/player_external.js | 271 | async function getManifestUriFromAdManager(asset) { | CODE |
| LOW | test/player_external.js | 316 | async function getManifestUriFromMediaTailorAdManager(asset) { | CODE |
| LOW | test/ads/interstitial_ad_unit.js | 64 | function leavePreviousAdMediaLoaded() { | CODE |
| LOW | test/drm/drm_engine_unit.js | 3263 | function createMockMediaKeySystemAccess() { | CODE |
| LOW | test/ui/ui_integration.js | 337 | async function verifyLanguageChangeViaUI(playerEventName, getTracks) { | CODE |
| LOW | test/ui/ui_integration.js | 353 | async function verifyLanguageChangeViaAPI( | CODE |
| LOW | test/ui/ui_integration.js | 724 | function updateResolutionButtonsAndMap() { | CODE |
| LOW | test/msf/msf_parser_unit.js | 1671 | async function givenALiveStreamWithTimeline() { | CODE |
| LOW | test/test/boot.js | 20 | function failTestsOnFailedAssertions() { | CODE |
| LOW | test/test/boot.js | 46 | function failTestsOnNamespacedElementOrAttributeNames() { | CODE |
| LOW | test/test/boot.js | 92 | function failTestsOnUnhandledErrors() { | CODE |
| LOW | test/test/boot.js | 165 | function workAroundLegacyEdgePromiseIssues() { | CODE |
| LOW | test/test/boot.js | 183 | function installPromiseWithResolversPolyfill() { | CODE |
| LOW | test/test/boot.js | 203 | function installStructuredClonePolyfill() { | CODE |
| LOW | test/test/boot.js | 404 | function configureJasmineEnvironment() { | CODE |
| LOW | test/test/boot.js | 598 | function checkWidevinePersistentSupport() { | CODE |
| LOW | test/test/boot.js | 668 | function isReadableStreamSupported() { | CODE |
| LOW | test/test/boot.js | 688 | function isWritableStreamSupported() { | CODE |
| LOW | test/test/closure-boot.js | 45 | function installRetryingScriptLoader() { | CODE |
| LOW | test/test/assets/screenshots/review.html | 350 | function appendScreenshotLineBreak() { | CODE |
| LOW | test/util/video_frame_callback_handler_unit.js | 61 | function createMockVideoWithoutRVFC() { | CODE |
| LOW | test/util/video_frame_callback_handler_unit.js | 71 | function fireLastRegisteredCallback(now = 100, metadata = null) { | CODE |
| LOW | test/cast/cast_receiver_integration.js | 334 | function waitForUpdateMessageWrapper(prototype, name, methodName) { | CODE |
| LOW | test/cast/cast_receiver_integration.js | 364 | async function averageUpdateMessageLength() { | CODE |
| LOW | test/cast/cast_receiver_integration.js | 412 | function createMockReceiverManager() { | CODE |
| LOW | test/cast/cast_receiver_unit.js | 1014 | function createMockReceiverManager() { | CODE |
| LOW | test/cast/cast_sender_unit.js | 923 | function fakeSessionConnectionFailure(code) { | CODE |
| LOW | test/abr/simple_abr_manager_integration.js | 199 | function createMultiBitrateManifest(duration) { | CODE |
| LOW | test/abr/simple_abr_manager_integration.js | 373 | async function setupDroppedFramesPlayback(disableStreamSpy) { | CODE |
| LOW | test/hls/hls_live_unit.js | 123 | function configureNetEngineForInitialManifest(master, media1, media2) { | CODE |
| LOW | test/dash/dash_parser_manifest_unit.js | 1651 | async function testAudioChannelConfiguration( | CODE |
| LOW | test/dash/dash_parser_manifest_unit.js | 3082 | function buildManifestWithPeriodStartTime(periods) { | CODE |
| LOW | test/dash/dash_parser_live_unit.js | 131 | function makeSimpleLiveManifestText(lines, updateTime, duration) { | CODE |
| LOW | test/text/native_text_displayer_unit.js | 470 | function FakeVTTCueWithoutAlignCenter(start, end, text) { | CODE |
| LOW | test/offline/storage_integration.js | 1550 | function makeManifestWithVideoInitSegments() { | CODE |
| LOW | test/offline/storage_integration.js | 1606 | function makeManifestWithPerStreamBandwidth() { | CODE |
| LOW | test/offline/storage_integration.js | 1652 | function makeManifestWithoutPerStreamBandwidth() { | CODE |
| LOW | test/offline/storage_integration.js | 1666 | function makeManifestWithNonZeroStart() { | CODE |
| LOW | test/offline/storage_integration.js | 1686 | function makeManifestWithLiveTimeline() { | CODE |
| LOW | test/offline/storage_integration.js | 1696 | function makeManifestWithAlternateSegments() { | CODE |
| LOW | test/media/closed_caption_parser_unit.js | 47 | function getCurrentContinuityTimeline(parser) { | CODE |
| LOW | test/media/streaming_engine_unit.js | 5053 | function slideSegmentAvailabilityWindow() { | CODE |
| LOW | test/media/streaming_engine_unit.js | 5099 | function failFirstRequestForTarget(netEngine, targetUri, errorCode) { | CODE |
| LOW | test/media/streaming_engine_unit.js | 5154 | function createAlternateSegmentIndex(baseStream, alternateStream) { | CODE |
| LOW | test/media/streaming_engine_integration.js | 198 | function createLiveStreamGenerator(metadata, type, timeShiftBufferDepth) { | CODE |
| LOW | test/media/media_source_engine_integration.js | 229 | function appendWithSeekAndClosedCaptions(type, segmentNumber) { | CODE |
| LOW | test/media/media_source_engine_integration.js | 242 | function appendInitWithClosedCaptions(type) { | CODE |
| LOW | test/media/media_source_engine_unit.js | 2102 | function simulatePlaybackBeginning() { | CODE |
| LOW | docs/upgrades/upgrade-v2.1-to-v2.4.md | 286 | function retryLiveOnFailureCallback(error) { | CODE |
| LOW | docs/upgrades/upgrade-v2.1-to-v2.4.md | 292 | function retryOnSpecificHttpErrorsCallback(error) { | CODE |
| LOW | docs/upgrades/upgrade-v1-to-v2.md | 103 | function interpretContentProtection(schemeIdUri, contentProtectionElement) { | CODE |
| LOW | docs/upgrades/upgrade-v1-to-v2.md | 156 | function interpretContentProtection(contentProtectionElement) { | CODE |
| LOW | docs/upgrades/upgrade-v1-to-v2.md | 193 | function interpretContentProtection(schemeIdUri, contentProtectionElement) { | CODE |
| LOW | docs/upgrades/upgrade-v1-to-v2.md | 310 | function interpretContentProtection(schemeIdUri, contentProtectionElement) { | CODE |
| LOW | docs/upgrades/upgrade-v2.0-to-v2.4.md | 493 | function retryLiveOnFailureCallback(error) { | CODE |
| 2 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | .github/workflows/release-please.yaml | 290 | # Create a simple README for the repo | COMMENT |
| MEDIUM | .github/workflows/release-please.yaml | 298 | # Create a clean commit for the new demo release. | COMMENT |
| MEDIUM | .github/workflows/report-incremental-coverage.yaml | 51 | # Create a new comment | COMMENT |
| MEDIUM | .github/workflows/update-screenshots.yaml | 155 | # Create a local branch. | COMMENT |
| MEDIUM | .github/workflows/update-screenshots.yaml | 183 | # Create a PR. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | ui/playback_rate_selection.js | 111 | // Slider row: [−] ──────slider────── [+] | COMMENT |
| MEDIUM | lib/codec/av1.js | 269 | // ── color_config() (AV1 §5.5.2) ────────────────────────────────────── | COMMENT |
| MEDIUM | lib/transmuxer/loc_transmuxer.js | 296 | // ── AnnexB mode (LOC §2.1.4) ─────────────────────────────────────── | COMMENT |
| MEDIUM | lib/transmuxer/loc_transmuxer.js | 317 | // ── Length-prefix mode (LOC §2.1.3, AVCC/HVCC) ──────────────────── | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | test/test/boot.js | 415 | // nuanced version. You can't set this to null, since jasmine still tries | COMMENT |
| MEDIUM | test/test/boot.js | 794 | // and on certain platforms. So this seems to be the more robust solution. | COMMENT |
| MEDIUM | lib/player.js | 9593 | // Get the safeMargin to ensure a seamless playback | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | lib/dash/mpd_utils.js | 607 | // Step 3: integrate the imported content into the Linked Period. | COMMENT |
| LOW⚡ | lib/dash/mpd_utils.js | 615 | // Step 2: fall back to a regular Period instead of failing the parse. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | lib/dash/mpd_utils.js | 607 | // Step 3: integrate the imported content into the Linked Period. | COMMENT |
| LOW⚡ | lib/dash/mpd_utils.js | 615 | // Step 2: fall back to a regular Period instead of failing the parse. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | test/test/assets/mkv/generate.py | 44 | CODE | |
| LOW | .github/workflows/compute-incremental-coverage.py | 207 | CODE | |
| LOW | .github/workflows/compute-incremental-coverage.py | 70 | CODE | |
| LOW | .github/workflows/compute-incremental-coverage.py | 171 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | .github/workflows/update-screenshots.yaml | 164 | # Check if a PR already exists. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | ui/locales/dashboard.html | 1335 | 'placeholder': st.status === 'missing' ? 'Missing translation' : null, | CODE |