Comments (4)
Thank you for pointing this out. I should not assume the linescore node is present in all cases, so I am checking in a fix for v0.0.8. I will check the 4/8/18 postponed game to see what's going on there too.
from mlb-statsapi.
The game on 4/8/18 is failing because there was no probable pitcher listed for the home team. See #6.
from mlb-statsapi.
>>> import statsapi
>>> statsapi.__version__
'0.0.8'
>>> statsapi.schedule(team=136,start_date='05/11/2018')
[{'game_id': 529982, 'game_datetime': '2018-05-11T23:10:00Z', 'game_date': '2018-05-11', 'game_type': 'R', 'status': 'Postponed', 'away_name': 'Seattle Mariners', 'home_name': 'Detroit Tigers', 'away_id': 136, 'home_id': 116, 'doubleheader': 'N', 'game_num': 1, 'home_probable_pitcher': 'Boyd, Matthew', 'away_probable_pitcher': 'Gonzales, Marco', 'home_pitcher_note': '', 'away_pitcher_note': '', 'away_score': '0', 'home_score': '0', 'current_inning': '', 'inning_state': '', 'summary': '2018-05-11 - Seattle Mariners @ Detroit Tigers (Postponed)'}]
>>> statsapi.schedule(team=136,start_date='04/08/2018')
[{'game_id': 529544, 'game_datetime': '2018-04-08T18:10:00Z', 'game_date': '2018-04-08', 'game_type': 'R', 'status': 'Postponed', 'away_name': 'Seattle Mariners', 'home_name': 'Minnesota Twins', 'away_id': 136, 'home_id': 142, 'doubleheader': 'N', 'game_num': 1, 'home_probable_pitcher': '', 'away_probable_pitcher': '', 'home_pitcher_note': '', 'away_pitcher_note': '', 'away_score': '0', 'home_score': '0', 'current_inning': '', 'inning_state': '', 'summary': '2018-04-08 - Seattle Mariners @ Minnesota Twins (Postponed)'}]
from mlb-statsapi.
Please update to v0.0.8 with pip install --upgrade MLB-StatsAPI
from mlb-statsapi.
Related Issues (20)
- sports_players endpoint requiring season param excludes unsigned FA's HOT 3
- Awards winners by player/season HOT 2
- Today's game date HOT 1
- Cleaner endpoint for stats ranked by team HOT 4
- Question about getting gamePk for past games / how to get game by game stats for each player HOT 5
- Get Player Information HOT 1
- Pitches per inning HOT 3
- Some games are hidden by the api but appear when you search by game_id with the api HOT 3
- What endpoint to get a gamePk given info such as both teams, season, or date HOT 1
- Missing Players HOT 4
- How to get game_log for a player? HOT 2
- How to get minor league stats? HOT 3
- Issue making client side request to api HOT 2
- Additional Data? HOT 2
- Attribute Error - Function: lookup_team HOT 4
- 404 Client Error - team_stats Endpoint HOT 4
- Get number of outs before at bat in play by play? HOT 1
- gameType param not working for sports_players endpoint? HOT 3
- schedule function KeyError HOT 5
- Change License to MIT HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mlb-statsapi.