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

Speed up Psalm tests #49001

Merged
merged 1 commit into from Feb 13, 2023
Merged

Speed up Psalm tests #49001

merged 1 commit into from Feb 13, 2023

Conversation

danepowell
Copy link
Contributor

Q A
Branch? 6.3
Bug fix? no
New feature? no
Deprecations? no
Tickets Fix #...
License MIT
Doc PR symfony/symfony-docs#...

The setupphp maintainer recommends caching the couchbase extension using the cache-extensions action. This should speed up Psalm runs from 14 minutes to 2 minutes!

@carsonbot carsonbot added this to the 6.3 milestone Jan 16, 2023
@danepowell
Copy link
Contributor Author

Might not be able to actually see this working until #49000 is merged...

@xabbuh
Copy link
Member

xabbuh commented Jan 23, 2023

@danepowell #49000 has been merged, you may want to rebase. :)

@danepowell
Copy link
Contributor Author

This sped up Psalm tests from 40 minutes to 3 minutes! 😂

.github/workflows/psalm.yml Outdated Show resolved Hide resolved
.github/workflows/psalm.yml Outdated Show resolved Hide resolved
@danepowell danepowell requested review from stof and javiereguiluz and removed request for stof January 24, 2023 15:50
@danepowell danepowell requested review from stof and removed request for javiereguiluz January 24, 2023 15:50
@nicolas-grekas
Copy link
Member

We should merge this on 5.4, isn't it?

@nicolas-grekas nicolas-grekas modified the milestones: 6.3, 5.4 Feb 13, 2023
@nicolas-grekas nicolas-grekas changed the base branch from 6.3 to 5.4 February 13, 2023 15:02
@nicolas-grekas
Copy link
Member

Thank you @danepowell.

@nicolas-grekas nicolas-grekas merged commit 99d2424 into symfony:5.4 Feb 13, 2023
with:
php-version: ${{ env.php-version }}
extensions: ${{ env.extensions }}
key: cache-v1 # can be any string, change to clear the extension cache.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

on 6.3 the list of extensions is not the same as on 6.2/5.4
shouldn't we vary this by php-version + extensions?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I haven't used GitHub Actions caching much, but I think it will attempt to restore the cache from the current branch before falling back to the default branch. So there shouldn't be any harm in reusing a cache key across branches.

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

Successfully merging this pull request may close these issues.

None yet

6 participants