[extractor/PokemonSoundLibrary] Remove extractor (#3918)

Authored by: Lesmiscore
This commit is contained in:
Lesmiscore 2022-05-31 18:02:29 +09:00 committed by GitHub
parent 661e7253a2
commit 1cd6cba306
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 0 additions and 42 deletions

View file

@ -1275,7 +1275,6 @@
from .pokemon import ( from .pokemon import (
PokemonIE, PokemonIE,
PokemonWatchIE, PokemonWatchIE,
PokemonSoundLibraryIE,
) )
from .pokergo import ( from .pokergo import (
PokerGoIE, PokerGoIE,

View file

@ -1,5 +1,3 @@
import re
from .common import InfoExtractor from .common import InfoExtractor
from ..utils import ( from ..utils import (
ExtractorError, ExtractorError,
@ -136,42 +134,3 @@ def _real_extract(self, url):
'episode': video_data.get('title'), 'episode': video_data.get('title'),
'episode_number': int_or_none(video_data.get('episode')), 'episode_number': int_or_none(video_data.get('episode')),
}) })
class PokemonSoundLibraryIE(InfoExtractor):
_VALID_URL = r'https?://soundlibrary\.pokemon\.co\.jp'
_TESTS = [{
'url': 'https://soundlibrary.pokemon.co.jp/',
'info_dict': {
'title': 'Pokémon Diamond and Pearl Sound Tracks',
},
'playlist_mincount': 149,
}]
def _real_extract(self, url):
musicbox_webpage = self._download_webpage(
'https://soundlibrary.pokemon.co.jp/musicbox', None,
'Downloading list of songs')
song_titles = [x.group(1) for x in re.finditer(r'<span>([^>]+?)</span><br/>をてもち曲に加えます。', musicbox_webpage)]
song_titles = song_titles[4::2]
# each songs don't have permalink; instead we return all songs at once
song_entries = [{
'id': f'pokemon-soundlibrary-{song_id}',
'url': f'https://soundlibrary.pokemon.co.jp/api/assets/signing/sounds/wav/{song_id}.wav',
# note: the server always serves MP3 files, despite its extension of the URL above
'ext': 'mp3',
'acodec': 'mp3',
'vcodec': 'none',
'title': song_title,
'track': song_title,
'artist': 'Nintendo / Creatures Inc. / GAME FREAK inc.',
'uploader': 'Pokémon',
'release_year': 2006,
'release_date': '20060928',
'track_number': song_id,
'album': 'Pokémon Diamond and Pearl',
} for song_id, song_title in enumerate(song_titles, 1)]
return self.playlist_result(song_entries, playlist_title='Pokémon Diamond and Pearl Sound Tracks')