Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error 1001, 1002 and 1003 #2915

Open
1 task done
DanielProg39 opened this issue Sep 7, 2023 · 130 comments
Open
1 task done

Error 1001, 1002 and 1003 #2915

DanielProg39 opened this issue Sep 7, 2023 · 130 comments
Labels
bug Something isn't working

Comments

@DanielProg39
Copy link

Official Instance

Describe the bug

I opened this video and got a message saying: "Failed with error code 1001, see logs for more info". Other videos play properly without any issues.

To Reproduce

  1. Open this video.
  2. Observe an error.

Expected behavior

Video should play like any other.

Logs/Errors

Found this in logs:

Error: Shaka Error
    at new x (https://piped.video/assets/shaka-player.ui-92211a3f.js:1:22884)
    at nm (https://piped.video/assets/shaka-player.ui-92211a3f.js:1:389839)
    at Vy.h (https://piped.video/assets/shaka-player.ui-92211a3f.js:1:391259)
    at Cr (https://piped.video/assets/shaka-player.ui-92211a3f.js:1:4167)
    at Hy.next (https://piped.video/assets/shaka-player.ui-92211a3f.js:1:4465)
    at t (https://piped.video/assets/shaka-player.ui-92211a3f.js:1:4694)

Can provide more logs if required

Browser, and OS with Version.

Brave 1.57.62 on Chromium 116.0.5845.180

Additional context

No response

@DanielProg39 DanielProg39 added the bug Something isn't working label Sep 7, 2023
@ReshmaM8
Copy link

(When I click on your video I get error 1002; there are other videos in my feed also encounter error 1002 as well. Yet some videos play fine. I joined few hours ago on Chrome 116.0.5845.180 with duckduckgo search engine

@DanielProg39
Copy link
Author

Now the video is playing fine for me, no errors. @ReshmaM8 let us know when there are no errors, until then I'll leave the issue open.

@DanielProg39 DanielProg39 changed the title Error 1001 Error 1001 and 1002 Sep 11, 2023
@ReshmaM8
Copy link

I have inconsistent response when I try to play this video: Link
I played first on my main chrome profile and it works but when I opened a guest profile , go to piped.video -> search this video and hit play I get error code 1002.
image
I have two .har network logs - one when the video did load and one with the error code; should I attach them(sensitive info redacted using google HAR analyzer) here or do I send it to specifically to an email ?

@FireMasterK
Copy link
Member

You can send it to [email protected], I'll have a look!

@oneover0
Copy link

are you facing this issue still? i am getting this same error in every video .

@ReshmaM8
Copy link

yeah, I'm having the same issue. The network traffic shows the video playback in a cycle of cancelled -> 500 --> one 200 request --> pending.

@DanielProg39
Copy link
Author

Now the video is playing fine for me, no errors.

Not anymore. Now I get misterious Error 1002 for the video I reported in the first place.

Here's new error log in stack:

Error: Shaka Error
    at new x (https://piped.video/assets/shaka-player.ui-92211a3f.js:1:22884)
    at Vy.h (https://piped.video/assets/shaka-player.ui-92211a3f.js:1:391198)
    at Cr (https://piped.video/assets/shaka-player.ui-92211a3f.js:1:4167)
    at Hy.throw (https://piped.video/assets/shaka-player.ui-92211a3f.js:1:4560)
    at n (https://piped.video/assets/shaka-player.ui-92211a3f.js:1:4730)

@EHP4321
Copy link

EHP4321 commented Sep 15, 2023

Having the same problem. Getting 1002 error. Sometimes just changing instance works. But once a video fails on a specific instance it keeps failing on that instance, but switching to another video generally works. So maybe there is a cache issue.
Edit: Actually It seems switching instance always works.
Edit 2: Nope looks like I was just lucky a few times

@opusforlife2
Copy link
Contributor

Apart from Error 1002, I've also seen 1003 several times.

@DanielProg39 DanielProg39 changed the title Error 1001 and 1002 Error 1001, 1002 and 1003 Sep 21, 2023
@DanielProg39
Copy link
Author

Now the video is playing fine for me, no errors.

Again. Got no errors

@saenglert
Copy link

The bug appears to be cause by missing cors headers in the http response: #2970 (comment)

@DanielProg39
Copy link
Author

The bug appears to be cause by missing cors headers in the http response: #2970 (comment)

I've noticed CORS errors many times in the past in plenty videos, though they led to video starting playing later than usual or load for a long time, they haven't let to any errors displayed.

@DanielProg39
Copy link
Author

Again. Got no errors

Checked the video out once more. Error 1002.

"Error: Shaka Error 1002
    at new x (https://piped.video/assets/shaka-player.ui-7171c67c.js:1:22922)
    at Hy.h (https://piped.video/assets/shaka-player.ui-7171c67c.js:1:391789)
    at Mr (https://piped.video/assets/shaka-player.ui-7171c67c.js:1:4167)
    at qy.throw (https://piped.video/assets/shaka-player.ui-7171c67c.js:1:4560)
    at n (https://piped.video/assets/shaka-player.ui-7171c67c.js:1:4730)"

@saenglert
Copy link

The bug appears to be cause by missing cors headers in the http response: #2970 (comment)

I've noticed CORS errors many times in the past in plenty videos, though they led to video starting playing later than usual or load for a long time, they haven't let to any errors displayed.

grafik

Well, if you look at the error object, you can see it is caused by the network error. And the network error is caused by the connection not completing because of the missing cors header.

@opusforlife2
Copy link
Contributor

I got a 1002 on the Syncpundit instance as well, but only once, and a reload fixed it immediately.

@saenglert
Copy link

kavin.rocks now returns the proper headers and I no longer receive the error.

image

@DanielProg39
Copy link
Author

Everything seems to be back to normal. I'm not getting any errors and no CORS errors, although the video was loading endlessly. After reloading the page several times and setting the playback indicator to the beginning of the video, the video started playing and played to the end without any problems. I suspect this was something to do with the cache.

Overall, the issue seems to have been resolved. I'm going to keep it open for a while in case anyone else is still experiencing these errors. So if you got them in any videos, check them now and report if any of them still seem to be broken.

@ghost
Copy link

ghost commented Sep 27, 2023

@DanielProg39 can you check this https://piped.video/watch?v=oRdxUFDoQe0 ?
For me, its giving 1001 error

@DanielProg39
Copy link
Author

@DanielProg39 can you check this https://piped.video/watch?v=oRdxUFDoQe0 ? For me, its giving 1001 error

Strangely, I got no errors or problems. The whole video played perfectly

@ReshmaM8
Copy link

@DanielProg39 can you check this https://piped.video/watch?v=oRdxUFDoQe0 ? For me, its giving 1001 error

I checked as well, no issues (chrome, win 10)
other videos are playing for me as well - just at the beginning it takes a while to load cause the video playback fails a couple of times before succeeding

@ghost
Copy link

ghost commented Sep 28, 2023

@DanielProg39 @ReshmaM8
Actually the problem was from ISP😅. When i switched isp to telecom one, it works fine.
Thanks

@opusforlife2
Copy link
Contributor

Still had some 1002's yesterday. Had to switch back and forth between instances to be able to watch the intended videos.

@ghost
Copy link

ghost commented Oct 3, 2023

1002 here. happens all the time on almost all instances.

@Bnyro Bnyro pinned this issue Apr 5, 2024
@amirianos
Copy link

Now I have the same issue here

@jiaen-p
Copy link

jiaen-p commented May 13, 2024

I use the libretube app with a self hosted piped instance, and i've noticed that dash is disabled, so I've dived into the code and this is what I have found in regards to dash/hls

From what I can see is that newpipe extractor defaults to hls except for livestream, they set the properties here.

public static final class Builder {
        private String id;
        private String content;
        private boolean isUrl;
        private DeliveryMethod deliveryMethod = DeliveryMethod.PROGRESSIVE_HTTP;
        @Nullable
        private MediaFormat mediaFormat;
        @Nullable
        private String manifestUrl;
        // Use of the Boolean class instead of the primitive type needed for setter call check
        private Boolean isVideoOnly;
        private String resolution;
        @Nullable
        private ItagItem itagItem;

        /**
         * Create a new {@link Builder} instance with its default values.
         */
        public Builder() {
        }

There's a method in which you can set the delivery method in the same class

 /**
         * Set the {@link DeliveryMethod} of the {@link VideoStream}.
         *
         * <p>
         * It must not be null.
         * </p>
         *
         * <p>
         * The default delivery method is {@link DeliveryMethod#PROGRESSIVE_HTTP}.
         * </p>
         *
         * @param deliveryMethod the {@link DeliveryMethod} of the {@link VideoStream}, which must
         *                       not be null
         * @return this {@link Builder} instance
         */
        public Builder setDeliveryMethod(@Nonnull final DeliveryMethod deliveryMethod) {
            this.deliveryMethod = deliveryMethod;
            return this;
        }

From what I can gather, the piped backend requests the stream info from here you can call on that method to set the stream type

                if (!livestream) {
            info.getVideoOnlyStreams().forEach(stream -> videoStreams.add(new PipedStream(stream.getItag(), rewriteVideoURL(stream.getContent(), extraParams),
                    String.valueOf(stream.getFormat()), stream.getResolution(), stream.getFormat().getMimeType(), true,
                    stream.getBitrate(), stream.getInitStart(), stream.getInitEnd(), stream.getIndexStart(),
                    stream.getIndexEnd(), stream.getCodec(), stream.getWidth(), stream.getHeight(), stream.getFps(), stream.getItagItem().getContentLength())));
            info.getVideoStreams()
                    .forEach(stream -> videoStreams
                            .add(new PipedStream(stream.getItag(), rewriteVideoURL(stream.getContent(), Map.of()), String.valueOf(stream.getFormat()),
                                    stream.getResolution(), stream.getFormat().getMimeType(), false, stream.getItagItem().getContentLength())));

            info.getAudioStreams()
                    .forEach(stream -> audioStreams.add(new PipedStream(stream.getItag(), rewriteVideoURL(stream.getContent(), extraParams),
                            String.valueOf(stream.getFormat()), stream.getAverageBitrate() + " kbps",
                            stream.getFormat().getMimeType(), false, stream.getBitrate(), stream.getInitStart(),
                            stream.getInitEnd(), stream.getIndexStart(), stream.getIndexEnd(), stream.getItagItem().getContentLength(), stream.getCodec(), stream.getAudioTrackId(),
                            stream.getAudioTrackName(), Optional.ofNullable(stream.getAudioTrackType()).map(Enum::name).orElse(null),
                            Optional.ofNullable(stream.getAudioLocale()).map(Locale::toLanguageTag).orElse(null)
                    )));
        }
        final Map<String, String> extraParams = Map.of(
//                "ump", "1",
//                "srfvp", "1"
        );

I think the bug is somewhere in the newpipe deliveryMethod, the stream builder expects a single value in the delivery method and piped is passing 2.

However, I'm not an familiar with Java, and I hope I could contribute to the project.
Cheers.

@samip5
Copy link

samip5 commented May 19, 2024

Now I have the same issue here

In my experience, the error (1001 as an example) seems to happen on just some channels, possibly related to the type of video being used there.

@manuelkamp
Copy link

1001 on every second video I try to watch on my own instance. Had this now for a few days. Noticeable only the newer ones does have this issue. If I try to watch a video today which did not work yesterday, it works (4 out of 4 success).

@DeltaTangoLima
Copy link

Error 1001 just started happening for me in the past few days. Initially was only a few videos, now I'm struggling to play any video at all.

Starting to think this could be related to the big G's crackdown on ad blocking, maybe the recent change to try injecting server-side ads to defeat Sponsorblock.

@opusforlife2
Copy link
Contributor

Unlikely. These are all Shaka player errors, and the YT crackdown is a straight up Newpipe Extractor exception.

@DeltaTangoLima
Copy link

DeltaTangoLima commented Jun 15, 2024

Unlikely. These are all Shaka player errors, and the YT crackdown is a straight up Newpipe Extractor exception.

Yeah, fair enough. I haven't (yet) educated myself on how Piped works, so wasn't sure. Just seemed highly coincidental at face value.

Edit: just realised I can play videos from my instance using a different client, on my phone. So definitely not a problem extracting the videos from YT.

@leberschnitzel
Copy link

leberschnitzel commented Jul 9, 2024

Since today all videos bring me an 1001 error when using my own instance.

Edit: rebuilt the stack and now it works again

@Dominion0815
Copy link

I have also been getting 1001 errors since yesterday.
I have already tried to reset everything via Docker AIO Script, but then I also get error 1001.

In the developer console of the browser I see 403 errors at pipedproxy.xxx.de

In LibreTube with HLS the instance still works!

What exactly did you do @leberschnitzel ?
Does anyone else have the problem, is there a solution @FireMasterK ?

@leberschnitzel
Copy link

I have also been getting 1001 errors since yesterday. I have already tried to reset everything via Docker AIO Script, but then I also get error 1001.

In the developer console of the browser I see 403 errors at pipedproxy.xxx.de

In LibreTube with HLS the instance still works!

What exactly did you do @leberschnitzel ? Does anyone else have the problem, is there a solution @FireMasterK ?

I've just stopped the stack and rebuild it with a forced pull of the images.

@Dominion0815
Copy link

I have also been getting 1001 errors since yesterday. I have already tried to reset everything via Docker AIO Script, but then I also get error 1001.
In the developer console of the browser I see 403 errors at pipedproxy.xxx.de
In LibreTube with HLS the instance still works!
What exactly did you do @leberschnitzel ? Does anyone else have the problem, is there a solution @FireMasterK ?

I've just stopped the stack and rebuild it with a forced pull of the images.

then you were lucky. It seems to affect almost all instances.

@kibirisu
Copy link

also having that issue. on libretube everything works just fine but trying to watch anything on the web app results in 1001 error on my instance.

@athiosh
Copy link

athiosh commented Jul 10, 2024

same here, it was working yesterday but today i am getting 1001 for all videos in my instance

@leberschnitzel
Copy link

I have also been getting 1001 errors since yesterday. I have already tried to reset everything via Docker AIO Script, but then I also get error 1001.
In the developer console of the browser I see 403 errors at pipedproxy.xxx.de
In LibreTube with HLS the instance still works!
What exactly did you do @leberschnitzel ? Does anyone else have the problem, is there a solution @FireMasterK ?

I've just stopped the stack and rebuild it with a forced pull of the images.

then you were lucky. It seems to affect almost all instances.

My luck didn't last long, same problems again today

@Lukilei
Copy link

Lukilei commented Jul 10, 2024

Also had code 1001 earlier today on public instances, piped.video works again now.

@manuelkamp
Copy link

it worked until about an hour ago. I even went to delete everything and reinstalled and reconfigured from scratch (since my pgsql is dedicated and not part of the docker stack), getting now 1001s or even not loaded the entire video frame (this one only on LG smart tv) on every single video I tried.

@JohnFawkes
Copy link

JohnFawkes commented Jul 10, 2024

Also getting error 1001 on every video on my private instance on web. HAs anyone figured out whats causing it and what the fix is?

@Lwfrancisco
Copy link

+1 on this issue, getting error 1001 on all videos. I am on a new self-hosted instance where I am the only user and have rebuilt the instance just to be safe. I cannot play video via web but can play videos via libretube.

@AlyoshaVasilieva
Copy link
Contributor

My private instance (Hetzner with IPv6 rotation) seems to still be working.

@leberschnitzel
Copy link

Now mine also seems to work again without me doing anything...

@gmemstr
Copy link

gmemstr commented Jul 11, 2024

With TeamPiped/Piped-Backend#818, this should be working. Make sure to pull the latest Docker images. Tested it on my own instance.

@leberschnitzel
Copy link

Yep, forgot about my watchtower 😊

@Egorundel
Copy link

Hello, I have the 1002 error. How to fix it?

@ghost
Copy link

ghost commented Aug 8, 2024

Hello, I have the 1002 error. How to fix it?

If the solution is known, the issue will be closed

@Egorundel
Copy link

Egorundel commented Aug 9, 2024

If the solution is known, the issue will be closed

@Pamilg9 There is no solution yet

@3052
Copy link

3052 commented Sep 29, 2024

FYI all the people saying to just remove &ump=1, it seem the ump key was just a YouTube experiment, and from testing today that key is not passed anymore, and even if you provide ump=0 you still get a UMP response

@maximushugus
Copy link

since a few days, I have an error 1001 on every video on my self hosted private instance. am I the only one ?

@Scorpoon
Copy link

since a few days, I have an error 1001 on every video on my self hosted private instance. am I the only one ?

Works without a problem on my side. Did you check if you have the latest version installed?

@maximushugus
Copy link

Yes, I did a docker pull, but without resolving the problem. To note I'm using cloudflare warp on the VPS I run my instance because it my IP was blocked a few months ago

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests