Welcome to the Inedo Forums! Check out the Forums Guide for help getting started.

If you are experiencing any issues with the forum software, please visit the Contact Form on our website and let us know!

PowerShell connector failing to pull from PowerShell Gallery



  • We have an internal ProGet server we use to host a number of different feeds (PowerShell, NuGet, Chocolatey, Universal Packages, and NPM modules), and at least in the PowerShell case, we have a feed connector that connects to the public PowerShell Gallery. This has historically allowed us to pull third party module dependencies that are hosted in the public gallery through our internal feed.

    Recently we've noticed that many (almost all) third party modules on the public gallery are no longer being pulled in/discovered by the feed connector. As shown in the following image, if I try to look for BetterCredentials, it's only available through the public gallery, but searching for PowerShellGet shows the latest version in both the public gallery and our internal feed:

    FindModuleOutput

    If we look at the web UI for our internal PowerShell feed, we can see that, in fact, the PowerShellGet module is discovered through the connector:

    ConnectorOverlay

    Our ProGet server is hosted on a Windows Server 2012 R2 VM with the latest updates from Microsoft. We also tried standing up a fresh VM with the latest version of ProGet, and after creating an internal PowerShell feed with a feed connector, we saw the same behavior. We have tried recreating our feed connector with no change in behavior.

    At first we thought this might have been something related to the version normalization that occurs in later versions of NuGet (as described
    in issue 3050 for NuGet) because we saw that the connector seemed to work for modules that were SemVer-compliant whereas modules that had 2- and 4-part version numbers weren't found by the connector. However, we have now found some modules that do have SemVer-compliant version numbers and are failing to be found by the connector.

    At this point we are able to workaround this issue by manually adding third party modules to our internal feed through the ProGet web UI, but this obviously diminishes the utility of the feed connector itself. We're not sure what else we can poke around at to try to diagnose this. Any help or guidance would be appreciated, and if there's any other info we can provide, please let us know!

    Thanks!

    Product: ProGet
    Version: 5.1.11


  • inedo-engineer

    Hello Michael,

    Does the feed have a connector for https://www.powershellgallery.com/api/v2? You can check the connectors attached to a feed from the Manage Feed page.

    If the PowerShellGet package was cached from a connector and the connector was subsequently deleted or disconnected from the feed, the package will still show that icon.



  • Hi Ben,

    Yes, the feed's connector is pointed at that URL. The connector has never been deleted, and to the best of our knowledge, it has always maintained a healthy status.

    At the time we were testing, we were seeing modules like cChoco, Plaster, PreferenceVariables, etc. failing to be pulled by the connector. However, at that same time, I tried pulling a module we never had used internally, dbatools, and the connector was able to successfully pull the latest version of that package. I was able to look in the web UI and verify that the remote overlay icon was present for that package.

    We also installed ProGet on a fresh VM, created a connector to the PowerShell Gallery URL listed above, and saw the same behavior. In all cases, simply running Find-Module or Install-Module successfully finds/installs the modules directly from the PSGallery; it's only when we try to do anything through the feed connector do we see things fail.

    We're not sure if there are any other things on our end that we can try to rule out. We've tried looking at then events within ProGet's admin panel, but things seem clean from what we can tell.

    Thanks,
    Michael



  • I can confirm this behavior too the PowerShell Gallery connector only shows it having 397 packages, but there are currently 3,940 unique packages available via powershellgallery.org. I am unable to install modules such as Carbon.

    Image Text



  • Just as an update, we've learned that this is a result of a bug/issue with the PowerShell Gallery. Basically, the PowerShell gallery is currently returning incorrect data for some packages, which causes this to fail.

    This has been reported to Microsoft (PowerShell Gallery), but please upvote or comment on it there so they realize this is an issue: https://github.com/PowerShell/PowerShellGallery/issues/30

    As a workaround, you can look up the latest version of the package on the PowerShell Gallery website and request that specific version from ProGet. Once the package has been downloaded from the connector once, it is cached, and will act as the latest version of the package.



  • Hi Alana,

    Thanks so much for the update and the workaround solution. I'll be sure to upvote the linked issue.

    Best,
    Michael



Inedo Website HomeSupport HomeCode of ConductForums GuideDocumentation