Youtube_player_flutter: [BUG] استحقاق العميل المطلوب مفقود: MediaPlayback

تم إنشاؤها على ٣٠ يونيو ٢٠٢١  ·  4تعليقات  ·  مصدر: sarbagyastha/youtube_player_flutter

صف الخلل
عند كل فتح للاعب ، قمت بطباعة خطأ في وحدة التحكم مثل هذا:

2021-06-30 09:24:44.141532+0200 Media Creations[39379:12785401] [ProcessSuspension] 0x10c4dd0b0 - ProcessAssertion: Failed to acquire RBS MediaPlayback assertion 'WebKit Media Playback' for process with PID 39379, error: Error Domain=RBSAssertionErrorDomain Code=3 "Required client entitlement is missing" UserInfo={RBSAssertionAttribute=<RBSDomainAttribute| domain:"com.apple.webkit" name:"MediaPlayback" sourceEnvironment:"(null)">, NSLocalizedFailureReason=Required client entitlement is missing}

يبدو Mine YoutubePlayerController كما يلي:

final YoutubePlayerController _controller = YoutubePlayerController(
      initialVideoId: videoId,
      flags: YoutubePlayerFlags(
        enableCaption: false,
        hideThumbnail: true,
        forceHD: true,
        autoPlay: false,
        startAt: startAt,
      ),
    );

لإعادة إنتاج
افتح YoutubePlayerFlutter على IOS

سلوك متوقع
يفتح المشغل دون أي أخطاء

لقطات
إذا أمكن ، أضف لقطات شاشة للمساعدة في شرح مشكلتك.

تفاصيل تقنية:

  • الجهاز: ايفون 10
  • نظام التشغيل: iOS 14.6
  • الإصدار Flutter 2.2.2

سياق إضافي
هذا هو الكود الخاص بي على YoutubePlayer:

return OrientationBuilder(
      builder: (_, __) => YoutubePlayer(
        key: UniqueKey(),
        showVideoProgressIndicator: true,
        onReady: _controller.play,
        controller: _controller,
        controlsTimeOut: const Duration(seconds: 2),
        actionsPadding: const EdgeInsets.only(bottom: 10),
        progressIndicatorColor: _theme.primaryColor,
        onEnded: (_) => _controller.pause(),
        bottomActions: [
          Padding(
            padding: const EdgeInsets.only(
              left: VideoFullScreenButton.paddingSize +
                  VideoFullScreenButton.size * 2,
              right: VideoFullScreenButton.paddingSize,
            ),
            child: CurrentPosition(),
          ),
          ProgressBar(
            colors: ProgressBarColors(
              playedColor: _theme.primaryColor,
              handleColor: _theme.primaryColor,
            ),
            isExpanded: true,
          ),
          GestureDetector(
            onTap: () => launch(
              Strings.youtubeUrlFromId(
                videoId,
                seconds: _controller.value.position.inSeconds,
              ),
            ),
            child: const Padding(
              padding: EdgeInsets.only(
                left: VideoFullScreenButton.paddingSize,
                right: VideoFullScreenButton.paddingSize,
              ),
              child: FaIcon(
                FontAwesomeIcons.externalLinkAlt,
                color: Colors.white,
                size: VideoFullScreenButton.size,
              ),
            ),
          ),
          VideoFullScreenButton(
            preloadedFullScreen: isFullScreen,
            key: UniqueKey(),
            onTap: (isFullScreen) => _onVideoFullScreenTap(
              isFullScreen,
              context,
              _controller,
            ),
          ),
        ],
      ),
    );

شيء مفقود في مشروعي؟ في حالة وجود طلب سأرد على الفور.

bug

التعليق الأكثر فائدة

لدي نفس المشكلة

ال 4 كومينتر

لدي نفس المشكلة

هل يشير هذا التحذير إلى Info.plist؟

PcolBP هل وجدت أي حل؟

لسوء الحظ ليس لـ YoutubePlayerFlutter. بالنسبة لهذا المشروع ، قمت بالتبديل إلى YoutubePlayerIframe نظرًا لأنه يوفر أداءً أفضل مقارنةً بـ YoutubePlayerFlutter ولم يتم طباعة أي خطأ منذ ذلك الحين.

هل كانت هذه الصفحة مفيدة؟
0 / 5 - 0 التقييمات