Skip to content

[Bug] failed to get channel #3717

Closed
NixOS/nixpkgs
#224250
@slayernominee

Description

@slayernominee

EDIT by @unixfox: This bug affects all the invidious instances, please don't add a comment if you just want to say that you can also reproduce the same issue, thank you! Just react with a 👍


Could not extract JSON. Youtube API returned error 500 with message:
"ExecuteQuery for ChannelMiddlewareService-GetShelves failed: RET_CHECK failure (video/youtube/channels/frontend/shared/continuations/channel_middleware_token_encoding.cc:15) absl::WebSafeBase64Unescape(web_safe_token, &unescaped_token) ; OneMustSucceed: input 'mw_shelf_source_exp_continuation_unwrapper'; OneMustSucceed: input 'mw_shelf_source_exp_subgraphs'; OneMustSucceed: input 'mw_shelf_source_exp_empty_shelf_filter'; OneMustSucceed: input 'ShelfSourceExpansion__graph'; OneMustSucceed: input 'get_shelves_shelf_candidate_rank_sorter'; OneMustSucceed: input 'wrapped_main_subgraph'; OneMustSucceed: input 'pre_decoration_subgraph'; OneMustSucceed: input 'decoration_annotator_subgraph'; OneMustSucceed: input 'post_decoration_subgraph'; PropagateAllErrors: input 'GetShelvesEndpoint__graph'; PropagateAllErrors: input 'default_filter_survivor_probe_op'; PropagateAllErrors: input 'policy_enforcement_candidate_predicate'; /ChannelMiddlewareService.GetShelves RPC failed"

Activity

shnappi-kk

shnappi-kk commented on Mar 31, 2023

@shnappi-kk

Yep. The error appears when you enter the channel.
/channel/UCQHX6ViZmPsWiYSFAyS0a3Q for example.
In some cases, refreshing the page gives the expected result, but then refreshing the page again gives this error.
Sections "streams", "community", "playlists", individual playlists and individual videos do not cause this error.

Perhaps, subscriptions are not updated for the same reason.
I see this error on yewtu.be invidious.snoopyta and on my own instance.

SethPyle376

SethPyle376 commented on Mar 31, 2023

@SethPyle376
pinned this issue on Mar 31, 2023
davidhfrankelcodes

davidhfrankelcodes commented on Mar 31, 2023

@davidhfrankelcodes
knivey

knivey commented on Mar 31, 2023

@knivey

I'm also getting it, from log file after clicking to view a channel:

2023-03-31 15:42:20 UTC [error] YoutubeAPI: Got error 500 when requesting /youtubei/v1/browse                                                                                                                    
2023-03-31 15:42:20 UTC [error] YoutubeAPI: ExecuteQuery for ChannelMiddlewareService-GetShelves failed: RET_CHECK failure (video/youtube/channels/frontend/shared/continuations/channel_middleware_token_encodin
g.cc:15) absl::WebSafeBase64Unescape(web_safe_token, &unescaped_token) ; OneMustSucceed: input 'mw_shelf_source_exp_continuation_unwrapper'; OneMustSucceed: input 'mw_shelf_source_exp_subgraphs'; OneMustSuccee
d: input 'mw_shelf_source_exp_empty_shelf_filter'; OneMustSucceed: input 'ShelfSourceExpansion__graph'; OneMustSucceed: input 'get_shelves_shelf_candidate_rank_sorter'; OneMustSucceed: input 'wrapped_main_subg
raph'; OneMustSucceed: input 'pre_decoration_subgraph'; OneMustSucceed: input 'decoration_annotator_subgraph'; OneMustSucceed: input 'post_decoration_subgraph'; PropagateAllErrors: input 'GetShelvesEndpoint__g
raph'; PropagateAllErrors: input 'default_filter_survivor_probe_op'; PropagateAllErrors: input 'policy_enforcement_candidate_predicate'; /ChannelMiddlewareService.GetShelves RPC failed                         
2023-03-31 15:42:20 UTC [info] YoutubeAPI: POST data was: {"context" => {"client" => {"hl" => "en", "gl" => "US", "clientName" => "WEB", "clientVersion" => "2.20221118.01.00", "clientScreen" => "WATCH_FULL_SCR
EEN", "osName" => "Windows", "osVersion" => "10.0", "platform" => "DESKTOP"}}, "continuation" => "4qmFsgKzARIYVUN3bjJtSnpSbzU4Skx2U3ZuQWtYQ0dBGmg4Z1pHR2tSNlFnby1DaFpGWjBsSlFVTm5lVTFCUlRSSWEyZENWVUZCSlRORUVpUXd
NREF3TURBd01DMHdNREF3TFRBd01EQXRNREF3TUMwd01EQXdNREF3TURBd01EQVlBUSUzRCUzRJoCLGJyb3dzZS1mZWVkVUN3bjJtSnpSbzU4Skx2U3ZuQWtYQ0dBdmlkZW9zMTAy"}                                                                      
2023-03-31 15:42:20 UTC [error] RefreshChannelsJob: UCwn2mJzRo58JLvSvnAkXCGA : Could not extract JSON. Youtube API returned error 500 with message:<br>"ExecuteQuery for ChannelMiddlewareService-GetShelves fail
ed: RET_CHECK failure (video/youtube/channels/frontend/shared/continuations/channel_middleware_token_encoding.cc:15) absl::WebSafeBase64Unescape(web_safe_token, &unescaped_token) ; OneMustSucceed: input 'mw_sh
elf_source_exp_continuation_unwrapper'; OneMustSucceed: input 'mw_shelf_source_exp_subgraphs'; OneMustSucceed: input 'mw_shelf_source_exp_empty_shelf_filter'; OneMustSucceed: input 'ShelfSourceExpansion__graph'; OneMustSucceed: input 'get_shelves_shelf_candidate_rank_sorter'; OneMustSucceed: input 'wrapped_main_subgraph'; OneMustSucceed: input 'pre_decoration_subgraph'; OneMustSucceed: input 'decoration_annotator_subgraph'; OneMustSucceed: input 'post_decoration_subgraph'; PropagateAllErrors: input 'GetShelvesEndpoint__graph'; PropagateAllErrors: input 'default_filter_survivor_probe_op'; PropagateAllErrors: input 'policy_enforcement_candidate_predicate'; /ChannelMiddlewareService.GetShelves RPC failed"
2023-03-31 15:42:20 UTC [error] RefreshChannelsJob: UCwn2mJzRo58JLvSvnAkXCGA fiber : backing off for 02:08:00s
2023-03-31 15:42:24 UTC [error] YoutubeAPI: Got error 500 when requesting /youtubei/v1/browse
2023-03-31 15:42:24 UTC [error] YoutubeAPI: ExecuteQuery for ChannelMiddlewareService-GetShelves failed: RET_CHECK failure (video/youtube/channels/frontend/shared/continuations/channel_middleware_token_encodin
g.cc:15) absl::WebSafeBase64Unescape(web_safe_token, &unescaped_token) ; OneMustSucceed: input 'mw_shelf_source_exp_continuation_unwrapper'; OneMustSucceed: input 'mw_shelf_source_exp_subgraphs'; OneMustSuccee
d: input 'mw_shelf_source_exp_empty_shelf_filter'; OneMustSucceed: input 'ShelfSourceExpansion__graph'; OneMustSucceed: input 'get_shelves_shelf_candidate_rank_sorter'; OneMustSucceed: input 'wrapped_main_subgraph'; OneMustSucceed: input 'pre_decoration_subgraph'; OneMustSucceed: input 'decoration_annotator_subgraph'; OneMustSucceed: input 'post_decoration_subgraph'; PropagateAllErrors: input 'GetShelvesEndpoint__graph'; PropagateAllErrors: input 'default_filter_survivor_probe_op'; PropagateAllErrors: input 'policy_enforcement_candidate_predicate'; /ChannelMiddlewareService.GetShelves RPC failed
2023-03-31 15:42:24 UTC [info] YoutubeAPI: POST data was: {"context" => {"client" => {"hl" => "en", "gl" => "US", "clientName" => "WEB", "clientVersion" => "2.20221118.01.00", "clientScreen" => "WATCH_FULL_SCR
EEN", "osName" => "Windows", "osVersion" => "10.0", "platform" => "DESKTOP"}}, "continuation" => "4qmFsgKzARIYVUNsckctbU1zdWNXeE9JYWNGYXpNb0hnGmg4Z1pHR2tSNlFnby1DaFpGWjBsSlFVTm5lVTFCUlRSSWEyZENWVUZCSlRORUVpUXdNREF3TURBd01DMHdNREF3TFRBd01EQXRNREF3TUMwd01EQXdNREF3TURBd01EQVlBUSUzRCUzRJoCLGJyb3dzZS1mZWVkVUNsckctbU1zdWNXeE9JYWNGYXpNb0hndmlkZW9zMTAy"}
Exception: Could not extract JSON. Youtube API returned error 500 with message:<br>"ExecuteQuery for ChannelMiddlewareService-GetShelves failed: RET_CHECK failure (video/youtube/channels/frontend/shared/continuations/channel_middleware_token_encoding.cc:15) absl::WebSafeBase64Unescape(web_safe_token, &unescaped_token) ; OneMustSucceed: input 'mw_shelf_source_exp_continuation_unwrapper'; OneMustSucceed: input 'mw_shelf_source_exp_subgraphs'; OneMustSucceed: input 'mw_shelf_source_exp_empty_shelf_filter'; OneMustSucceed: input 'ShelfSourceExpansion__graph'; OneMustSucceed: input 'get_shelves_shelf_candidate_rank_sorter'; OneMustSucceed: input 'wrapped_main_subgraph'; OneMustSucceed: input 'pre_decoration_subgraph'; OneMustSucceed: input 'decoration_annotator_subgraph'; OneMustSucceed: input 'post_decoration_subgraph'; PropagateAllErrors: input 'GetShelvesEndpoint__graph'; PropagateAllErrors: input 'default_filter_survivor_probe_op'; PropagateAllErrors: input 'policy_enforcement_candidate_predicate'; /ChannelMiddlewareService.GetShelves RPC failed" (InfoException)
  from src/invidious/yt_backend/youtube_api.cr:623:7 in '_post_json'
  from src/invidious/channels/videos.cr:104:12 in 'videos'
  from lib/kemal/src/kemal/route.cr:13:9 in '->'
  from src/invidious/helpers/handlers.cr:30:37 in 'call'
  from /usr/share/crystal/src/http/server/handler.cr:28:7 in 'call'
  from /usr/share/crystal/src/http/server/handler.cr:28:7 in 'call_next'
  from lib/kemal/src/kemal/filter_handler.cr:21:7 in 'call'
  from /usr/share/crystal/src/http/server/handler.cr:28:7 in 'call'
  from /usr/share/crystal/src/http/server/handler.cr:28:7 in 'call_next'
  from src/invidious/helpers/handlers.cr:94:12 in 'call'
  from /usr/share/crystal/src/http/server/handler.cr:28:7 in 'call_next'
  from src/invidious/helpers/handlers.cr:151:29 in 'call'
  from /usr/share/crystal/src/http/server/handler.cr:28:7 in 'call'
  from /usr/share/crystal/src/http/server/handler.cr:28:7 in 'call_next'
  from src/ext/kemal_static_file_handler.cr:106:36 in 'call'
  from /usr/share/crystal/src/http/server/handler.cr:28:7 in 'call'
  from /usr/share/crystal/src/http/server/handler.cr:28:7 in 'call'
  from /usr/share/crystal/src/http/server/handler.cr:28:7 in 'call'
  from /usr/share/crystal/src/http/server/request_processor.cr:51:11 in 'process'
  from /usr/share/crystal/src/http/server.cr:500:5 in '->'
  from /usr/share/crystal/src/fiber.cr:146:11 in 'run'
  from ???

2023-03-31 15:42:24 UTC [warn] i18n: Missing translation key "Could not extract JSON. Youtube API returned error 500 with message:<br>"ExecuteQuery for ChannelMiddlewareService-GetShelves failed: RET_CHECK failure (video/youtube/channels/frontend/shared/continuations/channel_middleware_token_encoding.cc:15) absl::WebSafeBase64Unescape(web_safe_token, &unescaped_token) ; OneMustSucceed: input 'mw_shelf_source_exp_continuation_unwrapper'; OneMustSucceed: input 'mw_shelf_source_exp_subgraphs'; OneMustSucceed: input 'mw_shelf_source_exp_empty_shelf_filter'; OneMustSucceed: input 'ShelfSourceExpansion__graph'; OneMustSucceed: input 'get_shelves_shelf_candidate_rank_sorter'; OneMustSucceed: input 'wrapped_main_subgraph'; OneMustSucceed: input 'pre_decoration_subgraph'; OneMustSucceed: input 'decoration_annotator_subgraph'; OneMustSucceed: input 'post_decoration_subgraph'; PropagateAllErrors: input 'GetShelvesEndpoint__graph'; PropagateAllErrors: input 'default_filter_survivor_probe_op'; PropagateAllErrors: input 'policy_enforcement_candidate_predicate'; /ChannelMiddlewareService.GetShelves RPC failed""
2023-03-31 15:42:24 UTC [info] 500 GET /channel/UClrG-mMsucWxOIacFazMoHg 144.88ms
99thim

99thim commented on Mar 31, 2023

@99thim
Abyssgrowth

Abyssgrowth commented on Mar 31, 2023

@Abyssgrowth

Was there an internal youtube update that caused this?

unixfox

unixfox commented on Mar 31, 2023

@unixfox
Member

Was there an internal youtube update that caused this?

Yes that's correct. If you want, you can discuss it further on matrix or IRC.

alithechemist

alithechemist commented on Mar 31, 2023

@alithechemist

Yep. The error appears when you enter the channel. /channel/UCQHX6ViZmPsWiYSFAyS0a3Q for example. In some cases, refreshing the page gives the expected result, but then refreshing the page again gives this error. Sections "streams", "community", "playlists", individual playlists and individual videos do not cause this error.

That is because a change is being deployed to a large cluster

garoto

garoto commented on Mar 31, 2023

@garoto

It seems it's related to how channels are now using the new @name handle/moniker format by default.

unixfox

unixfox commented on Apr 3, 2023

@unixfox
Member

New commit fixed the issue: #3718
Please update your invidious instance.

added a commit that references this issue on Apr 5, 2023
unpinned this issue on Apr 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Participants

      @unixfox@knivey@garoto@SethPyle376@slayernominee

      Issue actions

        [Bug] failed to get channel · Issue #3717 · iv-org/invidious