question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

May I ask why? pip cache is not found

See original GitHub issue
jobs:
  
  build:
  
    runs-on: ${{ matrix.os }}
    environment: build
    permissions:
      contents: write

    strategy:
      matrix:
        os: [ macos-12 ]

    steps:
     
      - uses: actions/checkout@v3
        with:
          submodules: recursive
      - uses: actions/setup-python@v4
        with:
          python-version: '3.9'
          architecture: "x64"
          cache: 'pip'
      - run: |
          pip install -r requirements.txt
image

There is no cache for each build

I don’t know why. Every build indicates that there is no cache

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:15 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
duolabmeng6commented, Jul 25, 2022

I have understood the reason. Thank you very much for your help

1reaction
duolabmeng6commented, Jul 25, 2022

@duolabmeng6 👋 Root cause of your problem is that you are running your workflow each time on a different branch (or tag) and there was not a single run on the main branch. You can read about restrictions for accessing a cache here.

Thank you very much for your answer. I’m reading the information you sent

Read more comments on GitHub >

github_iconTop Results From Across the Web

Why is my pip cache not found? - Atlassian Community
Adding pip as a cache to a step designates it as both producing AND consuming the dependency. The second step was configured with...
Read more >
pip uses incorrect cached package version, instead of the user ...
Since pip 6.0 (back in 2014!), pip install , pip download and pip wheel commands can be told to avoid using the cache...
Read more >
cache/pip disabled immediately after instalation of pip
The directory '/home/administrator/. cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. ...
Read more >
pip cache - pip documentation v22.3.1
Inspect and manage pip's wheel cache. Subcommands: ... <pattern> can be a glob expression or a package name. Options#.
Read more >
Python caching in GitHub Actions - AI2 Blog
Luckily there's a simple way to improve this: instead of caching the pip cache, we can just cache the entire Python environment, which...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found