问题描述
复现步骤
[复现问题的步骤]
- 打开HBuilder
- 启动云打包
- 等待终端信息
我的项目地址 https://github.com/hfut-soft-ware/hfut-space-app
预期结果
应该打包成功的
实际结果
[HBuilder] 18:08:26.892 项目 'hfut-space-app' 开始编译...
[HBuilder] 18:08:28.467 编译器版本:3.6.1(vue3)
[HBuilder] 18:08:28.470 正在编译中...
[HBuilder] 18:08:30.612 uni-app 有新版本发布,请执行 `npx @dcloudio/uvm alpha` 更新,更新日志详见:https://update.dcloud.net.cn/hbuilderx/changelog/3.7.1.20230210-alpha.html
[HBuilder] 18:08:30.622 vite v2.9.15 building for production...
[HBuilder] 18:08:34.800 'looseToNumber' is not exported by node_modules/.pnpm/@vue+shared@3.2.37/node_modules/@vue/shared/dist/shared.esm-bundler.js, imported by node_modules/.pnpm/@vue+runtime-core@3.2.47/node_modules/@vue/runtime-core/dist/runtime-core.esm-bundler.js
[HBuilder] 18:08:34.800 at ../node_modules/.pnpm/@vue+runtime-core@3.2.47/node_modules/@vue/runtime-core/dist/runtime-core.esm-bundler.js:3:105
[HBuilder] 18:08:34.806 1: import { pauseTracking, resetTracking, isRef, toRaw, getCurrentScope, isShallow as isShallow$1, isReactive, ReactiveEffect, ref, shallowReadonly, track, reactive, shallowReactive, trigger, isProxy, proxyRefs, markRaw, EffectScope, computed as computed$1, isReadonly } from '@vue/reactivity';
[HBuilder] 18:08:34.815 2: export { EffectScope, ReactiveEffect, customRef, effect, effectScope, getCurrentScope, isProxy, isReactive, isReadonly, isRef, isShallow, markRaw, onScopeDispose, proxyRefs, reactive, readonly, ref, shallowReactive, shallowReadonly, shallowRef, stop, toRaw, toRef, toRefs, triggerRef, unref } from '@vue/reactivity';
[HBuilder] 18:08:34.822 3: import { isString, isFunction, isPromise, isArray, NOOP, getGlobalThis, extend, EMPTY_OBJ, toHandlerKey, looseToNumber, hyphenate, camelize, isObject, isOn, hasOwn, isModelListener, toNumber, hasChanged, remove, isSet, isMap, isPlainObject, invokeArrayFns, isRegExp, isBuiltInDirective, capitalize, isGloballyWhitelisted, def, isReservedProp, EMPTY_ARR, toRawType, makeMap, NO, normalizeClass, normalizeStyle } from '@vue/shared';
[HBuilder] 18:08:34.831 ^
[HBuilder] 18:08:34.836 4: export { camelize, capitalize, normalizeClass, normalizeProps, normalizeStyle, toDisplayString, toHandlerKey } from '@vue/shared';
[HBuilder] 18:08:34.837 error during build:
[HBuilder] 18:08:34.843 Error: 'looseToNumber' is not exported by node_modules/.pnpm/@vue+shared@3.2.37/node_modules/@vue/shared/dist/shared.esm-bundler.js, imported by node_modules/.pnpm/@vue+runtime-core@3.2.47/node_modules/@vue/runtime-core/dist/runtime-core.esm-bundler.js
[HBuilder] 18:08:34.849 at error (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:198:30)
[HBuilder] 18:08:34.855 at Module.error (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:12543:16)
[HBuilder] 18:08:34.856 at Module.traceVariable (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:12902:29)
[HBuilder] 18:08:34.862 at ModuleScope.findVariable (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:11554:39)
[HBuilder] 18:08:34.863 at FunctionScope.findVariable (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:6486:38)
[HBuilder] 18:08:34.869 at ChildScope.findVariable (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:6486:38)
[HBuilder] 18:08:34.876 at TrackingScope.findVariable (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:6486:38)
[HBuilder] 18:08:34.883 at BlockScope.findVariable (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:6486:38)
[HBuilder] 18:08:34.891 at TrackingScope.findVariable (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:6486:38)
[HBuilder] 18:08:34.898 at BlockScope.findVariable (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:6486:38)
[HBuilder] 18:08:34.904 at Identifier.bind (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:7553:40)
[HBuilder] 18:08:34.905 at CallExpression.bind (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:5379:73)
[HBuilder] 18:08:34.911 at CallExpression.bind (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:9049:15)
[HBuilder] 18:08:34.917 at AssignmentExpression.bind (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:5383:23)
[HBuilder] 18:08:34.921 at ExpressionStatement.bind (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:5383:23)
[HBuilder] 18:08:34.927 at BlockStatement.bind (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:5379:73)
[HBuilder] 18:08:34.933 at IfStatement.bind (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:5383:23)
[HBuilder] 18:08:34.937 at BlockStatement.bind (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:5379:73)
[HBuilder] 18:08:34.943 at IfStatement.bind (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:5383:23)
[HBuilder] 18:08:34.949 at BlockStatement.bind (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:5379:73)
[HBuilder] 18:08:34.957 at FunctionDeclaration.bind (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:5383:23)
[HBuilder] 18:08:34.963 at Program.bind (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:5379:73)
[HBuilder] 18:08:34.970 at Module.bindReferences (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:12539:18)
[HBuilder] 18:08:34.978 at Graph.sortModules (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:23108:20)
[HBuilder] 18:08:34.984 at Graph.build (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:22986:14)
[HBuilder] 18:08:34.990 at async D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:23680:13
[HBuilder] 18:08:34.996 at async catchUnfinishedHookActions (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:23162:20)
[HBuilder] 18:08:35.006 at async rollupInternal (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\rollup@2.77.3\node_modules\rollup\dist\shared\rollup.js:23677:5)
[HBuilder] 18:08:35.011 at async doBuild (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\vite@2.9.15_sass@1.56.1\node_modules\vite\dist\node\chunks\dep-689425f3.js:41710:24)
[HBuilder] 18:08:35.021 at async build (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\vite@2.9.15_sass@1.56.1\node_modules\vite\dist\node\chunks\dep-689425f3.js:41552:16)
[HBuilder] 18:08:35.021 at async buildApp (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\@dcloudio+vite-plugin-uni@3.0.0-alpha-3060120220907002_vite@2.9.15+vue@3.2.47\node_modules\@dcloudio\vite-plugin-uni\dist\cli\build.js:94:24)
[HBuilder] 18:08:35.028 at async CAC.runBuild (D:\Dev\hfut\hfut-space-app\node_modules\.pnpm\@dcloudio+vite-plugin-uni@3.0.0-alpha-3060120220907002_vite@2.9.15+vue@3.2.47\node_modules\@dcloudio\vite-plugin-uni\dist\cli\action.js:80:9)
7条答案
按热度按时间pieyvz9o1#
错误提示又变了
kmb7vmvb2#
我也遇到相同的问题了
vfwfrxfs3#
使用的是 HX 3.6.1 ?之前使用云打包功能是正常的,然后突然出现这个情况了?在 本地运行/制作本地打包资源 等是否正常?
tp5buhyn4#
使用的是 HX 3.6.1 ?之前使用云打包功能是正常的,然后突然出现这个情况了?在 本地运行/制作本地打包资源 等是否正常?
3.6.18,之前没试过打包,这次就是想尝试一下app是否能打包成功
f5emj3cl5#
从你给的信息中可以看到使用的是 HX 3.6.1 版本打包的,是 cli 项目?升级一下依赖再试试,使用 yarn 安装
wnavrhmk6#
升级到最新的3.0.0-alpha-3080520230612002,也出现了这个问题:
Uncaught SyntaxError: The requested module '/node_modules/@vue/shared/dist/shared.esm-bundler.js' does not provide an export named 'looseToNumber' (at vue.runtime.esm.js:1:204)
alen0pnh7#
升级到最新的3.0.0-alpha-3080520230612002,也出现了这个问题:
Uncaught SyntaxError: The requested module '/node_modules/@vue/shared/dist/shared.esm-bundler.js' does not provide an export named 'looseToNumber' (at vue.runtime.esm.js:1:204)
vue 版本是多少?