Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No name's github stats #77

Open
reveurguy opened this issue Jul 6, 2022 · 4 comments
Open

No name's github stats #77

reveurguy opened this issue Jul 6, 2022 · 4 comments

Comments

@reveurguy
Copy link

I am trying to implement the stats on readme. I have created all the files and folders and yaml file but I am getting No name's github stats and no stats. I am an attaching the image for reference:

Screenshot 2022-07-06 at 2 58 34 PM

This is my main.yml file:

# This is a basic workflow to help you get started with Actions

name: Generate Stats Images

# Controls when the action will run. Triggers the workflow on push events
on:
  push:
  schedule:
    - cron: "0 0 * * *"
  workflow_dispatch:

permissions:
  contents: write

# A workflow run is made up of one or more jobs that can run sequentially or in
# parallel
jobs:
  # This workflow contains a single job called "build"
  build:
    # The type of runner that the job will run on
    runs-on: ubuntu-latest

    # Sequence of tasks that will be executed as part of the job
    steps:
    # Checks-out repository under $GITHUB_WORKSPACE, so the job can access it
    - uses: actions/checkout@v2

    # Run using Python 3.8 for consistency and aiohttp
    - name: Set up Python 3.8
      uses: actions/setup-python@v2
      with:
        python-version: '3.8'
        architecture: 'x64'

    # Cache dependencies. From:
    # https://github.com/actions/cache/blob/master/examples.md#python---pip
    - uses: actions/cache@v2
      with:
        path: ~/.cache/pip
        key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
        restore-keys: |
          ${{ runner.os }}-pip-


    # Install dependencies with `pip`
    - name: Install requirements
      run: |
        python3 -m pip install --upgrade pip setuptools wheel
        python3 -m pip install -r requirements.txt

    - name: Generate images
      run: |
        python3 --version
        python3 generate_images.py
      env:
        ACCESS_TOKEN: ${{ secrets.ACCESS_TOKEN }}
        GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
        EXCLUDE_FORKED_REPOS: true

    # Commits all changed files to the repository
    - name: Commit to the output branch of repo
      run: |
        git config --global user.name "reveurguy"
        git config --global user.email "reveur.guy99@gmail.com"
        git add .
        git commit -m 'temp commit' || echo
        git checkout output1 2>/dev/null || git checkout --orphan output1 && git rm -rf . && git checkout master -- generated/
        # "echo" returns true so the build succeeds, even if no changed files
        git commit -m 'Update generated files' || echo
        git push origin output1 -f
@seanpm2001
Copy link

I have been running this process for nearly a month. I have noted that it only says No name when it hasn't properly indexed all repositories. It appears to be random, some days it works, some days it doesn't. It will work eventually if you let it run enough times. Although inconvenient, this is what I have observed. The stats should appear when it runs correctly as well. Try running it for 14 days and sample the results.

@jstrieb
Copy link
Owner

jstrieb commented Aug 15, 2022

What permissions to you have set on your personal access token?

@jmmaa
Copy link

jmmaa commented Nov 8, 2022

What permissions to you have set on your personal access token?

same issue, I have not set any permissions on my token

@iaizawa0623
Copy link

I think you used "Fine-grained personal access tokens".
Try using "personal access tokens (classic)".
Don't forget to check repo and user:read permissions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants