Code Monkey home page Code Monkey logo

strava-kudos's Introduction

Strava Kudos Giver ๐Ÿ‘๐Ÿ‘๐Ÿ‘

Python 3.10 Build Give Strava Kudos

A Python tool to automatically give Strava Kudos to recent activities on your feed. There are a few repos that uses JavaScript like strava-kudos-lambda and strava-kudos.

The repo is set up so that the script runs on a set schedule via Github Actions. Github suggests in their docs to not run cron jobs at the start of every hour to avoid delays so minute30 was chosen here. Feel free to change it to whenever you want. There is also a max_run_duration parameter which is 9 minutes by default so that we don't exceed the monthly Github Action free tier minutes when the action is triggered a few times a day.

๐Ÿƒ Usage

  1. Fork the repo
  2. Setup the environment variables in secrets
  3. Give kudos automatically!

Alternatively, you can run the script manually with

python3 give_kudos.py

๐Ÿ› ๏ธSetup

Playwright

Playwright is used, so be sure to follow instructions to install it properly.

Environment Variables

Set the environment variables for your email and password as follows:

export STRAVA_EMAIL=YOUR_EMAIL
export STRAVA_PASSWORD=YOUR_PASSWORD

Github Actions

To add secrets for GH actions, navigate to Settings -> Security -> Secrets and Variables -> Actions. Enter your email and password within Repository Secrets.

Contributions

Let me know if you wish to add anything or if there are any issues :)

ForTheBadge built-with-love

strava-kudos's People

Contributors

bin101 avatar isaac-chung avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

strava-kudos's Issues

script fails after retries

no kudos are given, script basically times out after retries.

error started showing up recently, maybe this week?

Unable to find own profile ID, nor web feeds

Unable to Find Own Profile ID and Web Feeds

Description

I'm encountering an issue with the script (Playwright version pinned in requirements.txt).
While the script successfully logs in, it fails to:

  1. Retrieve the user's own profile ID
  2. Access web feeds after manually setting the profile ID

It seems these problems are not dependent as manually setting the profile ID doesn't resolve the web feed issue.

Steps to Reproduce

  1. Run the script locally or through GitHub actions.
  2. Observe the script successfully logging in to Strava.
  3. Verify the script fails to retrieve the user's own profile ID.
  4. Optional:
    • Manually set the profile ID in the script.
    • Observe the script still fails to access web feeds.

Expected Behavior

  1. The script retrieves the user's own profile ID after successful login.
  2. After login (or with a manually set profile ID), the script successfully retrieves and processes web feeds.

System Information

  • Python Version: (both 3.11 and 3.12)
  • Playwright Version: (pinned in requirements.txt)

Issue retrieving own activity's owner name

Looking over the logs, it seems like this line is having trouble.

 h = container.get_by_test_id("owners-name").get_attribute('href')

The id might not exist anymore, or under a different structure. Would be good to have a fix.

no web feeds found, no kudos given....

Hi,

I just installed your script and could finally run it...
But It gives the following response:


python3 give_kudos.py
---Logged in!!---
id xxxxx
web feeds found: 0

Kudos given: 0

Even the feed has open activities to give kudos....
Am I doing something wrong?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.