@Dan_Woolf Version 6.0.2 (Build 5) still has the same issue as PG-2034, at least on NPM feeds, possibly others.
Posts made by forcenet_4316
-
RE: System.InvalidCastException: Unable to cast object of type 'Inedo.ProGet.Feeds.Npm.NpmFeed' to type 'Inedo.ProGet.IRepackageFeed'
-
System.InvalidCastException: Unable to cast object of type 'Inedo.ProGet.Feeds.Npm.NpmFeed' to type 'Inedo.ProGet.IRepackageFeed'
Having upgraded from Proget 5.3 to 6.0.1, a previously working script we have used many times on the promotions API is now failing when promoting packages on an NPM feed.
Issue #1: The 'ToFeed' param is now required in the JSON. Previously you could omit this if the feed was configured to have a Promote To Feed setting configured.
Issue #2: Calling the promotion API always returns the following error.
Unhandled exception processing http://proget.internal/api/promotions/promote
System.InvalidCastException: Unable to cast object of type 'Inedo.ProGet.Feeds.Npm.NpmFeed' to type 'Inedo.ProGet.IRepackageFeed'.
at Inedo.ProGet.WebApplication.SimpleHandlers.Api.PackagePromotion.PromotePackageApiHandler.ProcessRequestAsync(HttpContext context, LoggedResponseStream output, WebApiContext apiContext) in C:\Users\builds\AppData\Local\Temp\InedoAgent\BuildMaster\192.168.44.60\Temp_E155545\Src\ProGet.WebApplication\SimpleHandlers\Api\PackagePromotion\PackagePromotionApiHandler.cs:line 98
at Inedo.ProGet.WebApplication.SimpleHandlers.Api.ProGetApiKeySecuredHandler.ProcessRequestInternalAsync(HttpContext context, LoggedResponseStream output, WrappedApiKey apiKey) in C:\Users\builds\AppData\Local\Temp\InedoAgent\BuildMaster\192.168.44.60\Temp_E155545\Src\ProGet.WebApplication\SimpleHandlers\Api\ProGetApiKeySecuredHandler.cs:line 45
at Inedo.Web.Handlers.Api.ApiKeySecuredHandler.ProcessRequestInternalAsync(HttpContext context)
at Inedo.Web.Handlers.Api.StandardApiHandler.ProcessRequestAsync(HttpContext context) -
RE: Error promoting maven package
Thanks @atripp. If proget v6 becomes the recommended stable version then we'll upgrade to it, otherwise we'll stay with whatever the current release version is.
-
RE: Error promoting maven package
Here are steps to reproduce even when the artifact is provably not in the feed.
-
In the approved feed I go to the package and delete it.
-
The response is "Unexpected Error" however if I search again for the package I can see that it has been deleted. (BTW: The error is " An error occurred in the web application: Object reference not set to an instance of an object." at Inedo.ProGet.Feeds.Maven.MavenFeed.Inedo.ProGet.Feeds.IBrowsablePackageFeed.ListPackageVersionsAsync(CommonPackageId id) in C:\Users\builds\AppData\Local\Temp\InedoAgent\BuildMaster\192.168.44.60\Temp_E146812\Src\ProGetCoreEx\Feeds\Maven\MavenFeed.cs:line 663 )
-
Then I go back to the unapproved feed and promote the package, the result is the same error message as in my original post, even though the artifact is clearly not in the approved feed because I deleted it.
-
-
RE: Error promoting maven package
@forcenet_4316 sorry I forgot to mention. This is ProGet Basic Version 5.3.38 (Build 4) running on linux/docker.
-
Error promoting maven package
Hi,
I'm getting the following error when I attempt to promote a maven package. Some package promotions seem to work but others don't. Can you recommend any steps to fix it please?
An error occurred promoting the package: 2627
14
1MavenArtifacts_CreateOrUpdateArtifact
90`Violation of PRIMARY KEY constraint 'PK__MavenArtifactFiles'. Cannot insert duplicate key in object 'dbo.MavenArtifactFiles'. The duplicate key value is (1603, 4.5.2-1, .jar).