oleeskild / digitalgarden

261 stars 147 forks source link

Deploy errors when changing favicon #249

Open ChristinaHyh opened 4 months ago

ChristinaHyh commented 4 months ago

It seems that the template 1.60 has some problems when changing favicon in my Vault. The deploy log is as follows, thank you for your kind help.

11:18:48 PM: [11ty] Problem writing Eleventy templates: (more in DEBUG output) 11:18:48 PM: [11ty] 1. Having trouble writing to "dist/index.html" from "./src/site/notes/Sapere Aude/Wiki TARDIS.md" (via EleventyTemplateError) 11:18:48 PM: [11ty] 2. (./src/site/_includes/layouts/index.njk) 11:18:48 PM: [11ty] Template render error: (/opt/build/repo/src/site/_includes/components/pageheader.njk) 11:18:48 PM: [11ty] EleventyShortcodeError: Error with Nunjucks shortcode favicons (via Template render error) 11:18:48 PM: [11ty] 3. Expected number between 1 and 100000 for density but received 0.5760000000000001 of type number (via Template render error) 11:18:48 PM: [11ty] 11:18:48 PM: [11ty] Original error stack trace: Error: Expected number between 1 and 100000 for density but received 0.5760000000000001 of type number 11:18:48 PM: [11ty] at Object.invalidParameterError (/opt/build/repo/node_modules/eleventy-plugin-gen-favicons/node_modules/sharp/lib/is.js:124:10) 11:18:48 PM: [11ty] at Sharp._createInputDescriptor (/opt/build/repo/node_modules/eleventy-plugin-gen-favicons/node_modules/sharp/lib/input.js:92:18) 11:18:48 PM: [11ty] at new Sharp (/opt/build/repo/node_modules/eleventy-plugin-gen-favicons/node_modules/sharp/lib/constructor.js:341:29) 11:18:48 PM: [11ty] at Sharp (/opt/build/repo/node_modules/eleventy-plugin-gen-favicons/node_modules/sharp/lib/constructor.js:169:12) 11:18:48 PM: [11ty] at resizedSharp (/opt/build/repo/node_modules/eleventy-plugin-gen-favicons/favicon-gen.js:34:10) 11:18:48 PM: [11ty] at /opt/build/repo/node_modules/eleventy-plugin-gen-favicons/favicon-gen.js:41:33 11:18:48 PM: [11ty] at Array.map () 11:18:48 PM: [11ty] at icoBuf (/opt/build/repo/node_modules/eleventy-plugin-gen-favicons/favicon-gen.js:41:20) 11:18:48 PM: [11ty] at module.exports (/opt/build/repo/node_modules/eleventy-plugin-gen-favicons/favicon-gen.js:92:7) 11:18:48 PM: [11ty] at async Object. (/opt/build/repo/node_modules/eleventy-plugin-gen-favicons/index.js:25:28) 11:18:48 PM: [11ty] Benchmark 230ms 21% 1× (Data) ./src/site/_data/dynamics.js 11:18:48 PM: [11ty] Copied 120 files / Wrote 0 files in 0.66 seconds (v2.0.1) 11:18:51 PM: ERROR: "build:eleventy" exited with 1. 11:18:51 PM: ​ 11:18:51 PM: "build.command" failed
11:18:51 PM: ──────────────────────────────────────────────────────────────── 11:18:51 PM: ​ 11:18:51 PM: Error message 11:18:51 PM: Command failed with exit code 1: npm install && npm run build 11:18:51 PM: ​ 11:18:51 PM: Error location 11:18:51 PM: In build.command from netlify.toml: 11:18:51 PM: npm install && npm run build 11:18:51 PM: ​ 11:18:51 PM: Resolved config 11:18:51 PM: build: 11:18:51 PM: command: npm install && npm run build 11:18:51 PM: commandOrigin: config 11:18:51 PM: publish: /opt/build/repo/dist 11:18:51 PM: publishOrigin: config 11:18:51 PM: redirects: 11:18:51 PM: - from: /api/* status: 200 to: /.netlify/functions/:splat

anantshri commented 4 months ago

check https://github.com/oleeskild/digitalgarden/issues/161

ChristinaHyh commented 4 months ago

check #161 

Thank you. But my favicon is square, and it still can't work.

ChristinaHyh commented 4 months ago

I think I know the reason why deploy failed. I changed the favicon size from 2000 2000 to 600 600 and it worked!