Skip to content
This repository has been archived by the owner on Jun 26, 2024. It is now read-only.

打包成安装包错误,下载不来winCodeSign #26

Closed
yoke1990 opened this issue Sep 4, 2017 · 17 comments
Closed

打包成安装包错误,下载不来winCodeSign #26

yoke1990 opened this issue Sep 4, 2017 · 17 comments

Comments

@yoke1990
Copy link

yoke1990 commented Sep 4, 2017

程序已经生成好了,就是自动打包这个出错了
这个应该是win签名的包winCodeSign,下载不了。

electron-builder 19.27.3
No native production dependencies
Packaging for win32 ia32 using electron 1.6.11 to ..\release\win-ia32-unpacked
⚠️ Application icon is not set, default Electron icon will be used
Downloading winCodeSign-1.9.0, please wait
⚠️ Cannot download winCodeSign, attempt #1: Error: Request timed out
Error: connect ETIMEDOUT 54.231.40.3:443
at Object._errnoException (util.js:1041:11)
at _exceptionWithHostPort (util.js:1064:20)
at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1153:14)
From previous event:
at Promise.longStackTracesCaptureStackTrace [as _captureStackTrace] (C:\Users\Yoke\weweChat\node_modules_bluebird@3.5.0@bluebird\js\release\debuggability.js:397:19)
at new PromiseSpawn (C:\Users\Yoke\weweChat\node_modules_bluebird@3.5.0@bluebird\js\release\generators.js:43:17)
at C:\Users\Yoke\weweChat\node_modules_bluebird@3.5.0@bluebird\js\release\generators.js:197:21
at NodeHttpExecutor.download (C:\Users\Yoke\weweChat\node_modules_builder-util@1.0.1@builder-util\out\nodeHttpExecutor.js:159:11)
at Timeout._onTimeout (C:\Users\Yoke\weweChat\node_modules_builder-util@1.0.1@builder-util\src\binDownload.ts:85:39)
at ontimeout (timers.js:469:11)
at tryOnTimeout (timers.js:304:5)
at Timer.listOnTimeout (timers.js:264:5)
npm ERR! code ELIFECYCLE
npm ERR! errno 4294967295
npm ERR! wewechat@1.1.0 package-win32: npm run build && build --win --ia32 --projectDir ./dist
npm ERR! Exit status 4294967295
npm ERR!
npm ERR! Failed at the wewechat@1.1.0 package-win32 script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Yoke\AppData\Roaming\npm-cache_logs\2017-09-04T09_56_53_132Z-debug.log

@trazyn
Copy link
Owner

trazyn commented Sep 4, 2017

国内老实用cnpm吧 国内网络因为众所周知的原因是无法访问一些外网的

@yoke1990
Copy link
Author

yoke1990 commented Sep 4, 2017

cnpm 也不行/(ㄒoㄒ)/~~

@trazyn
Copy link
Owner

trazyn commented Sep 4, 2017

多试几次,或者挂ss或者未批恩,fq是国内程序员的必备技能之一

@yoke1990
Copy link
Author

yoke1990 commented Sep 4, 2017

https://cnpmjs.org
https://npm.taobao.org
进入网站直接搜包,也搜不到winCodeSign
npm源我切换过了,cnpm也试过

@trazyn
Copy link
Owner

trazyn commented Sep 4, 2017

这个是electron-builder的依赖,网络问题可以参考科学上网系列

@trazyn trazyn closed this as completed Sep 4, 2017
@yoke1990
Copy link
Author

yoke1990 commented Sep 4, 2017

我查下它依赖看下情况。

@zzhgithub
Copy link

手动下载吧.大兄弟 — https://github.com/electron-userland/electron-builder-binaries/releases/tag/winCodeSign-1.9.0

@baochunliang
Copy link

@zzhgithub 请问手动下载后,放哪里呢。

@zzhgithub
Copy link

zzhgithub commented Sep 15, 2017

macOS: ~/Library/Caches/electron-builder
Linux: ~/.cache/electron-builder
windows: %LOCALAPPDATA%\electron-builder\cache

@baochunliang

我也查别的地方electron-userland/electron-builder#1859 (comment)
(PS: 没事可以 支持一下我的博客哦~~http://zzhgithub.github.io/)

@songlingxi
Copy link

songlingxi commented Sep 29, 2017

@zzhgithub @baochunliang 你们好, 我在 %LOCALAPPDATA%\electron-builder\cache 下新建了 winCodeSign 文件夹, 并将7z中的文件复制进去. 结果打包时还是会去下载... 请问这个怎么破?

@trazyn
Copy link
Owner

trazyn commented Sep 29, 2017

换个好点的网络就能直接安装了,没办法近期狮鹫大各种网络问题

@songlingxi
Copy link

@trazyn 已经尝试过科学上网的方法了 (/ □ )

@trazyn
Copy link
Owner

trazyn commented Sep 29, 2017

我每次都能下载成功没碰到过😅

@yanjingenious
Copy link

就像楼上说的,多试几次就好了,你还可以看看package.json里的配置https://github.com/electron-userland/electron-packager/blob/master/docs/api.md#options
上面文档中有个download的配置具体可以试试

@1c7
Copy link

1c7 commented May 10, 2020

方法2:

直接给命令行设置代理

set http_proxy=http://127.0.0.1:2802
set https_proxy=http://127.0.0.1:2802

(windows 本地在 2802 端口跑了代理)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants