-
Notifications
You must be signed in to change notification settings - Fork 263
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Player Name Error #214
Comments
The split function needs the second parameter to indicate how many times to split, and in this case we only want one split:
Technically, it's an issue with https://github.com/BurntSushi/nflgame/ I'm actually kind of surprised this hasn't been an issue yet. I thought there were a few players with the Jr suffix (i.e. Duke Johnson Jr, Ted Ginn Jr). Turns out it's how they are listed at http:https://www.nfl.com/players/profile, and that name does not always match what is on the back of their jerseys. Right now it looks like Charles Leno Jr is the only active player in the NFL, officially, with a Jr suffix in his name. Also, he's been playing since 2014, so did he just change his name? Edit: It looks like his name did change, at least according to Wikipedia: https://en.wikipedia.org/w/index.php?title=Charles_Leno_Jr.&diff=next&oldid=742096818 |
@snake-plissken You should probably make a pull request for that fix. It worked for me. |
@nokemono42 Sorry I'm new to GitHub. |
It has to do with the extra "," in the name. Does anyone know a good way to work around that per chance?
Could not get player info from roster row:
72 Leno, Charles, Jr. T ACT 6'3" 305 10/9/1991 3 Boise StateException:
Traceback (most recent call last):
File "C:\Anaconda2\lib\site-packages\nflgame\update_players.py", line 419, in run
roster.append(meta_from_soup_row(team, row))
File "C:\Anaconda2\lib\site-packages\nflgame\update_players.py", line 179, in meta_from_soup_row
last_name, first_name = map(lambda s: s.strip(), name.split(','))
ValueError: too many values to unpack
The text was updated successfully, but these errors were encountered: