Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Version 2.7.3 introduced some rollup problems #752

Open
Boardtale opened this issue May 19, 2024 · 0 comments
Open

Version 2.7.3 introduced some rollup problems #752

Boardtale opened this issue May 19, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@Boardtale
Copy link

Boardtale commented May 19, 2024

Expected Behavior

Ability to vue-tsc project that included "@amplitude/analytics-browser": "2.7.3"

Current Behavior

Failing when building on pipelines. Locally it works. Local env: Windows, pipelines: Linux

> vue-tsc --noEmit -p tsconfig.vitest.json --composite false

/home/vsts/work/1/s/packages/ui/node_modules/rollup/dist/native.js:59
		throw new Error(
		      ^

Error: Cannot find module @rollup/rollup-linux-x64-gnu. npm has a bug related to optional dependencies (https://github.com/npm/cli/issues/4828). Please try `npm i` again after removing both package-lock.json and node_modules directory.
    at requireWithFriendlyError (/home/vsts/work/1/s/packages/ui/node_modules/rollup/dist/native.js:59:9)
    at Object.<anonymous> (/home/vsts/work/1/s/packages/ui/node_modules/rollup/dist/native.js:68:76)
    ... 3 lines matching cause stack trace ...
    at Module._load (node:internal/modules/cjs/loader:1024:12)
    at cjsLoader (node:internal/modules/esm/translators:348:17)
    at ModuleWrap.<anonymous> (node:internal/modules/esm/translators:297:7)
    at ModuleJob.run (node:internal/modules/esm/module_job:222:25)
    at async ModuleLoader.import (node:internal/modules/esm/loader:316:24) {
  [cause]: Error: Cannot find module '@rollup/rollup-linux-x64-gnu'
  Require stack:
  - /home/vsts/work/1/s/packages/ui/node_modules/rollup/dist/native.js
      at Module._resolveFilename (node:internal/modules/cjs/loader:1145:15)
      at Module._load (node:internal/modules/cjs/loader:986:27)
      at Module.require (node:internal/modules/cjs/loader:1233:19)
      at require (node:internal/modules/helpers:179:18)
      at requireWithFriendlyError (/home/vsts/work/1/s/packages/ui/node_modules/rollup/dist/native.js:41:10)
      at Object.<anonymous> (/home/vsts/work/1/s/packages/ui/node_modules/rollup/dist/native.js:68:76)
      at Module._compile (node:internal/modules/cjs/loader:1358:14)
      at Module._extensions..js (node:internal/modules/cjs/loader:1416:10)
      at Module.load (node:internal/modules/cjs/loader:1208:32)
      at Module._load (node:internal/modules/cjs/loader:1024:12) {
    code: 'MODULE_NOT_FOUND',
    requireStack: [
      '/home/vsts/work/1/s/packages/ui/node_modules/rollup/dist/native.js'
    ]
  }
}

Node.js v20.13.1
ERROR: "build-only" exited with 1.

I get it this might be related to some other updates that 2.7.3 included - upgrading other libraries. But it introduced problems unfortunatly. Would appreciate any help here.
2.7.2 works fine, but wanted to upgrade this lib

Steps to Reproduce

  1. setup linux machine (I am using ADO pipelines: ubuntu-latest
  2. Run: vue-tsc --noEmit -p tsconfig.vitest.json --composite false

Environment

  • JS SDK Version: Node 20 + TS on Vue3
  • Installation Method: NPM
  • Browser and Version: n/a
@Boardtale Boardtale added the bug Something isn't working label May 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant