Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error Status 403 #63

Closed
pulla2908 opened this issue Feb 22, 2019 · 7 comments
Closed

error Status 403 #63

pulla2908 opened this issue Feb 22, 2019 · 7 comments

Comments

@pulla2908
Copy link

I recently added this extension from the marketplace and try to use it now in my release pipeline. When running the task I get following error:

2019-02-22T20:45:45.7991997Z ##[section]Starting: Publish $(SYSTEM.ARTIFACTSDIRECTORY)\**\*.appxbundle
2019-02-22T20:45:45.7997017Z ==============================================================================
2019-02-22T20:45:45.7997119Z Task         : Windows Store - Publish
2019-02-22T20:45:45.7997204Z Description  : Publish your app to the Windows Store
2019-02-22T20:45:45.7997268Z Version      : 0.10.25
2019-02-22T20:45:45.7997343Z Author       : Microsoft Corporation
2019-02-22T20:45:45.7997403Z Help         : 
2019-02-22T20:45:45.7997489Z ==============================================================================
2019-02-22T20:45:46.6655027Z 5ccde424-942e-45f5-8d48-98a69ecd4af5 exists true
2019-02-22T20:45:46.6884803Z Authenticating...
2019-02-22T20:45:46.6886532Z Authenticating with server...
2019-02-22T20:45:46.9042429Z Obtaining app information...
2019-02-22T20:45:49.1417293Z Creating submission...
2019-02-22T20:45:49.5290819Z ##[error]Status 403:  CorrelationId: 09e77990-69de-460e-8c8e-9c34b80e96f1
2019-02-22T20:45:49.5357435Z ##[section]Finishing: Publish $(SYSTEM.ARTIFACTSDIRECTORY)\**\*.appxbundle

Any ideas how to start troubleshooting? I was not able to get it working at least once. Right now I can not distinguish if this is a bug or wrong configuration somewhere.

@zurdev
Copy link
Contributor

zurdev commented Feb 23, 2019

Set release variable System.Debug to true and redeploy, it would help with getting more detailed task log.
Check the prerequisites for using the Microsoft Store submission API. Before you can create a submission for a given app using this API, you must first create one submission for the app in Partner Center.

@pulla2908
Copy link
Author

I read the prerequisites and I think I did all. I already had created the app in the dev center. Before I created the bundle local on my machine and uploaded it to the dev center. I have 4 submissions so for. The app is already available through the store. The only special setting is maybe to make it only available via promo code but this should not be related to the submission process I guess. Then I started using this extension.

Note: As the build does not create appxbundle I refer to msixupload in the extension now but same error.

Good idea about debug, I did this now. See output:

##[debug]Evaluating condition for step: 'Publish $(SYSTEM.ARTIFACTSDIRECTORY)\**\*.msixupload'
##[debug]Evaluating: succeeded()
##[debug]Evaluating succeeded:
##[debug]=> True
##[debug]Result: True
##[section]Starting: Publish $(SYSTEM.ARTIFACTSDIRECTORY)\**\*.msixupload
==============================================================================
Task         : Windows Store - Publish
Description  : Publish your app to the Windows Store
Version      : 0.10.25
Author       : Microsoft Corporation
Help         : 
==============================================================================
##[debug]agent.workFolder=D:\a
##[debug]loading inputs and endpoints
##[debug]loading ENDPOINT_AUTH_5ccde424-942e-45f5-8d48-98a69ecd4af5
##[debug]loading ENDPOINT_AUTH_PARAMETER_5ccde424-942e-45f5-8d48-98a69ecd4af5_AUTHENTICATIONTYPE
##[debug]loading ENDPOINT_AUTH_PARAMETER_5ccde424-942e-45f5-8d48-98a69ecd4af5_SERVICEPRINCIPALID
##[debug]loading ENDPOINT_AUTH_PARAMETER_5ccde424-942e-45f5-8d48-98a69ecd4af5_SERVICEPRINCIPALKEY
##[debug]loading ENDPOINT_AUTH_PARAMETER_5ccde424-942e-45f5-8d48-98a69ecd4af5_TENANTID
##[debug]loading ENDPOINT_AUTH_PARAMETER_5ccde424-942e-45f5-8d48-98a69ecd4af5_URL
##[debug]loading ENDPOINT_AUTH_PARAMETER_SYSTEMVSSCONNECTION_ACCESSTOKEN
##[debug]loading ENDPOINT_AUTH_SCHEME_5ccde424-942e-45f5-8d48-98a69ecd4af5
##[debug]loading ENDPOINT_AUTH_SCHEME_SYSTEMVSSCONNECTION
##[debug]loading ENDPOINT_AUTH_SYSTEMVSSCONNECTION
##[debug]loading INPUT_APPNAME
##[debug]loading INPUT_DELETEPACKAGES
##[debug]loading INPUT_FORCE
##[debug]loading INPUT_ISMANDATORYUPDATE
##[debug]loading INPUT_MANDATORYUPDATEDIFFERHOURS
##[debug]loading INPUT_METADATAPATH
##[debug]loading INPUT_METADATAUPDATEMETHOD
##[debug]loading INPUT_NAMETYPE
##[debug]loading INPUT_NUMBEROFPACKAGESTOKEEP
##[debug]loading INPUT_PACKAGEPATH
##[debug]loading INPUT_SERVICEENDPOINT
##[debug]loading INPUT_SKIPPOLLING
##[debug]loading INPUT_UPDATEIMAGES
##[debug]loaded 23
##[debug]serviceEndpoint=5ccde424-942e-45f5-8d48-98a69ecd4af5
5ccde424-942e-45f5-8d48-98a69ecd4af5 exists true
##[debug]5ccde424-942e-45f5-8d48-98a69ecd4af5 exists true
##[debug]force=false
##[debug]metadataUpdateMethod=NoUpdate
##[debug]updateImages=false
##[debug]Agent.WorkFolder=D:\a
##[debug]skipPolling=false
##[debug]deletePackages=false
##[debug]isMandatoryUpdate=false
##[debug]packagePath=D:\a\1\a\**\*.msixupload
##[debug]Agent.ReleaseDirectory=undefined
##[debug]packagePath=D:\a\1\a\**\*.msixupload
##[debug]additionalPackages=null
##[debug]nameType=AppName
##[debug]appName=This is my  App
##[debug]metadataPath=D:\a\1\s
##[debug]App ID: 
##[debug]Endpoint: ***
##[debug]Force delete: false
##[debug]Metadata update type: 0
##[debug]Update images: false
##[debug]Metadata root: D:\a\1\s
##[debug]Packages: D:/a/1/a/AppxPackages/ThisIsMyApp.Store.App_0.2.3.0_x86_x64_ARM_bundle.msixupload
##[debug]skipPolling: false
##[debug]deletePackages: false
##[debug]numberOfPackagesToKeep: null
##[debug]isMandatoryUpdate: false
##[debug]mandatoryUpdateDifferHours: null
Authenticating...
Authenticating with server...
##[debug]Starting request with correlation id: 172c5bf8-0647-41cb-8549-710e6342ab64
##[debug]Finished request with correlation id: 172c5bf8-0647-41cb-8549-710e6342ab64
Obtaining app information...
##[debug]Getting app resource from ID 
##[debug]Starting request with correlation id: bce6a492-07cb-4764-9bf2-08d4aae84550
##[debug]Finished request with correlation id: bce6a492-07cb-4764-9bf2-08d4aae84550
Creating submission...
##[debug]Creating new submission
##[debug]Starting request with correlation id: 74894ab6-38bb-4180-bab1-61b41126fd89
##[debug]Finished request with correlation id: 74894ab6-38bb-4180-bab1-61b41126fd89
##[debug]task result: Failed
##[error]Status 403:  CorrelationId: 56500391-9088-4f02-98ed-eb6303289012
##[debug]Processed: ##vso[task.issue type=error;]Status 403:  CorrelationId: 56500391-9088-4f02-98ed-eb6303289012
##[debug]Processed: ##vso[task.complete result=Failed;]Status 403:  CorrelationId: 56500391-9088-4f02-98ed-eb6303289012
##[section]Finishing: Publish $(SYSTEM.ARTIFACTSDIRECTORY)\**\*.msixupload

@elendil326
Copy link
Contributor

Hi @pulla2908 , I have requested the help of the Store team to get more information on why you are getting a 403, since the error returned by the API doesn't provide a lot of information.

While they look into this, can you help me verifying that your Azure AD application is associated with your partner center account?

The logs show you are able to get an access token with the azure AD application, that means your azure AD application does exist; but the fact that the store is returning 403 when trying to create a submission makes me believe that the application is not correctly associated to the partner center account. Also make sure you assign the Azure AD Application the Manager role under the partner center account.

@elendil326
Copy link
Contributor

elendil326 commented Feb 27, 2019

H

Hi @pulla2908 , I just got the information from the Store team, and they pointed out the following piece in your log:

##[debug]nameType=AppName
##[debug]appName=This is my  App
##[debug]metadataPath=D:\a\1\s
##[debug]App ID:

It looks like there is a white space in the App ID, which is causing some confusion on this function. To unblock yourself, you can clean up this field in the task UI and try again, or you can use the App ID instead of the App Name. You can see your app's Id in the dev center page.

EDIT

Adding an example of the dev center URL overview page with the app id:
AppID: 9WGDNCMFJCH4
Dev Center Url: https://partner.microsoft.com/en-us/dashboard/products/9WGDNCMFJCH4/overview

@pulla2908
Copy link
Author

pulla2908 commented Feb 28, 2019

Hi @elendil326 , thank you for your feedback. It was helpful! I changed now from App Name to App Id. App Id is in my opinion the prefered way anyway because it never changes where as a display name can change over time. By changing from App Name to App Id I could now create a new submission sucessfully. This is the good news. The bad news is that I got a timeout from the task. See output here:

2019-02-28T20:30:52.6373746Z ##[section]Starting: Publish $(SYSTEM.ARTIFACTSDIRECTORY)\**\*.msixupload
2019-02-28T20:30:52.6378151Z ==============================================================================
2019-02-28T20:30:52.6378248Z Task         : Windows Store - Publish
2019-02-28T20:30:52.6378326Z Description  : Publish your app to the Windows Store
2019-02-28T20:30:52.6378757Z Version      : 0.10.25
2019-02-28T20:30:52.6378841Z Author       : Microsoft Corporation
2019-02-28T20:30:52.6378901Z Help         : 
2019-02-28T20:30:52.6378974Z ==============================================================================
2019-02-28T20:30:53.5523715Z 5ccde424-942e-45f5-8d48-98a69ecd4af5 exists true
2019-02-28T20:30:53.5757080Z Authenticating...
2019-02-28T20:30:53.5759454Z Authenticating with server...
2019-02-28T20:30:53.8189666Z Obtaining app information...
2019-02-28T20:30:58.9313783Z Creating submission...
2019-02-28T20:31:16.6700412Z Submission https://developer.microsoft.com/en-us/dashboard/apps/9NTBZK4TNJ72/submissions/1152921505688424277 was created successfully
2019-02-28T20:31:16.6700939Z Updating package delivery options...
2019-02-28T20:31:16.6701609Z Updating submission...
2019-02-28T20:31:23.3167058Z Creating zip file...
2019-02-28T20:31:27.3336985Z Uploading zip file...
2019-02-28T20:31:29.3713506Z Successfully uploaded file!
2019-02-28T20:31:29.3714406Z Committing submission...
2019-02-28T20:31:35.6602564Z Polling submission...
2019-02-28T20:31:41.3408344Z Submission status for "applications/9NTBZK4TNJ72/submissions/1152921505688424277"CommitStarted
2019-02-28T20:36:46.5062176Z Submission status for "applications/9NTBZK4TNJ72/submissions/1152921505688424277"PreProcessing
2019-02-28T20:41:52.4385387Z Submission status for "applications/9NTBZK4TNJ72/submissions/1152921505688424277"PreProcessing
2019-02-28T20:46:58.0011644Z Submission status for "applications/9NTBZK4TNJ72/submissions/1152921505688424277"Certification
2019-02-28T20:52:03.2547845Z Submission status for "applications/9NTBZK4TNJ72/submissions/1152921505688424277"Certification
2019-02-28T20:57:09.3072487Z Submission status for "applications/9NTBZK4TNJ72/submissions/1152921505688424277"Certification
2019-02-28T21:00:38.0003034Z ##[error]The operation was canceled.
2019-02-28T21:00:38.0007672Z ##[section]Finishing: Publish $(SYSTEM.ARTIFACTSDIRECTORY)\**\*.msixupload

If I take a look into the dev center I can see the new submission. The status is right now in verfication. Looks good in my opinion.

Regarding the timeout) I thought it just creates the submission and the task ends. Further steps like verfication are not awaited from the task itself but it seems it waits for it.

Regarding App Name with spaces) The 403 error does not make it clear what is the problem. Can you provide a more meaningful message here?

Update: After a while the status in dev center is now publishing. It seems everything is fine so far with the submission.

Update 04 March: I enabled now skip polling and the task finish succesfull. However, now I don't get feedback if any post processing steps fail or not. It would be very helpful to increase the timeout.

@elendil326
Copy link
Contributor

Hi @pulla2908 ,

Thanks for your feedback and happy things are working now. The timeout you are hitting is configured by VSTS and you can control it through the task UI. Go under the Control Options section, you will see an input text for Timeout. Judging by the logs I would say the current value is 30 minutes. You can increase that value and see how it plays out.

@sivap77
Copy link

sivap77 commented Oct 14, 2021

Hi @elendil326

I am getting 403 error any thoughts?

021-10-14T01:27:45.2237428Z Obtaining app information...
2021-10-14T01:27:45.2239686Z ##[debug]Getting app resource from ID 9NBLBGH2K3VZ
2021-10-14T01:27:45.2245703Z ##[debug]Starting request with correlation id: f905fe97-0b6c-4093-9833-a7eef3b9c6be
2021-10-14T01:27:46.2478555Z ##[debug]Finished request with correlation id: f905fe97-0b6c-4093-9833-a7eef3b9c6be
2021-10-14T01:27:46.2580531Z ##[debug]task result: Failed
2021-10-14T01:27:46.2666405Z ##[error]Status 403: CorrelationId: 9a781839-2b21-45e8-9d58-0c8cd86bb866

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants