12

A tool to generate your weekly table based on your Strava activities from the last week (Read 240 times)

flavio80


Not an 80%er

    Hi everyone,

     

    Some people on this forum used to use a tool to generate their weeklies table by pulling the last 7 days of activities from Strava.

    A couple months ago I heard that it stopped working.

    It's been a while but today I was bored and assembled something together that might be able to help people do just that.

     

    It's a very early draft, but I control the source code so we are able to iterate on it to make it better.

     

    Those of you who are Java/web developers can send a Pull Request to https://github.com/flaviopezzini/stravaweekly

    Your technical feedback is much appreciated as well

     

    So how does it work?

     

    1 - Go to https://strava-weekly.fly.dev

     

    2 - Click on "click here" next to With Strava.

     

    3 - It will redirect you to the Strava login page. Enter your credentials and click login.

    PS: If you are already logged in to Strava it will skip this step.

     

    4 - It will show a page so you can authorize the app to fetch your activities from the last 7 days.

    The message will be : Authorize forum_weekly_app to connect to Strava

    You just have to click on the big orange "Authorize" button.

     

    5 - It will automatically compute the last week and load activities for it.

    If you live elsewhere in the world and you use the logic, metric system, then tick the check box "Show Metric?" and then click the Activities button.

     

    6 - A table with your activities from the last 7 days will be displayed (name, distance, duration and elevation gain).

     

    7 - There are also buttons to show "Previous week" and "Next week" so you can navigate through your weeks.

    This can be useful if you need to generate the last 2 weeks.

     

    You can reply here to this thread if you find any issue or if you have a recommendation of how we could make it better (other bits of information that you'd like displayed, colors, better way to lay out the buttons, etc).

     

    PS: This has been deployed on a free account on Heroku, I'm not sure exactly what is the limit but it's possible that one of you will eventually hit a limit and it will error out. If that happens, wait half an hour and try again.

     

    Thanks all in advance for the feedback

     

    Edit: 2020-03-29 - I've updated the instructions to reflect the current state of the app.

    Edit: 2024-05-11 - The tool has moved to the fly.dev domain.

    PRs: 1500 4:54.1 2019 - 5K 17:53 2023 - 10K 37:55 2023 - HM 1:21:59 2021

    Up next: some 800m race (or time trials)

    Tool to generate Strava weekly

    JMac11


    RIP Milkman

      Thank you for putting this together! Here are my suggestions:

       

      1) It would be helpful if you can pull last week, not the last 7 days. The problem I see is some folks want to post their weeklies on Tuesday for example, but this will only pull the previous Tuesday to Monday.

       

      2) I would include the date next to each activity.

       

      3) Average pace should be included as well.

       

      4) Can you include a link to the activity like the old version of this had?

       

      5) It pastes a little funky on this site, here's what mine looks like. not sure how you can fix that though:

       

      Weekly

      Name

      Distance

      Duration

      Elevation Gain

      Evening Run

      11.0

      01:25:15

      159.4

      Afternoon Run

      7.0

      00:55:07

      87.2

      Lunch Run

      16.0

      01:55:55

      60.4

      Afternoon Run

      10.9

      01:25:08

      158.6

      When is a niggle actually an injury?

      10.9

      01:28:03

      61.2

      Morning Run

      7.1

      00:59:14

      91.2

      Evening Run

      17.3

      02:13:57

      150.3

      Total distance: 80.2

      5K: 16:37 (11/20)  |  10K: 34:49 (10/19)  |  HM: 1:14:57 (5/22)  |  FM: 2:36:31 (12/19) 

       

       

      flavio80


      Not an 80%er

        thanks Jmac for the great feedback. I have updated the tool according to your suggestions.

         

        Here's how the table looks now. Let me know for more feedback you have and I'll adjust accordingly.

         

        Date Name Distance Duration Average Pace Elevation Gain Link to Strava Activity
        01/03/2020 Morning Run 12.3 01:00:01 00:04:53 70 Link
        29/02/2020 Morning Run 9.1 00:44:56 00:04:56 32 Link
        27/02/2020 Morning Run 9.3 00:45:00 00:04:50 24 Link
        26/02/2020 Morning Run 12.4 01:00:00 00:04:50 24 Link
        25/02/2020 Morning Run 9.2 00:45:00 00:04:53 69 Link
        24/02/2020 Morning Run 6.0 00:30:00 00:05:00 31 Link

        Total distance: 58.3

        PRs: 1500 4:54.1 2019 - 5K 17:53 2023 - 10K 37:55 2023 - HM 1:21:59 2021

        Up next: some 800m race (or time trials)

        Tool to generate Strava weekly

        flavio80


        Not an 80%er

          Here's how it looks when not using metric (default).

           

          Date Name Distance Duration Average Pace Elevation Gain Link to Strava Activity
          03/01/2020 Morning Run 7.6 01:00:01 00:07:54 70 Link
          02/29/2020 Morning Run 5.7 00:44:56 00:07:53 32 Link
          02/27/2020 Morning Run 5.8 00:45:00 00:07:46 24 Link
          02/26/2020 Morning Run 7.7 01:00:00 00:07:48 24 Link
          02/25/2020 Morning Run 5.7 00:45:00 00:07:54 69 Link
          02/24/2020 Morning Run 3.8 00:30:00 00:07:54 31 Link

          Total distance: 36.3

          PRs: 1500 4:54.1 2019 - 5K 17:53 2023 - 10K 37:55 2023 - HM 1:21:59 2021

          Up next: some 800m race (or time trials)

          Tool to generate Strava weekly

          flavio80


          Not an 80%er

            I've also added a couple more improvements.

             

            It loads the previous week. If today is a Sunday it will look up the last 7 days (mon-Sun).

            If it's not a Sunday it computes the previous Sunday and 7 days before that.

             

            Also it's using the user timezone to compute the dates so it should finally help out our fellow Kiwi friends.

             

            Overtime I'll adjust it so you don't have to authorize it on Strava every time.

            PRs: 1500 4:54.1 2019 - 5K 17:53 2023 - 10K 37:55 2023 - HM 1:21:59 2021

            Up next: some 800m race (or time trials)

            Tool to generate Strava weekly

            DavePNW


              JMac - you can also copy/paste from your RA log.

               

              Date ▲ Course Type Distance Duration Pace
              2/24/2020   Default 11.1 mi 1:25:39 7:42
              2/25/2020   Default 17.3 mi 2:13:57 7:44
              2/26/2020   Default 7.1 mi 59:27 8:23
              2/27/2020   Default 10.9 mi 1:28:04 8:07
              2/28/2020   Default 10.9 mi 1:25:16 7:49
              2/29/2020   Default 16.0 mi 1:55:56 7:15
              3/1/2020   Default 7.0 mi 55:07 7:56

              Dave

              flavio80


              Not an 80%er

                I have added a little blurb explaining how start and end dates for the period being displayed are calculated, as well as the start and end dates computed from that.

                I've also changed the table to display the activities in ascending order by date.

                Another change was to use the user time zone when computing said dates.

                PRs: 1500 4:54.1 2019 - 5K 17:53 2023 - 10K 37:55 2023 - HM 1:21:59 2021

                Up next: some 800m race (or time trials)

                Tool to generate Strava weekly

                Running Problem


                Problem Child

                  Seems to work for me. Looks a lot like the previous version we'd used.

                   

                  Weekly for period: From 3/1/2020 to 3/8/2020

                   

                  Date Name Distance Duration Average Pace Elevation Gain Link to Strava Activity
                  03/02/2020 That time we talked about fresh groovers 6.8 57:27 08:27/mi 92.5 Link
                  03/03/2020 That time it was SUUUUUUUU-purrrr 8.0 02:22 07:48/mi 44 Link
                  03/04/2020 That time I'm just not that into you 7.5 56:55 07:35/mi 109.5 Link
                  03/05/2020 That time it was reasonably unreasonable. 7.8 59:28 07:37/mi 114.2 Link
                  03/06/2020 That time I hadn't had enough 7.9 02:43 07:56/mi 114 Link
                  03/07/2020 That time I blamed COVID-1 13.0 51:05 08:33/mi 44.7 Link

                  Total distance: 51.0

                  Many of us aren't sure what the hell point you are trying to make and no matter how we guess, it always seems to be something else. Which usually means a person is doing it on purpose.

                  VDOT 53.37 

                  5k18:xx | Marathon 2:55:22

                  flavio80


                  Not an 80%er

                    I have done a few changes recently to the tool.

                     

                    It now will load the week automatically, we no longer need to click "Generate table".

                     

                    There are now also buttons to view the previous and the next weeks which can be useful if you need to generate the last 2 weeks.

                    PRs: 1500 4:54.1 2019 - 5K 17:53 2023 - 10K 37:55 2023 - HM 1:21:59 2021

                    Up next: some 800m race (or time trials)

                    Tool to generate Strava weekly

                    flavio80


                    Not an 80%er

                      Thanks Piwi and Darkwave for reporting the issue with the duration formatting.

                       

                      It was not displaying the hour bit, so 01:00:00 was being displayed as 00:00.

                       

                      That has been fixed now.

                      PRs: 1500 4:54.1 2019 - 5K 17:53 2023 - 10K 37:55 2023 - HM 1:21:59 2021

                      Up next: some 800m race (or time trials)

                      Tool to generate Strava weekly

                      CalBears


                        Nice tool. One thing I noticed right away is that you are losing on precision of the mileage - Strava reports precision of two digits after dot and you are only taking into account one digit. As a result, I had 100.7 miles last week but your tool reports 100.5 due to that rounding. Is it possible to fix? Thank you!

                        paces PRs - 5K - 5:48  /  10K - 6:05  /  HM - 6:14  /  FM - 6:26 per mile

                        flavio80


                        Not an 80%er

                          Thanks call for the feedback. I've just applied your recommendation.

                          Could you please try again and see if it shows correctly now?

                          PRs: 1500 4:54.1 2019 - 5K 17:53 2023 - 10K 37:55 2023 - HM 1:21:59 2021

                          Up next: some 800m race (or time trials)

                          Tool to generate Strava weekly

                          CalBears


                            Thanks call for the feedback. I've just applied your recommendation.

                            Could you please try again and see if it shows correctly now?

                             

                            Looks good flavio - thanks! Now I have to figure out why Strava gave me 100.7 miles and your tool and RunningAhead log gave me 100.8 Smile

                            paces PRs - 5K - 5:48  /  10K - 6:05  /  HM - 6:14  /  FM - 6:26 per mile

                            flavio80


                            Not an 80%er

                              Oh, that was a rounding choice. I was rounding every day to 2 digits after the decimal point and accumulating that value.

                              I've just adjusted it to accumulate in meters instead and then compute km/miles at the end.

                               

                              Thanks for the feedback!

                              PRs: 1500 4:54.1 2019 - 5K 17:53 2023 - 10K 37:55 2023 - HM 1:21:59 2021

                              Up next: some 800m race (or time trials)

                              Tool to generate Strava weekly

                              Marky_Mark_17


                                Flavio- the last couple of weeks, I've not been able to use this as the output is not capturing all my runs (I've tried it on Sunday, Monday and Tuesday).  The issues seem to be:

                                • For weeks starting March 23 onwards, it's only showing the first 4 runs for each week
                                • The weekly mileage total doesn't show for those weeks where it only picks up 4 runs (if you switch to a week that does have a mileage total, it then incorrectly populates that same total into the 4-run weeks)

                                I changed my profile to private a couple of weeks ago, but I tried re-running the summary with it set to public and have the same issues, so I don't think it's that.

                                 

                                I've seen others seem to have successfully posted the last week training using this so I'm not quite sure whether it's just some sort of issue/setting I'm having.

                                3,000m: 9:07.7 (Nov-21) | 5,000m: 15:39 (Dec-19) | 10,000m: 32:34 (Mar-20)  

                                10km: 33:15 (Sep-19) | HM: 1:09:41 (May-21)* | FM: 2:41:41 (Oct-20)

                                * Net downhill course

                                Last race: Runway5 / National 5k Champs, 16:22, National Masters AG Champ!

                                Up next: Still working on that...

                                "CONSISTENCY IS KING"

                                12