rharkor / caching-for-turbo Goto Github PK
View Code? Open in Web Editor NEWA Github action to set up Turborepo Remote Caching to work with GitHub Actions' built-in cache instead of Vercel one
License: MIT License
A Github action to set up Turborepo Remote Caching to work with GitHub Actions' built-in cache instead of Vercel one
License: MIT License
Hey, was just curious what the difference is between this action and the steps provided in turbo's docs? Thanks!!
We're facing a bug when using this in one of our composite actions.
We've added the following step before turbo build
:
- name: Cache for Turbo
uses: rharkor/[email protected]
And the issue prevented the workflow from completion in GitHub Actions.
This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.
These are blocked by an existing closed PR and will not be recreated unless you click a checkbox below.
@typescript-eslint/eslint-plugin
, @typescript-eslint/parser
).devcontainer/devcontainer.json
mcr.microsoft.com/devcontainers/typescript-node 22
ghcr.io/devcontainers/features/github-cli 1
ghcr.io/devcontainers-contrib/features/prettier 1
.github/workflows/check-dist.yml
actions/checkout v4
actions/setup-node v4
.github/workflows/ci.yml
actions/checkout v4
actions/setup-node v4
actions/checkout v4
actions/setup-node v4
actions/checkout v4
actions/setup-node v4
.github/workflows/codeql-analysis.yml
actions/checkout v4
github/codeql-action v3
github/codeql-action v3
github/codeql-action v3
.node-version
node 20.16.0
package.json
@actions/cache ^3.2.4
@actions/core ^1.10.1
fastify ^4.27.0
stream-to-promise ^3.0.0
wait-on ^7.2.0
@jest/globals ^29.7.0
@types/node ^20.14.2
@types/stream-to-promise ^2.2.4
@types/wait-on ^5.3.4
@typescript-eslint/eslint-plugin ^7.0.0
@typescript-eslint/parser ^7.0.0
@vercel/ncc ^0.38.1
eslint ^8.57.0
eslint-plugin-github ^5.0.1
eslint-plugin-jest ^28.6.0
eslint-plugin-jsonc ^2.16.0
eslint-plugin-prettier ^5.1.3
make-coverage-badge ^1.2.0
prettier ^3.3.2
prettier-eslint ^16.3.0
ts-jest ^29.1.4
tsx ^4.15.4
turbo ^2.0.3
typescript ^5.4.5
node >=20
npm 10.8.2
There is an error with this repository's Renovate configuration that needs to be fixed. As a precaution, Renovate will stop PRs until it is resolved.
Error type: Cannot find preset's package (config:recommeded)
For Windows, the log file is not created.
Error: ENOENT: no such file or directory, open 'D:\tmp\turbogha.log'
at openSync (node:fs:573:18)
at launchServer (D:\a\_actions\rharkor\caching-for-turbo\d030e8813d3de6746943c17def1f5643b1dd1e94\src\lib\server\utils.ts:28:1)
at run (D:\a\_actions\rharkor\caching-for-turbo\d030e8813d3de6746943c17def1f5643b1dd1e94\src\main.ts:16:1)
at D:\a\_actions\rharkor\caching-for-turbo\d030e8813d3de6746943c17def1f5643b1dd1e94\src\index.ts:7:1
at D:\a\_actions\rharkor\caching-for-turbo\d030e8813d3de6746943c17def1f5643b1dd1e94\dist\index.js:1585[12](https://github.com/psychobolt/vite-storybook-boilerplate/actions/runs/9617119273/job/26528200184?pr=920#step:5:13):3
at Object.<anonymous> (D:\a\_actions\rharkor\caching-for-turbo\d030e88[13](https://github.com/psychobolt/vite-storybook-boilerplate/actions/runs/9617119273/job/26528200184?pr=920#step:5:14)d3de6746943c17def1f5643b1dd1e94\dist\index.js:158515:12)
at Module._compile (node:internal/modules/cjs/loader:1358:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:[14](https://github.com/psychobolt/vite-storybook-boilerplate/actions/runs/9617119273/job/26528200184?pr=920#step:5:15)16:10)
at Module.load (node:internal/modules/cjs/loader:1208:32)
at Function.Module._load (node:internal/modules/cjs/loader:1024:12)
Which I also found another bug,
Post job cleanup.
D:\a\_actions\rharkor\caching-for-turbo\d030e8813d3de6746943c17def1f5643b1dd1e94\post.js:[2](https://github.com/psychobolt/vite-storybook-boilerplate/actions/runs/9617119273/job/26528200184?pr=920#step:10:2)2
if (error instanceof Error) core.setFailed(error.message)
^
ReferenceError: core is not defined
at run (D:\a\_actions\rharkor\caching-for-turbo\d0[3](https://github.com/psychobolt/vite-storybook-boilerplate/actions/runs/9617119273/job/26528200184?pr=920#step:10:3)0e8813d3de6746943c17def1f5643b1dd1e94\post.js:22:33)
at process.processTicksAndRejections (node:internal/process/task_queues:9[5](https://github.com/psychobolt/vite-storybook-boilerplate/actions/runs/9617119273/job/26528200184?pr=920#step:10:5):5)
Node.js v20.13.1
Seeing here import * as core from '@actions/core';
is not declared.
Also would it be ideal for log folder be same as runner.temp
? Reference
As a workaround for anyone running into the same issue for Windows, you may add this step:
- name: Create Turbo Cache Server Log
if: matrix.os == 'windows-latest'
run: mkdir D:/tmp && touch D:/tmp/turbogha.log || exit 0
shell: bash
Hi, there is a error with finding the temporary cached data on Windows. See logs:
Error: Unable to upload cache: Error: ENOENT: no such file or directory, open 'D:\tmp\cache-24932.tg.bin'
{"level":50,"time":1719255262077,"pid":3380,"hostname":"fv-az1489-381","reqId":"req-a","req":{"method":"PUT","url":"/v8/artifacts/1d9d215f8c05f1f4?slug=turbogha","hostname":"localhost:41230","remoteAddress":"::1","remotePort":50049},"res":{"statusCode":500},"err":{"type":"Error","message":"ENOENT: no such file or directory, open 'D:\\tmp\\cache-24932.tg.bin'","stack":"Error: ENOENT: no such file or directory, open 'D:\\tmp\\cache-24932.tg.bin'","errno":-[40](https://github.com/psychobolt/vite-storybook-boilerplate/actions/runs/9652918639/job/26624145421#step:10:40)58,"code":"ENOENT","syscall":"open","path":"D:\\tmp\\cache-24932.tg.bin"},"msg":"ENOENT: no such file or directory, open 'D:\\tmp\\cache-24932.tg.bin'"}
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.