mikemountain / nfl-led-scoreboard

NFL LED scoreboard! This project can display live scores of your favourite football teams!
GNU General Public License v3.0
101 stars 29 forks source link

Incorrect team abbreviation for Washington #14

Closed steve-cicco closed 3 years ago

steve-cicco commented 3 years ago

Noticed during the Steeler game today (Dec 7) that it wasn't working. Did some digging and found you have Washington's logo and formatting under WAS and it needs to be WSH according to ESPN's API data.

Great job on this. Added some code on my own to display the red zone animation at Heinz Field:

https://twitter.com/scicco21/status/1331799516857708544?s=20

Despite the horrible loss today...go Steelers!

mikemountain commented 3 years ago

Ah thanks man, this season's been a bit (just a bit) of a shitshow, as has 2020, so I haven't had as much time to dedicate to working on this project as I would have liked. Really hoping to tighten it up more soon

steve-cicco commented 3 years ago

It has indeed. Which is why I'm all the more appreciative that folks like you take time to create stuff like this to keep our minds off everything else.

It also doesn't help that there are only a few hours each week where you can develop with live gameday data.

machinasdei commented 3 years ago

Hello, I'm having issues selecting Washington as my favorite team and getting the main.py to run. I've tried WAS and WSH and even WFT in the config.json and neither abbreviation will launch the board. What should be used?

some quick output fails; Traceback;

with WAS;

gametime = datetime.strptime(self.data.game['date'], "%Y-%m-%dT%H:%MZ")

TypeError: 'NoneType' object has no attribute 'getitem'

with WSH

KeyError: u'WSH'

with WFT;

gametime = datetime.strptime(self.data.game['date'], "%Y-%m-%dT%H:%MZ")

TypeError: 'NoneType' object has no attribute 'getitem'

with WASH;

INFO (11:01:26): NFL Scoreboard - v0.0.1 (64x32) Traceback (most recent call last): File "main.py", line 30, in MainRenderer(matrix, data).render() File "/home/me/nfl-led-scoreboard/renderer/main.py", line 29, in render self.render_game() File "/home/me/nfl-led-scoreboard/renderer/main.py", line 33, in __render_game gametime = datetime.strptime(self.data.game['date'], "%Y-%m-%dT%H:%MZ") TypeError: 'NoneType' object has no attribute 'getitem__'

steve-cicco commented 3 years ago

It should be WSH in the config but you also have to change WAS.png to WSH.png in the logos directory if memory serves

machinasdei commented 3 years ago

Thanks Steve, I did catch the .png renames and changed as suggested, but still generates an error; INFO (13:37:08): NFL Scoreboard - v0.0.1 (64x32) INFO (13:37:12): Scheduled State, waiting 30 Traceback (most recent call last): File "main.py", line 30, in MainRenderer(matrix, data).render() File "/home/me/nfl-led-scoreboard/renderer/main.py", line 29, in render self.__render_game() File "/home/me/nfl-led-scoreboard/renderer/main.py", line 40, in __render_game self._draw_pregame() File "/home/me/nfl-led-scoreboard/renderer/main.py", line 116, in _draw_pregame awaysize = self.screen_config.team_logos_pos[overview['awayteam']]['size'] KeyError: u'WSH'

mikemountain commented 3 years ago

In renderer/64x32_config.json, can you try changing WAS to WSH there? I'll try to find some time soon to fix this on the main branch

Edit: unless that's the config you changed it in - if you changed it there too and it's not working, I'll dig deeper

machinasdei commented 3 years ago

hi mike, thanks, that did the trick. I missed it in renderer/64x32_config.json it's working now, got the WSH vs PHI screen saying Today 8:20 PM thanks for your work on this board!