Nuget package restore error on build server

9 posts, 0 answers
  1. Debbie
    Debbie avatar
    8 posts
    Member since:
    Jun 2019

    Posted 12 Sep 2019 Link to this post

     

    so I've followed the instructions here:

    https://docs.telerik.com/devtools/aspnet-ajax/installation/installing-the-telerik-controls-from-nuget-package

      <add key="telerik.com" value="https://nuget.telerik.com/nuget" />

    I've added my credentials in clear text. (note we check in a nuget.config with the solution(needed for other sources and solution configuration)

    locally everything works.

    on the build server we get these errors pulling from telerik source:

    :45 Retrying 'FindPackagesByIdAsyncCore' for source 'https://nuget.telerik.com/nuget/FindPackagesById()?id='Westwind.Utilities'&semVerLevel=2.0.0'. 09:47:45 The input is not a valid Base-64 string as it contains a non-base 64 character, more than two padding characters, or an illegal character among the padding characters.

     

    the build server is using a command line nuget restore command to restore these files

  2. Izabel
    Admin
    Izabel avatar
    4 posts

    Posted 12 Sep 2019 Link to this post

    Hi Debbie,

    Thank you for contacting us.

    The "Westwind.Utilities" package is not served by the Telerik Private Nuget Server (https://nuget.telerik.com/nuget).
    You could restore the above package by adding the Official Nuget Repo as a package source in your NuGet.Config file:

    <add key="nuget.org" value="https://api.nuget.org/v3/index.json" protocolVersion="3" />

    I hope that the proposed solution will fix your issue.

    Regards,
    Izabel
    Progress Telerik
    Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
  3. Debbie
    Debbie avatar
    8 posts
    Member since:
    Jun 2019

    Posted 12 Sep 2019 in reply to Izabel Link to this post

    sorry, I realize my question wasn't clear.

    I added telerik to an existing nuget.config for a working project, it has the main nuget and a few other sources.

    It works locally, but does not work on the build server with that error.

     

  4. Debbie
    Debbie avatar
    8 posts
    Member since:
    Jun 2019

    Posted 12 Sep 2019 in reply to Debbie Link to this post

    Really wish I could edit my own posts.

    I need to know what that error means, and how to fix it.

    my only other option is to remove your nuget source entirely and manually copy the files into our solution.

     

  5. Izabel
    Admin
    Izabel avatar
    4 posts

    Posted 13 Sep 2019 Link to this post

    Hello Debbie,

    From what you described, it seems that on the build server the Official Nuget Repo is missing as a  package source and it's trying to restore the package from the Telerik Nuget Feed.

    Are you sure that the build server is configured properly to use the Official Nuget Repo? Also, is it possible that something is blocking the request to it?

    Regards,

    Izabel
    Progress Telerik
    Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
  6. Debbie
    Debbie avatar
    8 posts
    Member since:
    Jun 2019

    Posted 13 Sep 2019 in reply to Izabel Link to this post

    Izabel - when I removed the telerik package, everything resumed building successfully. It was the addition of the telerik nuget source that caused the issue. Nuget does not allow ordering, it can and will check all sources for a package regardless of if they host it or not. we are not blocking the telerik website, was able to get to the url when I rdp'd into the build server host. application in question is a mixed webforms/mvc .net 4.71 and .netstandard  application, the particular package that triggered this error is a .netstandard class library.

    the nuget.config was configured with the nuget host, other hosts we are using, and the telerik host (using clear text credentials).

  7. Veselin Tsvetanov
    Admin
    Veselin Tsvetanov avatar
    1234 posts

    Posted 17 Sep 2019 Link to this post

    Hello Debbie,

    The observed is rather an unusual behavior of the NuGet package manager. The Westwind.Utilities package is available on the public NuGet feed. The build procedure, however, reports that such package was not found on the Telerik private feed. For some reason, the package manager does not check the public feed for that package. Moreover, the fact that the issue is present only on the build server points to some configuration/environment problems. May I ask you to:

    - Review the following GitHub issue as it discusses a problem as described. Could you try the solution outlined here: https://github.com/NuGet/Home/issues/2239#issuecomment-193208925?

    - Download and install the latest NuGet.exe on the build server machine: https://www.nuget.org/downloads;

    - If the above does not help, may I ask you to send us the NuGet.Config file used on your build server? For privacy reasons, you could freely remove your credentials (usernames and passwords) from that file.

    Regards,
    Veselin Tsvetanov
    Progress Telerik

    Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
  8. Debbie
    Debbie avatar
    8 posts
    Member since:
    Jun 2019

    Posted 17 Sep 2019 in reply to Veselin Tsvetanov Link to this post

    We've removed the telerik nuget package/feed completely from our solution.

    our  build server Is configured correctly, the issue is with the telerik nuget source, and probably related to the .net standard project, as it seems to pull information differently.

    the issue was not just on the build server it affected other users as well, and me once they cleared their nuget cache, they were unable to build as well, even with putting their own credentials in the config file for the telerik feed.

    As stated before, once the telerilk feed is gone, the solution builds correctly.

    It fails because its checking the telerik source First because you can't order nuget feeds, and the telerik source is throwing the error, so it never gets to the main nuget feed.

    If you could tell me what the issue is with the telerik source, and what that error message means it may be possible to fix. 

    our config(redacted)

    <configuration>
        <packageSources>
            <clear/>
            <add key="nuget" value="https://api.nuget.org/v3/index.json" />
            <add key="telerik.com" value="https://nuget.telerik.com/nuget" />
         </packageSources>
          <packageSourceCredentials>
           <telerik.com>
                  <add key="Username" value="username" />
                  <add key="Password" value="password" /> 
            </telerik.com>
         </packageSourceCredentials>
          <config>
          <add key="globalPackagesFolder" value=".\packages" />
        </config>
     </configuration>

     

     

  9. Veselin Tsvetanov
    Admin
    Veselin Tsvetanov avatar
    1234 posts

    Posted 19 Sep 2019 Link to this post

    Hello Debbie,

    Thank you for the additional information and the nuget.config content sent. I was able to reproduce the issue observed when filling in my Password as a clear-text value in the <packageSourceCredentials> section:

    <packageSourceCredentials>
      <telerik.com>
        <add key="Username" value="username" />
        <add key="Password" value="password" /> 
      </telerik.com>
    </packageSourceCredentials>

    The Password key, however, would expect encrypted password for the source. Hence, setting the actual password text would result in the error observed. When using the password in clear text, the ClearTextPassword key should be used instead:

    <packageSourceCredentials>
      <telerik.com>
        <add key="Username" value="username" />
        <add key="ClearTextPassword" value="password" /> 
      </telerik.com>
    </packageSourceCredentials>

    Regards,
    Veselin Tsvetanov
    Progress Telerik

    Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Back to Top