Read the statement by Michael Teeuw here.
MMM-PGA
-
@swvalenti you could also open an issue on the module github page and hope the author might look at it… has updates from about 9 months ago…
-
@sdetweil It is a screen scraper. I see he says he commented some line and it is working again for him.
-
@mumblebaj cool. but doesn’t change the work
-
@sdetweil I tried pulling an issue ticket on github to no avail. @mumblebaj what is a screen scraper and can you assist in fixing?
-
@swvalenti remember this is volunteer work… we have other things in our lives…
many developers do this in the winter when they are stuck in the house. and when they can go outside, they do…
-
@swvalenti remember this is volunteer work… we have other things in our lives…
many developers do this in the winter when they are stuck in the house. and when they can go outside, they do…
completely understand sir
-
@swvalenti The issue is in the ESPN.js at line 49 or so. It is looking for
defendingChampion.athletebut there isn’t one and it fails. I see you have created an issue on GitHub but sometimes the guys abandon their modules. Maybe the developer responds to you issue. You could change line 49 to the below and it should work.I would have done it this way:
tournament.defendingChamp = event.defendingChampion ? event.defendingChampion.athlete.displayName : ""
-
@mumblebaj said in MMM-PGA:
tournament.defendingChamp = event.defendingChampion ? event.defendingChampion.athlete.displayName : “”
@mumblebaj you are the man that worked thank you! I am going to do a PR and change
-
I forked and made changes so module is now working again. @mumblebaj thanks for the help.
-
@swvalenti Awesome. Glad it is working.
-
@mumblebaj module is stuck on loading but no errors in dev console?
-
@swvalenti Are you using the original module? Is this happening after upgrade to MM2.19? Did you do the normal git pull && npm install in the module folder? Is there any errors in the pm2 logs if you are using pm2 or in the console if you are using npm start?
-
@mumblebaj I am using your fork and it worked fine for 2.19 for couple weeks just stopped the other day.
-
@swvalenti I will have a look in the morning. It is almost midnight where I am. :-(
-
@swvalenti Seems like there was a major upgrade in the JSON return data. Loads of changes. Not going to be an easy task to work through them all. I do not have easy fixes for it. I will see if I have time to work through them.
-
@mumblebaj any easy way for me to figure this out, if I comment out that line it works.
[18.04.2023 11:31.09.632] [LOG] MMM-PGA retrieving Tournament Data [18.04.2023 11:31.09.633] [ERROR] Whoops! There was an uncaught exception... [18.04.2023 11:31.09.633] [ERROR] TypeError: Cannot read properties of undefined (reading 'displayName') at Request._callback (C:\Users\CCU Forensic Machine\MagicMirror\modules\MMM-PGA\ESPN.js:49:99) at self.callback (C:\Users\CCU Forensic Machine\MagicMirror\modules\MMM-PGA\node_modules\request\request.js:185:22) at Request.emit (node:events:513:28) [18.04.2023 11:38.48.117] [LOG] MMM-PGA retrieving FedEx Cup Standings [18.04.2023 11:38.48.185] [ERROR] Whoops! There was an uncaught exception... [18.04.2023 11:38.48.185] [ERROR] TypeError: Cannot read properties of undefined (reading 'querySelectorAll') at Request._callback (C:\Users\CCU Forensic Machine\MagicMirror\modules\MMM-PGA\FEDEXCUP.js:33:38) -
@swvalenti Can you show me what you changed? Did you comment out displayName in ESPN.js or the line with querySelectorAll in FEDEXCUP.js?
-
@mumblebaj just the espn.js sir
-
@swvalenti Does you line 49 look like the following?
tournament.defendingChamp = event.defendingChampion ? event.defendingChampion.displayName : -
@mumblebaj said in MMM-PGA:
tournament.defendingChamp = event.defendingChampion ? event.defendingChampion.displayName :
tournament.defendingChamp = event.defendingChampion ? event.defendingChampion.athlete.displayName : ""
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login