Platform Checker step in my pipeline is failing/exiting with an unknown error

Collins Muema 0 Reputation points
2025-05-16T11:44:41.6133333+00:00

I have an existing export pipeline for our solution. It has been running without issues until recently when the failure rate increased due to the platform checker step exiting with an unclear error. It is clear that the error has nothing to do with the solution itself (based on the logs). It is however unclear what is causing the error on platform checker because it only runs successfully at night. I have attached screenshots of the logs:

User's image

User's image

Azure DevOps
{count} votes

1 answer

Sort by: Most helpful
  1. Gaurav Kumar 785 Reputation points Moderator
    2025-05-26T10:18:00.8133333+00:00

    Hi @Collins Muema ,

    I’ve reviewed the logs you shared, and it looks like the Power Platform Checker step is failing intermittently with the following error:

    Error: A task was canceled.
    Exiting with Failed InvokePowerAppsChecker
    

    This usually points to throttling or network timeouts, especially since you mentioned the step works reliably at night.

    I also noticed this recurring failure:

    Could not connect to the Dataverse organization at https://arqitekcrm.crm4.dynamics.com/
    

    Which again indicates that the CLI couldn't reach the Dataverse instance before timing out and canceling the task.

    Try the below workaround to Stabilize the Power Platform Checker Step:

    Upgrade Power Platform CLI

    Ensure you're using the latest CLI version:

    pac install latest
    

    Implement Retry Logic in Pipeline

    Wrap your pac solution check command in retry logic to reduce the impact of transient failures.

    YAML Example with Retry Logic:

    - task: PowerShell@2
      displayName: 'Run Power Platform Checker with Retry'
      inputs:
        targetType: 'inline'
        script: |
          $maxAttempts = 3
          $attempt = 0
          $success = $false
          while (-not $success -and $attempt -lt $maxAttempts) {
              $attempt++
              Write-Host "Attempt $attempt of $maxAttempts..."
              try {
                  pac solution check `
                      --path "C:\agent\_work\1\a\UrSolution.zip" `
                      --ruleSet 0ad12346-e108-40b8-a956-9a8f95ea18c9 `
                      --customEndpoint "https://UrOrg.crm4.dynamics.com/" `
                      --outputDirectory "C:\agent\_work\1\a\checker-output" `
                      --saveResults false
                  Write-Host "Power Platform Checker succeeded."
                  $success = $true
              } catch {
                  Write-Warning "Attempt $attempt failed: $_"
                  if ($attempt -lt $maxAttempts) {
                      Write-Host "Retrying in 15 seconds..."
                      Start-Sleep -Seconds 15
                  }
              }
          }
          if (-not $success) {
              throw "Power Platform Checker failed after $maxAttempts attempts."
          }
    

    Schedule Runs During Off-Peak Hours

    Since the checker works at night, consider scheduling that step (or the full pipeline) to run after hours when load is low.

    Enable Debug Logging for Diagnostics

    Append --debug to your CLI call for more insight:

    pac solution check ... --debug
    

    By following these steps, you should be able to troubleshoot the Platform Checker step in your pipeline and address the unknown error it is encountering.

    Hope it helps!


    Please do not forget to click "Accept the answer” and Yes wherever the information provided helps you, this can be beneficial to other community members.

    If you have any other questions or still running into more issues, let me know in the "comments" and I would be happy to help you.


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.