Versioning information could not be retrieved from the NuGet package repository. Please try again la

 

NuGet Package Manager扩展遇到:

Versioning information could not be retrieved from the NuGet package repository. Please try again later.

 

修改

C:\Users\用户名\.vscode\extensions\jmrog.vscode-nuget-package-manager-1.1.6\out\src\actions\add-methods>fetchPackageVersions.js

文件: 在:(`${versionsUrl}${selectedPackageName}/index.json这段,selectedPackageName后面增加.toLowerCase():

(`${versionsUrl}${selectedPackageName.toLowerCase()}/index.json

 

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const vscode = require("vscode");
const node_fetch_1 = require("node-fetch");
const shared_1 = require("../shared");
const constants_1 = require("../../constants");
const utils_1 = require("../../utils");
function fetchPackageVersions(selectedPackageName, versionsUrl = constants_1.NUGET_VERSIONS_URL) {
    if (!selectedPackageName) {
        // User has canceled the process.
        return Promise.reject(constants_1.CANCEL);
    }
    vscode.window.setStatusBarMessage('Loading package versions...');
    return new Promise((resolve) => {
        node_fetch_1.default(`${versionsUrl}${selectedPackageName.toLowerCase()}/index.json`, utils_1.getFetchOptions(vscode.workspace.getConfiguration('http')))
            .then((response) => {
            shared_1.clearStatusBar();
            resolve({ response, selectedPackageName });
        });
    });
}
exports.default = fetchPackageVersions;
//# sourceMappingURL=fetchPackageVersions.js.map

--

 重启vscode问题解决!

上一篇:Linux查看硬件信息命令大全


下一篇:MySQL找出锁等待