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

StoreIngestion InvokeWebRequest UnknownInternalFailure #208

Closed
LanceMcCarthy opened this issue Aug 27, 2020 · 4 comments
Closed

StoreIngestion InvokeWebRequest UnknownInternalFailure #208

LanceMcCarthy opened this issue Aug 27, 2020 · 4 comments
Labels
API Issue Problem stemming from the Submission API as opposed to StoreBroker

Comments

@LanceMcCarthy
Copy link

LanceMcCarthy commented Aug 27, 2020

I am getting new errors. I do not have any code changes, but there have been a couple pushes to StoreBroker master since (my script always updates from SB master before using).

Ouput

If you would like to see the complete output, you can find it here, However, let me just share the relevant part to save time

1354 |          Write-Log -Exception $_ -Level Error
     |          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     | 2020-08-27 16:53:31 : runneradmin :  Write-Log:
     | D:\a\MediaFileManager\MediaFileManager\SBGitRoot\StoreBroker\StoreIngestionApi.psm1:2008 Line
     | | 2008 |                  Write-Log -Exception $_ -Level Error      |     
     | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~      | 2020-08-27 16:53:31 : runneradmin : 
     | Invoke-WebRequest:      |
     | D:\a\MediaFileManager\MediaFileManager\SBGitRoot\StoreBroker\StoreIngestionApi.psm1:1824
     | Line      | | 1824 |                      $result = Invoke-WebRequest
     | @params      |        | ~~~~~~~~~~~~~~~~~~~~~~~~~      |      |
     |      |
     | {"code":"InternalServerError","data":[],"details":[],"innererror":{"code":"UnknownInternalFailure","data":[],"details":[],"message":"The service has encountered an unknown internal server error: "},"message":"An internal server error occurred while processing the operation.","source":"Ingestion Api"}  

Thoughts

I have seen @riverar share some Partner Center ingestion API failures in the dashboard. I wonder if this is related. However, I cant be sure with just the response of {"code":"InternalServerError", ... }

@HowardWolosky
Copy link
Member

This report unfortunately is not actionable. There's not enough information here. You will either need to update your script to pass in the -Verbose switch to the StoreBroker commands so that it logs everything to your console output, or you will need to publish out your StoreBroker log file as some sort of build artifact for post-mortem debugging.

As far as I know, there shouldn't be any issues on the StoreBroker side. The only commits to StoreBroker that happened after your last successful build was a fix for the exception that you were seeing, and adding in the option to suppress the telemetry reminder, neither of which would have caused the issue that you're seeing.

Also as an aside, as of yesterday, StoreBroker is now published on PowerShellGallery (something that should have happened 4 years ago). So, going forward, you can just do an Install-Module -Name StoreBroker in your script to get it installed and loaded, as opposed to cloning the repo itself.

@LanceMcCarthy
Copy link
Author

I'll add the verbose and let you know if anything relevant comes out of it.

In the meantime, excellent news about the gallery! I'll be sure to also switch to that at the same time.

If you are going to update the Setup.md docs, I recommend updating the notepad $profile section to include Set-PSRepository so they dont have to keep approving the startup steps.

Here's what I used:

if (-NOT ([Security.Principal.WindowsPrincipal] [Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole(`
[Security.Principal.WindowsBuiltInRole] "Administrator")) {
    Write-Host "Not admin, skipping StoreBroker setup."
}
else {
    Write-Host "Updating and authenticating StoreBroker"
    Set-PSRepository -Name "PSGallery" -InstallationPolicy Trusted

    # Update StoreBroker
    Install-Module -Name StoreBroker

    # Authenticate Store Broker
    # redacted for clarity
}

@LanceMcCarthy
Copy link
Author

Okay, so this must have been a transient issue with the backend side of things? The submission when through this time.

Note: There are still a bunch of those Get-GitHubConfiguration failure warnings in there. I left -Verbose on if you want to see the warnings and the full results https://github.com/LanceMcCarthy/MediaFileManager/runs/1037925983?check_suite_focus=true

When you're done, feel free to close this issue unless oyu see something in there that might be related to the initial error.

@HowardWolosky
Copy link
Member

The Get-GitHubConfiguration failure warnings are fixed with this, that fix just isn't in 1.20.0. It's why you didn't see it in your runs that cloned the repo, but you were seeing it in your runs using PowerShellGallery. The fix will be in 1.20.1, which is waiting on #180 getting merged in.

@HowardWolosky HowardWolosky added the API Issue Problem stemming from the Submission API as opposed to StoreBroker label Aug 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
API Issue Problem stemming from the Submission API as opposed to StoreBroker
Projects
None yet
Development

No branches or pull requests

2 participants