Bug 222108 - [GStreamer] Error instead of asserting on the player in the source
Summary: [GStreamer] Error instead of asserting on the player in the source
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Xabier Rodríguez Calvar
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2021-02-18 08:38 PST by Xabier Rodríguez Calvar
Modified: 2021-03-23 10:13 PDT (History)
8 users (show)

See Also:


Attachments
Patch (1.82 KB, patch)
2021-02-18 08:40 PST, Xabier Rodríguez Calvar
no flags Details | Formatted Diff | Diff
Patch (1.91 KB, patch)
2021-03-02 07:33 PST, Xabier Rodríguez Calvar
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Xabier Rodríguez Calvar 2021-02-18 08:38:10 PST
[GStreamer] Error instead of asserting on the player in the source
Comment 1 Xabier Rodríguez Calvar 2021-02-18 08:40:01 PST
Created attachment 420833 [details]
Patch
Comment 2 Philippe Normand 2021-02-18 08:55:03 PST
Comment on attachment 420833 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=420833&action=review

> Source/WebCore/ChangeLog:10
> +        The release assert can be hit in some cases in smoothstreaming
> +        with already invalid pipelines so better to just error out instead
> +        of assert on release.

I don't disagree about this patch, but I would like to know more about these invalid pipelines :)
Comment 3 Alicia Boya García 2021-02-18 09:06:16 PST
Do you have a test vector that reproduces the failed assertion?
Comment 4 Xabier Rodríguez Calvar 2021-02-18 22:53:36 PST
It's a DRM test that plays, ends, loops, the DRM systems fails and then sometimes you get the error.
Comment 5 Alicia Boya García 2021-02-19 06:02:18 PST
Comment on attachment 420833 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=420833&action=review

> Source/WebCore/platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:484
> +        GST_ERROR_OBJECT(src, "player should not be null");

I would word it better: "Couldn't obtain WebKitWebSrcPlayerContext, which is necessary to make network requests."

> Source/WebCore/platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:485
> +        ASSERT_NOT_REACHED();

I would not assert here. While reaching this case is undesirable, we're already handling the error by returning GST_FLOW_ERROR. The cause of not being able to get a player is most likely a preceding error, so crashing here doesn't help gather valuable information. Also I don't think Release and Debug should get different treatment in this case.
Comment 6 Alicia Boya García 2021-02-19 06:03:03 PST
Informal r+ with these changes
Comment 7 Xabier Rodríguez Calvar 2021-03-02 07:33:48 PST
Created attachment 421933 [details]
Patch
Comment 8 EWS 2021-03-02 08:31:58 PST
Committed r273731: <https://commits.webkit.org/r273731>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 421933 [details].
Comment 9 Radar WebKit Bug Importer 2021-03-02 08:32:15 PST
<rdar://problem/74930203>