athul / waka-readme

Wakatime Weekly Metrics on your Profile Readme.
https://github.com/athul
MIT License
1.56k stars 302 forks source link

Error with last build probably some issue with last commit. #18

Closed riginoommen closed 4 years ago

riginoommen commented 4 years ago

image

athul commented 4 years ago

Hey @riginoommen, I have a few speculations on why this is happening. I'm not sure which is the issue correctly but here you go

I had just run the action on my repo and it seems to work just fine.

cc: @joe733 @gautamkrishnar any ideas on why this is happening?

Smartuil commented 4 years ago

I have the same problem

gautamkrishnar commented 4 years ago

@athul If I am inferring correctly, The lang_data array is empty in this case. Can you try out the workflow after signing up as a new user without any stats?

athul commented 4 years ago

Yes, I just ran the code and it's due to the empty list, maybe a if condition will be enough to resolve the issue or a try except block? Try except could help us exit with a warning method

What do you say?

gautamkrishnar commented 4 years ago

@athul Don't exit with a status greater than 0, Just put a console log to let the users wait till the next day or their data is empty.

athul commented 4 years ago

So I guess I should remove all the sys.exit(1) from the code

gautamkrishnar commented 4 years ago

@athul yes do exit(1) only when you have some required parameters error or API fetching error. Users will receive a notification via email whenever a job fails.

sebastiandg7 commented 4 years ago

+1. Happening here too, with recently created account. Have you tested what happens when a user does not log any time for a week? Maybe this lang_data array is also empty, I think you should write something like "No time tracked this week 😅".

athul commented 4 years ago

Sorry for the bug. Sending a PR in a few mins

athul commented 4 years ago

Hey @riginoommen @Smartuil @sebastiandg7 could you check and verify if its working?

riginoommen commented 4 years ago

I verified it. Job is working fine in the logs but its not pulling the stats.i reverified the secrets also

image

I have the stats in wakatime

image

athul commented 4 years ago

BTW @riginoommen did you start using it today?

If yes. Wait till 00.00 UTC since thats the time the API data gets updated

riginoommen commented 4 years ago

I triggered this manually now still same results

athul commented 4 years ago

I meant, Did you start using wakatime today?

riginoommen commented 4 years ago

Yes

On Wed, 22 Jul 2020, 11:29 pm Athul Cyriac Ajay, notifications@github.com wrote:

I meant, Did you start using wakatime today?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/athul/waka-readme/issues/18#issuecomment-662599779, or unsubscribe https://github.com/notifications/unsubscribe-auth/AA5JR5BZEQGLUURN44A2BKDR44SHRANCNFSM4PESDMSQ .

athul commented 4 years ago

Okay, then don't worry. It'll generate the updated stats tommorow morning(5.30 AM IST)

Smartuil commented 4 years ago

Hey @riginoommen @Smartuil @sebastiandg7 could you check and verify if its working?

It's working.

riginoommen commented 4 years ago

Yay its working now

On Thu, 23 Jul 2020, 7:46 am Smartuil, notifications@github.com wrote:

Hey @riginoommen https://github.com/riginoommen @Smartuil https://github.com/Smartuil @sebastiandg7 https://github.com/sebastiandg7 could you check and verify if its working?

It's working.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/athul/waka-readme/issues/18#issuecomment-662787312, or unsubscribe https://github.com/notifications/unsubscribe-auth/AA5JR5FNNKENXQZPYFG4ASTR46MPLANCNFSM4PESDMSQ .

athul commented 4 years ago

Since it's solved, I guess it's safe to close this issue. Feel free to open one if you found any other bugs