Skip to content

What is the exact reason that one should not cache the vendor directly #983

Closed

Description

@Ilyes512

The readme mentions the following:

Please do not cache vendor directory using action/cache as that will have side effects.

I would like to know more about what is exactly the issue? What are these side-effects? I currently do cache the vendor dir, since I didn't came across the line in the readme at the time when I implemented it. So now I am wondering what the reason is as it does look like it works just fine.

(I will try and benchmark the difference between caching and not caching the vendor directly.)

Activity

  1. shivammathur commented on Aug 8, 2025

    @shivammathur
    Owner

    I think that is based on this discussion.
    travis-ci/travis-ci#4579 (comment)

    But, If you publish composer.lock file and the cache key is based on the hash of that, I think it might be fine to cache the vendor directory now. If anything goes wrong, you can evict the cache easily using the actions UI.

  2. Repository owner locked and limited conversation to collaborators on Aug 10, 2025
  3. converted this issue into a discussion #984 on Aug 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions