vercel / analytics

Privacy-friendly, real-time traffic insights
https://vercel.com/analytics
Mozilla Public License 2.0
416 stars 24 forks source link

Vercel build failed with Turborepo and multiple apps deployed #117

Closed johannpinson closed 8 months ago

johannpinson commented 8 months ago

Hello,

I got build error from Vercel with a turborepo config:

image

This is the partial repository organization, using npm workspaces combined to turborepo

- package.json (root pkg)
- packages-lock.json (contain the `@vercel/analytics` reference and all deps)
- node_modules/ (the uniq `node_modules` folder for all the workspace)
- apps/
  - web/ (Next 13.5.x)
    - package.json (contain the `@vercel/analytics` pkg, and others monorepo deps, ui, auth...)
  - docs/ (Storybook v7)
    - package.json (storybook deps + packages/ui)
- packages/
  - ui/ (react ui components)
  - ...

In fact, I don't need to add the analytics on the Storybook project, because it uses internally.

So do I need to move the @vercel/analytics package inside the root package.json?

johannpinson commented 8 months ago

The issue seems to come from the Vercel CLI 32.6.0.

Since we noticed a downgrade to the 32.5.6 this morning, it looks to be ok about the build process.

feugy commented 8 months ago

Hello @johannpinson. Thanks for the report, and apologies for the annoyance. You don't have to change anything.

This is indeed a bug of CLI v32.6.0. We're working on a fix for the CLI, and reverted our build chain so you could still deploy your application.

I'll update this issue when the CLI fix will land.

johannpinson commented 8 months ago

Hey @feugy

Thanks for your feedback, I also discuss with the Vercel support who confirm me the revert. The new builds (and even redeploy) work well.

Feel free to close the issue or keep it as reference if needed 😉

feugy commented 8 months ago

Hi! Vercel CLI 32.6.1 has been deployed last Friday with a fix. I'll close this issue, feel free to reopen in case you have a related followup!

johannpinson commented 8 months ago

Hello, Yes I confirm you that all our previous deployments work.

Thanks!