simple2025
0D

vsce package 会卡住怎么办?

  •  
  •   simple2025 · Dec 11, 2023 · 1834 views
    This topic created in 912 days ago, the information mentioned may be changed or developed.
    webpack 5.89.0 compiled successfully in 5082 ms
     DONE  Packaged: /home/vagrant/vcode/xxx-file-split/xxx-file-split-0.0.1.vsix (9 files, 4.72KB)
    

    都运行完命令了,但是现在就是卡住了,怎么办? 有什么办法可以解决吗?

    19 replies    2023-12-11 18:29:52 +08:00
    jazzg62
        1
    jazzg62  
       Dec 11, 2023
    这个情况重试也会出现吗?可能是网络有问题,可以试试在后台手动上传
    NessajCN
        2
    NessajCN  
       Dec 11, 2023
    完成了就行了呀,直接 vsce publish 呗
    simple2025
        3
    simple2025  
    OP
       Dec 11, 2023
    @jazzg62 我是本地打包啊, 不是上传啊
    simple2025
        4
    simple2025  
    OP
       Dec 11, 2023
    @NessajCN 然后终端卡住了,我下面的 `code --install-extension ./*.vsix` 就执行不了,导致我脚本运行不了
    NessajCN
        5
    NessajCN  
       Dec 11, 2023
    @chenqh npm run compile 会卡吗
    jazzg62
        6
    jazzg62  
       Dec 11, 2023
    @chenqh 抱歉,看错了
    simple2025
        7
    simple2025  
    OP
       Dec 11, 2023
    @NessajCN 不卡,很快就结束了,奇怪了
    NessajCN
        8
    NessajCN  
       Dec 11, 2023
    @chenqh 那如果 npx @vscode/vsce package 会卡吗
    simple2025
        9
    simple2025  
    OP
       Dec 11, 2023
    @NessajCN 我没有 npx 只有 npm
    simple2025
        10
    simple2025  
    OP
       Dec 11, 2023
    @NessajCN 会卡,没有报不存在的错,就是卡在那里了
    NessajCN
        11
    NessajCN  
       Dec 11, 2023
    @chenqh npx 是跟着 npm 一起装的
    simple2025
        12
    simple2025  
    OP
       Dec 11, 2023
    @NessajCN

    现在出结果了

    ```

    npm ERR! code ETIMEDOUT
    npm ERR! syscall connect
    npm ERR! errno ETIMEDOUT
    npm ERR! network request to https://registry.npmjs.org/@vscode%2fvsce failed, reason: connect ETIMEDOUT 104.16.2.35:443
    npm ERR! network This is a problem related to network connectivity.
    npm ERR! network In most cases you are behind a proxy or have bad network settings.
    npm ERR! network
    npm ERR! network If you are behind a proxy, please make sure that the
    npm ERR! network 'proxy' config is set properly. See: 'npm help config'

    npm ERR! A complete log of this run can be found in:
    npm ERR! /home/vagrant/.npm/_logs/2023-12-11T09_48_05_225Z-debug.log
    ```

    为什么 package 也要连 npmjs?
    NessajCN
        13
    NessajCN  
       Dec 11, 2023   ❤️ 1
    @chenqh npx 的作用是从远程仓库里下载 vsce 来执行,主要是我想看一下是不是你本机的 vsce 损坏
    现在新的这个报错是 npx 没有正确下载到 @vscode/vsce ,你没连网?
    simple2025
        14
    simple2025  
    OP
       Dec 11, 2023
    @NessajCN 我 vagrant 里面的 vbox 用不了外面的 clash 网就是卡
    simple2025
        15
    simple2025  
    OP
       Dec 11, 2023
    @NessajCN 好像确实是 @vscode/vsce 的问题,我卸载重装试一下
    simple2025
        16
    simple2025  
    OP
       Dec 11, 2023
    @NessajCN 脑子晕了,没想到过这个问题
    simple2025
        17
    simple2025  
    OP
       Dec 11, 2023
    @NessajCN 重装之后现在又卡起来了,郁闷啊
    NessajCN
        18
    NessajCN  
       Dec 11, 2023 via Android
    @chenqh 你可以在工作目录里 npm i @vscode/vsce
    然后 npx vsce package
    simple2025
        19
    simple2025  
    OP
       Dec 11, 2023
    @NessajCN 我试试
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   2587 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 41ms · UTC 16:02 · PVG 00:02 · LAX 09:02 · JFK 12:02
    ♥ Do have faith in what you're doing.