I"m obtaining this error ~ destroying and recreating the task three times:

"There was a problem while play (Playback ID: ....) Tap to retry" The complying with are the details and also steps come reproduce the issue:

My app for Android (Match4app) is a card video game which mirrors images and also videos in every card.These videos are presented using YouTubePlayerSupportFragment.In a deck that cards, each map is a fragment. Everytime a card is shown, the fragment"s map creates a new instance the YouTubePlayerSupportFragment with its particular youTubePlayerFragment.initialize method:

youTubePlayerFragment.initialize( Constants.DEVELOPER_KEY,new YouTubePlayer.OnInitializedListener()


You are watching: There was a problem while playing tap to retry

Override public void onInitializationSuccess(YouTubePlayer.Provider provider, YouTubePlayer player, boolean wasRestored) if (!wasRestored) YPlayer = player; YouTubePlayer.PlayerStyle style = YouTubePlayer.PlayerStyle.MINIMAL; YPlayer.setPlayerStyle(style); YPlayer.setFullscreen(false); YPlayer.loadVideo(videoIDStatic);
Override public void onInitializationFailure(YouTubePlayer.Provider arg0, YouTubeInitializationResult arg1) );Users deserve to jump native one map (fragment) to an additional card (fragment) in the very same deck (Activity), and videos play well all the time. Users can watch as much as 30 cards (with its respective videos). Everytime there is a jump from one card to another card, the Youtubleplayer is released and collection to null with this method:

public void stopVideo() if (YPlayer != null) YPlayer.release(); YPlayer = null; if (!isAdded()) return; FragmentTransaction transaction = getChildFragmentManager().beginTransaction(); transaction.remove(youTubePlayerFragment).commit(); When jumping to an additional card, the fragment"s card creates a new instance that YouTubePlayerSupportFragment v its respective youTubePlayerFragment.initialize an approach again.

Now, if user returns to main menu and also the activity (deck) is destroyed (after running stopVideo() ), user can reopen the same activity and repeat every these tasks. HOWEVER, I have actually this strange issue:

Open ActivityWatch videos that the cards --> Videos play fine (you have the right to watch up to 30 videos)Go ago to main Menu (i.e. Ruin the activity)Reopen ActivityWatch videos that the cards --> Videos play well (you can watch as much as 30 videos)Go ago to main Menu (i.e.

See more: Dod Emp Drill November 4 6 2017, Emp & Antifa

Damage the activity)Reopen ActivityWatch videos of the cards --> Videos play fine (you deserve to watch as much as 30 videos)Go ago to key Menu (i.e. Damage the activity)Reopen Activity

Watch videos that the cards --> all VIDEOS start TO show THIS MESSAGE:

"There was a trouble while playing (Playback ID: ....) Tap to retry" similar issue has actually been reported in this thread without solution:YouTubePlayerSupportFragment not playing Video