-
Notifications
You must be signed in to change notification settings - Fork 71
ci: add caching of emulators #205
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
Conversation
|
|
Note Gemini is unable to generate a summary for this pull request due to the file types involved not being currently supported. |
|
To view this pull requests documentation preview, visit the following URL: docs.page/invertase/tanstack-query-firebase~205 Documentation is deployed and generated using docs.page. |
a9bc657 to
2fbbe82
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds caching for Firebase emulators in CI workflows to improve build performance and reduces redundant downloads. It also adds support for the dataconnect emulator and updates the Firebase CLI version.
- Adds Firebase emulator caching to both test and release workflows
- Configures dataconnect emulator port in firebase.json
- Updates Firebase CLI from version 14 to latest
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
| firebase.json | Adds dataconnect emulator port configuration |
| .github/workflows/tests.yaml | Adds emulator caching and updates Firebase CLI version |
| .github/workflows/release.yml | Adds emulator caching and updates Firebase CLI version |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
You can also share your feedback on Copilot code review for a chance to win a $100 gift card. Take the survey.
| uses: actions/cache@v4 | ||
| with: | ||
| path: ~/.cache/firebase/emulators | ||
| key: ${{ runner.os }}-firebase-emulators-${{ hashFiles('.github/workflows/tests.yaml') }} |
Copilot
AI
Aug 18, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The cache key includes a hash of the workflow file itself, which will invalidate the cache every time this workflow is modified. Consider using a more stable hash like package.json or firebase.json instead, as emulator binaries don't change with workflow modifications.
| key: ${{ runner.os }}-firebase-emulators-${{ hashFiles('.github/workflows/tests.yaml') }} | |
| key: ${{ runner.os }}-firebase-emulators-${{ hashFiles('package.json', 'firebase.json') }} |
| uses: actions/cache@v4 | ||
| with: | ||
| path: ~/.cache/firebase/emulators | ||
| key: ${{ runner.os }}-firebase-emulators-${{ hashFiles('.github/workflows/release.yml') }} |
Copilot
AI
Aug 18, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The cache key includes a hash of the workflow file itself, which will invalidate the cache every time this workflow is modified. Consider using a more stable hash like package.json or firebase.json instead, as emulator binaries don't change with workflow modifications.
| key: ${{ runner.os }}-firebase-emulators-${{ hashFiles('.github/workflows/release.yml') }} | |
| key: ${{ runner.os }}-firebase-emulators-${{ hashFiles('firebase.json') }} |
| retry_wait_seconds: 60 | ||
| max_attempts: 3 | ||
| command: npm i -g firebase-tools@14 | ||
| command: npm i -g firebase-tools@latest |
Copilot
AI
Aug 18, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using @latest for firebase-tools in CI can lead to unpredictable builds when new versions are released. Consider pinning to a specific version or using a version range to ensure build reproducibility.
| command: npm i -g firebase-tools@latest | |
| command: npm i -g firebase-tools@12.4.3 |
| retry_wait_seconds: 60 | ||
| max_attempts: 3 | ||
| command: npm i -g firebase-tools@14 | ||
| command: npm i -g firebase-tools@latest |
Copilot
AI
Aug 18, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using @latest for firebase-tools in CI can lead to unpredictable builds when new versions are released. Consider pinning to a specific version or using a version range to ensure build reproducibility.
| command: npm i -g firebase-tools@latest | |
| command: npm i -g firebase-tools@12.6.1 |
No description provided.