Skip to content

Conversation

@ajitzero
Copy link
Contributor

@ajitzero ajitzero commented Aug 18, 2023

  • Pinned Node version to 18. Netlify supports .nvmrc files automatically, so this works for now. For other providers, we would need to set NODE_VERSION=18 as an environment variable.
  • Updated Astro to v2.x because specific other libraries like astro-compress are no longer available via pnpm < v2, and upgrading them requires Astro itself to be upgraded.
  • After that, some other deps also needed to be upgraded manually:
  • Replace lock file from v5.4 to v6.

Fixes #51

@netlify
Copy link

netlify bot commented Aug 18, 2023

Deploy Preview for charming-faun-72b6b3 ready!

Name Link
🔨 Latest commit 9e04049
🔍 Latest deploy log https://app.netlify.com/sites/charming-faun-72b6b3/deploys/64dfc0e0daec75000893f122
😎 Deploy Preview https://deploy-preview-52--charming-faun-72b6b3.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@ajitzero
Copy link
Contributor Author

Netlify build passed after picking up the correct Node version in Line 18. No need to add environment variables separately.

@santoshyadavdev Please check the deployed URL in case something is broken post-dependency upgrade, like the MDX output structure or image (which we don't seem to have in the project currently.)

"@astrojs/image": "^0.11.6",
"@astrojs/mdx": "^0.11.6",
"@astrojs/image": "^0.17.3",
"@astrojs/mdx": "~0.19.6",
Copy link
Contributor Author

@ajitzero ajitzero Aug 18, 2023

Choose a reason for hiding this comment

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

I have intentionally used ~0.19.6 (include patches) instead of ^0.19.6 (hard limit) to avoid potential conflicts. At the moment, there is no difference, and both will work. You may use ^ instead if you prefer that to be more strict.

@ajitzero
Copy link
Contributor Author

Output of pnpm install:

$ pnpm install
 WARN  deprecated [email protected]: Modern JS already guarantees Array#sort() is a stable sort, so this library is deprecated. See the compatibility table on MDN: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort#browser_compatibility
Already up to date
Progress: resolved 661, reused 617, downloaded 0, added 0, done
 WARN  Issues with peer dependencies found
.
└─┬ astro-layouts 0.0.6
  └── ✕ unmet peer astro@^1.6.7: found 2.10.11

I couldn't find a proper reference of how and where astro-layouts are being used, but this is not causing any further build issues and I can preview it locally as well as can be seen in the Netlify URL: https://deploy-preview-52--charming-faun-72b6b3.netlify.app/

@santoshyadavdev
Copy link
Owner

Awesome thank you, I can see the build succeeded.

@santoshyadavdev santoshyadavdev merged commit 1b8d2c9 into santoshyadavdev:main Aug 18, 2023
@ajitzero ajitzero deleted the fix/build branch August 18, 2023 19:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug(ci): Build issue with pnpm v8 due to incompatible lock file

2 participants