Skip to main content

A parser for the Leaguepedia website, focused on accessing esports data.

Project description

leaguepedia_parser

A parser for the Leaguepedia website, focused on accessing esports data.

Possible future functionality includes direct querying for games from team names, fuzzy matching for tournament names, .... Any help is welcome, I am currently only adding features that I use on my projects.

Install

pip install leaguepedia_parser

Usage

import leaguepedia_parser

lp = leaguepedia_parser.LeaguepediaParser()

# Gets you available regions
lp.get_tournament_regions()

# Gets you tournaments in the region, by default only returns primary tournaments
tournaments = lp.get_tournaments('Korea', year=2020)

# Gets you all games for a tournament. Get the name from get_tournaments()
games = lp.get_games(tournaments[0]['name'])

# Gets picks and bans for a game. Get the game object from get_games()
lp.get_picks_bans(games[0])

# Gets the URL of the team’s logo
lp.get_team_logo('T1')

# Get player’s info
lp.get_player('Faker')

More usage examples can be found in the _tests folder where every function is tested at least once.

river_mwclient

If you installed river_mwclient, the LeaguepediaParser class will inherit from its EsportsClient class.

If not, it will simply be a wrapper for mwclient.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

leaguepedia_parser-0.2.0.tar.gz (6.6 kB view details)

Uploaded Source

File details

Details for the file leaguepedia_parser-0.2.0.tar.gz.

File metadata

  • Download URL: leaguepedia_parser-0.2.0.tar.gz
  • Upload date:
  • Size: 6.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.8.2

File hashes

Hashes for leaguepedia_parser-0.2.0.tar.gz
Algorithm Hash digest
SHA256 6144bfe2c1d440c9c8fe66d854a6fbc5f5a9a0f8a891bfd2c9cb5f18e869e533
MD5 a110a8559b3bec7c0cb209d3c8756756
BLAKE2b-256 1c1034776d8115bfab9a144ca9d8a9c73dafddbcb8f17b3b16bd0fa5a3d42e03

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page