AGill
AGill
Explore posts from servers
CDCloudflare Developers
Created by AGill on 3/2/2025 in #pages-help
Real-Time Logs not showing error responses
^ don't know why I got lucky with that request. the issue still persists. not seeing logs for the error responses. even after waiting
11 replies
CDCloudflare Developers
Created by AGill on 3/2/2025 in #pages-help
Real-Time Logs not showing error responses
10:04 -> 10:14
11 replies
CDCloudflare Developers
Created by AGill on 3/2/2025 in #pages-help
Real-Time Logs not showing error responses
No description
11 replies
CDCloudflare Developers
Created by AGill on 3/2/2025 in #pages-help
Real-Time Logs not showing error responses
{
"url": "/api/reports/z4y4l3jpgmyq0luxgi9s1zuy?items=slim",
"statusCode": 401,
"statusMessage": "",
"message": "signature verification failed",
"stack": ""
}
{
"url": "/api/reports/z4y4l3jpgmyq0luxgi9s1zuy?items=slim",
"statusCode": 401,
"statusMessage": "",
"message": "signature verification failed",
"stack": ""
}
That's the error I'm trying to debug, which happens periodically
11 replies
CDCloudflare Developers
Created by AGill on 3/2/2025 in #pages-help
Real-Time Logs not showing error responses
No description
11 replies
CDCloudflare Developers
Created by AGill on 3/2/2025 in #pages-help
Real-Time Logs not showing error responses
No description
11 replies
CDCloudflare Developers
Created by AGill on 3/2/2025 in #pages-help
Real-Time Logs not showing error responses
But I for certain don't see the logs for the error responses. Didn't apply any filters either
11 replies
CDCloudflare Developers
Created by louis on 2/27/2025 in #workers-help
Crop images in a worker
I'm using Jimp in my CF pages app. Looks to have a crop method: https://jimp-dev.github.io/jimp/api/jimp/classes/jimp/#crop
4 replies
CDCloudflare Developers
Created by BigBallard on 2/19/2025 in #pages-help
Nuxt + AWS SDK + TS transpilation issue
checkout aws4fetch package which should work in CF workers: https://www.npmjs.com/package/aws4fetch
3 replies
CDCloudflare Developers
Created by Nitish on 3/26/2024 in #r2
can i do something i will 2 copies of
^ endpoint is /images/[pathname].ts where [pathname] is the R2 prefix + filename
5 replies
CDCloudflare Developers
Created by Nitish on 3/26/2024 in #r2
can i do something i will 2 copies of
Hey did you guys figure this out? I'm also trying to serve images from my R2 bucket but I want to resize them on demand. My app is using NuxtJS and I have a dedicated API endpoint in my app to serve the R2 image. the return response the endpoint is the object.body of the R2 object which is type ReadableStream
export default eventHandler(async (event) => {
const { pathname: normalizedPathname } = event.context.params || {};

const pathname = denormalizePath(normalizedPathname);

await authorizeR2ObjectRequest(event, pathname);

const object = await assertObject(event, pathname);

const contentType
= object.httpMetadata?.contentType || getContentType(pathname);

setHeader(event, 'Content-Type', contentType);
setHeader(event, 'Content-Length', object.size);
setHeader(event, 'etag', object.httpEtag);
setHeader(event, 'Content-Security-Policy', 'default-src \'none\';');

return object.body;
});
export default eventHandler(async (event) => {
const { pathname: normalizedPathname } = event.context.params || {};

const pathname = denormalizePath(normalizedPathname);

await authorizeR2ObjectRequest(event, pathname);

const object = await assertObject(event, pathname);

const contentType
= object.httpMetadata?.contentType || getContentType(pathname);

setHeader(event, 'Content-Type', contentType);
setHeader(event, 'Content-Length', object.size);
setHeader(event, 'etag', object.httpEtag);
setHeader(event, 'Content-Security-Policy', 'default-src \'none\';');

return object.body;
});
5 replies
NNuxt
Created by BiffBaffBoff on 9/6/2024 in #❓・help
Cloudflare pages preset
lol fair point I ended up using jsquash: https://github.com/jamsinclair/jSquash
3 replies
NNuxt
Created by BiffBaffBoff on 9/6/2024 in #❓・help
Cloudflare pages preset
I was able to deploy sharp -- see issues comment: https://github.com/lovell/sharp/issues/4113#issuecomment-2560374164 But now I'm getting some runtime errors so I need to figure that out:
Could not load the \"sharp\" module using the linuxnull-undefined runtime\nundefined: Could not dynamically require \"../src/build/Release/sharp-linuxnull-undefined.node\". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.\nundefined: Could not dynamically require \"../src/build/Release/sharp-wasm32.node\". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.\nundefined: Could not dynamically require \"@img/sharp-linuxnull-undefined/sharp.node\". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.\nundefined: Could not dynamically require \"@img/sharp-wasm32/sharp.node\". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.\nPossible solutions:\n- Manually install libvips >= 8.15.3\n- Add experimental WebAssembly-based dependencies:\n npm install --cpu=wasm32 sharp\n npm install @img/sharp-wasm32\n- Consult the installation documentation:\n See https://sharp.pixelplumbing.com/install\n"
Could not load the \"sharp\" module using the linuxnull-undefined runtime\nundefined: Could not dynamically require \"../src/build/Release/sharp-linuxnull-undefined.node\". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.\nundefined: Could not dynamically require \"../src/build/Release/sharp-wasm32.node\". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.\nundefined: Could not dynamically require \"@img/sharp-linuxnull-undefined/sharp.node\". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.\nundefined: Could not dynamically require \"@img/sharp-wasm32/sharp.node\". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.\nPossible solutions:\n- Manually install libvips >= 8.15.3\n- Add experimental WebAssembly-based dependencies:\n npm install --cpu=wasm32 sharp\n npm install @img/sharp-wasm32\n- Consult the installation documentation:\n See https://sharp.pixelplumbing.com/install\n"
3 replies
CDCloudflare Developers
Created by Alsososcar on 11/28/2024 in #workers-help
Process data, then upload to Neon without going to page?
3 replies
CDCloudflare Developers
Created by Alsososcar on 11/28/2024 in #workers-help
Process data, then upload to Neon without going to page?
should be feasible with workers yes
3 replies
CDCloudflare Developers
Created by Josh on 10/7/2024 in #pages-help
Running with a newer version of Node - env var not being passed through?
I'm having the same issue: https://discord.com/channels/595317990191398933/1291619831870656584 And also https://discord.com/channels/595317990191398933/1288937653537869979 By recreate deployment, do you mean deleting the pages project entirely? and recreating? Because I've also tried re-deploying within the same project to no avail.
4 replies
CDCloudflare Developers
Created by Lune on 10/4/2024 in #workers-help
Puppeeter with cloudflare workers
The cloudflare browser rendering API is the infra (AKA Binding) that runs the puppeteer instance for you. And the @cloudflare/puppeteer package is what you install in your app to use the binding.
4 replies
CDCloudflare Developers
Created by AGill on 10/4/2024 in #pages-help
[Nuxt] Unable to load env vars when nodejs_compat flag enabled
4 replies
CDCloudflare Developers
Created by AGill on 10/4/2024 in #pages-help
[Nuxt] Unable to load env vars when nodejs_compat flag enabled
I see thanks for sharing. Unfortunately I'm stuck waiting because I need nodejs_compat_v2 (or nodejs_compat + compatibility_date > 2024-09-23) since I want to use the Browser rendering API.
4 replies