2016-05-24 7 views
1

以前はVisual Studio Team ServicesのTeam ServicesでプライベートNuGetフィードを取得していました。問題は認証されていましたが、私のチームサービスの代替資格情報をリセットして、グローバル設定の内容を消去し、nuget sources addを使用して資格情報を元に戻しました。Visual Studio Team ServicesへのプッシュNuGetフィードは400のBadRequestを返します

これは認証の問題ではないと思います。エラーが変更されました。

私のコマンドライン:

NuGet.exe push BrandPortaCoreDistrib.1.2.4.0.nupkg -Source https://brand.pkgs.visualstudio.com/DefaultCollection/_packaging/Libraries/nuget/v3/index.json -Verbosity detailed 

しかし、私は、画面上でこれを取得する:それに

WARNING: No API Key was provided and no API Key could be found for 'https://brand.pkgs.visualstudio.com/DefaultCollection/_packaging/14e755d8-0994-4b9d-b607-a79928cc4597/nuget/v2/'. To save an API Key for a source use the 'setApiKey' command. 
Pushing BrandPortaCoreDistrib.1.2.4.0.nupkg to 'https://brand.pkgs.visualstudio.com/DefaultCollection/_packaging/14e755d8-0994-4b9d-b607-a79928cc4597/nuget/v2/'... 
    PUT https://brand.pkgs.visualstudio.com/DefaultCollection/_packaging/14e755d8-0994-4b9d-b607-a79928cc4597/nuget/v2/ 
    Unauthorized https://brand.pkgs.visualstudio.com/DefaultCollection/_packaging/14e755d8-0994-4b9d-b607-a79928cc4597/nuget/v2/ 1043ms 
Using credentials from config. UserName: [email protected] 
    PUT https://brand.pkgs.visualstudio.com/DefaultCollection/_packaging/14e755d8-0994-4b9d-b607-a79928cc4597/nuget/v2/ 
    BadRequest https://brand.pkgs.visualstudio.com/DefaultCollection/_packaging/14e755d8-0994-4b9d-b607-a79928cc4597/nuget/v2/ 5054ms 
System.AggregateException: One or more errors occurred. ---> System.Net.Http.HttpRequestException: Response status code does not indicate success: 400 (Bad Request). 
    at NuGet.CommandLine.PushCommand.<ExecuteCommandAsync>d__16.MoveNext() 
    --- End of inner exception stack trace --- 
    at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions) 
    at System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, CancellationToken cancellationToken) 
    at NuGet.CommandLine.Command.Execute() 
    at NuGet.CommandLine.Program.MainCore(String workingDirectory, String[] args) 
---> (Inner Exception #0) System.Net.Http.HttpRequestException: Response status code does not indicate success: 400 (Bad Request). 
    at NuGet.CommandLine.PushCommand.<ExecuteCommandAsync>d__16.MoveNext()<--- 

キーはすべてのことの真ん中にBadRequestあります。その他のステータス情報はありません。エラーは表示されません。

パッケージのバージョンが既にフィードに含まれていません。

私は以前、このプロジェクトからこのnuspecとnupkgsを使ってこのフィードをプッシュしています。なぜなら、今日の世界が私を嫌う理由を知りません。

私はNuGet.exe 3.4.3.855を使用しています。私はTeam Servicesのフィードの所有者です。

奇妙なことに、画面上で吹き飛ばされるのは、v2のURLについてのすべての話ですが、チームサービスのフィードはv3です。あなたのコマンドで

答えて

6

追加「-ApiKey VSTS」:

NuGet.exe push BrandPortaCoreDistrib.1.2.4.0.nupkg -Source https://brand.pkgs.visualstudio.com/DefaultCollection/_packaging/Libraries/nuget/v3/index.json -Verbosity detailed -ApiKey VSTS 
私は自分の資格情報を使用して認証しておりますので、私はそれを必要に応じて、しかも、私は認証のために異なるコードを期待しているだろうとは思いませんでした
+0

エラー。ありがとう、エディ。 –

関連する問題