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

Bad lodash.clonedeep in @stacks/transactions 7.0.2 #1782

Open
dantrevino opened this issue Jan 7, 2025 · 0 comments
Open

Bad lodash.clonedeep in @stacks/transactions 7.0.2 #1782

dantrevino opened this issue Jan 7, 2025 · 0 comments
Labels
bug Unwanted or unintended logic causing harm

Comments

@dantrevino
Copy link
Contributor

What version of Stacks.js are you using?

"@stacks/transactions": "^7.0.2",

Describe the bug

Bad lodash import in @stacks/transactions. See partial build log below.

How to reproduce

import @stacks/transactions 7.0.2

Expected behavior

looks like part of a deprecated function. not sure.

Additional context

Build error on Netlify using Node v20. See partial build error below.

5:54:03 PM: x Build failed in 5.12s
5:54:03 PM: node_modules/@stacks/transactions/dist/esm/utils.js (7:7): "default" is not exported by "node_modules/lodash.clonedeep/index.js", imported by "node_modules/@stacks/transactions/dist/esm/utils.js".
5:54:03 PM: file: /opt/build/repo/node_modules/@stacks/transactions/dist/esm/utils.js:7:7
5:54:03 PM: 
5:54:03 PM: 5: import { bytesToHex, concatArray, concatBytes, utf8ToBytes } from '@stacks/common';
5:54:03 PM: 6: import { c32addressDecode } from 'c32check';
5:54:03 PM: 7: import lodashCloneDeep from 'lodash.clonedeep';
5:54:03 PM:           ^
5:54:03 PM: 8: import { deserializeCV, serializeCV } from './clarity';
5:54:03 PM: 9: export { verify as verifySignature } from '@noble/secp256k1';
5:54:03 PM: 
5:54:03 PM:     at getRollupError (file:///opt/build/repo/node_modules/@quasar/app-vite/node_modules/rollup/dist/es/shared/parseAst.js:396:41)
5:54:03 PM:     at error (file:///opt/build/repo/node_modules/@quasar/app-vite/node_modules/rollup/dist/es/shared/parseAst.js:392:42)
5:54:03 PM:     at Module.error (file:///opt/build/repo/node_modules/@quasar/app-vite/node_modules/rollup/dist/es/shared/node-entry.js:15710:16)
5:54:03 PM:     at Module.traceVariable (file:///opt/build/repo/node_modules/@quasar/app-vite/node_modules/rollup/dist/es/shared/node-entry.js:16159:29)
5:54:03 PM:     at ModuleScope.findVariable (file:///opt/build/repo/node_modules/@quasar/app-vite/node_modules/rollup/dist/es/shared/node-entry.js:13886:39)
5:54:03 PM:     at FunctionScope.findVariable (file:///opt/build/repo/node_modules/@quasar/app-vite/node_modules/rollup/dist/es/shared/node-entry.js:5305:38)
5:54:03 PM:     at FunctionBodyScope.findVariable (file:///opt/build/repo/node_modules/@quasar/app-vite/node_modules/rollup/dist/es/shared/node-entry.js:5305:38)
5:54:03 PM:     at Identifier.bind (file:///opt/build/repo/node_modules/@quasar/app-vite/node_modules/rollup/dist/es/shared/node-entry.js:5088:40)
5:54:03 PM:     at CallExpression.bind (file:///opt/build/repo/node_modules/@quasar/app-vite/node_modules/rollup/dist/es/shared/node-entry.js:2675:23)
5:54:03 PM:     at CallExpression.bind (file:///opt/build/repo/node_modules/@quasar/app-vite/node_modules/rollup/dist/es/shared/node-entry.js:11312:15) {
5:54:03 PM:   binding: 'default',
5:54:03 PM:   code: 'MISSING_EXPORT',
5:54:03 PM:   exporter: '/opt/build/repo/node_modules/lodash.clonedeep/index.js',
5:54:03 PM:   id: '/opt/build/repo/node_modules/@stacks/transactions/dist/esm/utils.js',
5:54:03 PM:   url: 'https://rollupjs.org/troubleshooting/#error-name-is-not-exported-by-module',
5:54:03 PM:   pos: 329,
5:54:03 PM:   loc: {
5:54:03 PM:     column: 7,
5:54:03 PM:     file: '/opt/build/repo/node_modules/@stacks/transactions/dist/esm/utils.js',
5:54:03 PM:     line: 7
5:54:03 PM:   },
5:54:03 PM:   frame: "5: import { bytesToHex, concatArray, concatBytes, utf8ToBytes } from '@stacks/common';\n" +
5:54:03 PM:     "6: import { c32addressDecode } from 'c32check';\n" +
5:54:03 PM:     "7: import lodashCloneDeep from 'lodash.clonedeep';\n" +
5:54:03 PM:     '          ^\n' +
5:54:03 PM:     "8: import { deserializeCV, serializeCV } from './clarity';\n" +
5:54:03 PM:     "9: export { verify as verifySignature } from '@noble/secp256k1';",
@dantrevino dantrevino added the bug Unwanted or unintended logic causing harm label Jan 7, 2025
@github-project-automation github-project-automation bot moved this to 🆕 New in DevTools Jan 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Unwanted or unintended logic causing harm
Projects
Status: 🆕 New
Development

No branches or pull requests

1 participant