fix: disable Android client
This commit is contained in:
parent
706e88134c
commit
a846b729e3
3 changed files with 3 additions and 4 deletions
|
|
@ -321,8 +321,7 @@ static VISITOR_DATA_REGEX: Lazy<Regex> =
|
|||
///
|
||||
/// The order may change in the future in case YouTube applies changes to their
|
||||
/// platform that disable a client or make it less reliable.
|
||||
pub const DEFAULT_PLAYER_CLIENT_ORDER: &[ClientType] =
|
||||
&[ClientType::Tv, ClientType::Android, ClientType::Ios];
|
||||
pub const DEFAULT_PLAYER_CLIENT_ORDER: &[ClientType] = &[ClientType::Tv, ClientType::Ios];
|
||||
|
||||
/// The RustyPipe client used to access YouTube's API
|
||||
///
|
||||
|
|
|
|||
|
|
@ -198,7 +198,7 @@ impl MapResponse<VideoPlayer> for response::Player {
|
|||
"Premium" => Some(UnavailabilityReason::Premium),
|
||||
"members-only" => Some(UnavailabilityReason::MembersOnly),
|
||||
"country" => Some(UnavailabilityReason::Geoblocked),
|
||||
"Android" | "websites" => Some(UnavailabilityReason::UnsupportedClient),
|
||||
"version" | "websites" => Some(UnavailabilityReason::UnsupportedClient),
|
||||
"bot" => Some(UnavailabilityReason::IpBan),
|
||||
_ => None,
|
||||
})
|
||||
|
|
|
|||
|
|
@ -30,7 +30,7 @@ use rustypipe::validate;
|
|||
#[case::desktop(ClientType::Desktop)]
|
||||
#[case::tv(ClientType::Tv)]
|
||||
#[case::mobile(ClientType::Mobile)]
|
||||
#[case::android(ClientType::Android)]
|
||||
// #[case::android(ClientType::Android)]
|
||||
#[case::ios(ClientType::Ios)]
|
||||
#[tokio::test]
|
||||
async fn get_player_from_client(#[case] client_type: ClientType, rp: RustyPipe) {
|
||||
|
|
|
|||
Reference in a new issue