microsoft/accessibility-insights-service

[Bug] Error: Evaluation failed: TypeError: pQuerySelectorAll is not a function

Closed this issue · 1 comments

Describe the bug

When running accessibility-insights-scan on portal.azure.com URLs with authentication, scanner fails with "Error: pQuerySelectorAll is not a function".

Area

accessibility-insights-scan
accessibility-insights-crawler

To Reproduce

Steps to reproduce the behavior:

Run ai-scan with authentication on the url https://portal.azure.com, e.g. node .\packages\cli\dist\ai-scan-cli.js --url https://portal.azure.com --serviceAccountName $ACCOUNT_NAME --serviceAccountPassword $ACCOUNT_PASS --authType AAD --crawl

Expected behavior

The crawler successfully scans the URL.

Log files

From a test pipeline using the Accessibility Insights for ADO extension:

2023-04-21T17:33:32.4813223Z ##[section]Starting: case 12: url, azure portal auth test
2023-04-21T17:33:32.4818816Z ==============================================================================
2023-04-21T17:33:32.4819227Z Task         : Accessibility Insights Azure DevOps Task
2023-04-21T17:33:32.4819477Z Description  : Scan for accessibility issues in an Azure DevOps pipeline
2023-04-21T17:33:32.4819800Z Version      : 3.0.9
2023-04-21T17:33:32.4820033Z Author       : Accessibility Insights
2023-04-21T17:33:32.4820316Z Help         : For help with configuring and troubleshooting this task, see https://aka.ms/accessibility-insights-faq#azure-devops-extension
2023-04-21T17:33:32.4820669Z ==============================================================================
2023-04-21T17:33:32.6828065Z ##[group]Installing runtime dependencies
2023-04-21T17:33:32.6836034Z ##[debug]Using node from /usr/local/vss-agent/3.218.0/externals/node16/bin/node
2023-04-21T17:33:32.6837943Z ##[debug]Using bundled yarn from /mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/.yarn/releases/yarn-3.4.1.cjs
2023-04-21T17:33:33.1307492Z ➤ YN0000: ┌ Resolution step
2023-04-21T17:33:33.2744215Z ➤ YN0002: │ @fluentui/font-icons-mdl2@npm:8.4.13 doesn't provide @types/react (p46e09), requested by @fluentui/utilities
2023-04-21T17:33:33.2746711Z ➤ YN0002: │ @fluentui/font-icons-mdl2@npm:8.4.13 doesn't provide react (pc3e60), requested by @fluentui/utilities
2023-04-21T17:33:33.2747865Z ➤ YN0002: │ @fluentui/style-utilities@npm:8.7.12 doesn't provide @types/react (p1c0a5), requested by @fluentui/utilities
2023-04-21T17:33:33.2749370Z ➤ YN0002: │ @fluentui/style-utilities@npm:8.7.12 doesn't provide @types/react (p1f230), requested by @fluentui/theme
2023-04-21T17:33:33.2750468Z ➤ YN0002: │ @fluentui/style-utilities@npm:8.7.12 doesn't provide react (pd254b), requested by @fluentui/utilities
2023-04-21T17:33:33.2751353Z ➤ YN0002: │ @fluentui/style-utilities@npm:8.7.12 doesn't provide react (p716df), requested by @fluentui/theme
2023-04-21T17:33:33.2752282Z ➤ YN0002: │ accessibility-insights-report@npm:4.6.3 doesn't provide @types/react (pcd13e), requested by @fluentui/react
2023-04-21T17:33:33.2755178Z ➤ YN0002: │ accessibility-insights-report@npm:4.6.3 doesn't provide @types/react-dom (p6fea8), requested by @fluentui/react
2023-04-21T17:33:33.2757392Z ➤ YN0002: │ accessibility-insights-report@npm:4.6.4 doesn't provide @types/react (p6edd6), requested by @fluentui/react
2023-04-21T17:33:33.2759035Z ➤ YN0002: │ accessibility-insights-report@npm:4.6.4 doesn't provide @types/react-dom (p17015), requested by @fluentui/react
2023-04-21T17:33:33.2760229Z ➤ YN0060: │ accessibility-insights-scan@npm:1.7.0 provides puppeteer (p62687) with version 19.8.5, which doesn't satisfy what @axe-core/puppeteer requests
2023-04-21T17:33:33.2762081Z ➤ YN0060: │ accessibility-insights-scan@npm:1.7.0 provides puppeteer (p07c1d) with version 19.8.5, which doesn't satisfy what apify requests
2023-04-21T17:33:33.2765175Z ➤ YN0000: │ Some peer dependencies are incorrectly met; run yarn explain peer-requirements <hash> for details, where <hash> is the six-letter p-prefixed code
2023-04-21T17:33:33.2770684Z ➤ YN0000: └ Completed
2023-04-21T17:33:33.3180984Z ➤ YN0000: ┌ Fetch step
2023-04-21T17:33:33.6548686Z ➤ YN0013: │ 519 packages were already cached
2023-04-21T17:33:33.6577304Z ➤ YN0000: └ Completed in 0s 340ms
2023-04-21T17:33:33.6911814Z ➤ YN0000: ┌ Link step
2023-04-21T17:33:34.1088182Z ➤ YN0000: └ Completed in 0s 417ms
2023-04-21T17:33:34.1152453Z ➤ YN0000: Done with warnings in 0s 987ms
2023-04-21T17:33:34.1273218Z ##[endgroup]
2023-04-21T17:33:36.8152179Z ##[debug][Telemetry] tracking a 'ScanStart' event
2023-04-21T17:33:36.8159962Z ##[debug][Telemetry] tracking a 'Inputs' event
2023-04-21T17:33:36.8161410Z ##[debug][Telemetry] tracking a 'AuthUsed' event
2023-04-21T17:33:36.8162132Z ##[group]Scanning URL https://portal.azure.com
2023-04-21T17:33:36.8162849Z ##[debug]Starting accessibility scanning of URL https://portal.azure.com
2023-04-21T17:33:36.8163692Z ##[debug]Chrome app executable: /usr/bin/google-chrome
2023-04-21T17:33:36.8165059Z ##[debug] Created a data storage folder at /mnt/vss/_work/_temp/accessibility-insights-action-6jhpsw. You can override the path by setting the APIFY_LOCAL_STORAGE_DIR environment variable
2023-04-21T17:33:36.8166241Z ##[debug]�[33m PuppeteerCrawler:AutoscaledPool:Snapshotter:�[39m Setting max memory of this run to 1988 MB. Use the APIFY_MEMORY_MBYTES environment variable to override it.
2023-04-21T17:33:36.8167830Z ##[debug]�[33m PuppeteerCrawler:AutoscaledPool:�[39m state�[90m {"currentConcurrency":0,"desiredConcurrency":1,"systemStatus":{"isSystemIdle":true,"memInfo":{"isOverloaded":false,"limitRatio":0.2,"actualRatio":null},"eventLoopInfo":{"isOverloaded":false,"limitRatio":0.6,"actualRatio":null},"cpuInfo":{"isOverloaded":false,"limitRatio":0.4,"actualRatio":null},"clientInfo":{"isOverloaded":false,"limitRatio":0.3,"actualRatio":null}}}�[39m
2023-04-21T17:33:55.4177366Z ##[debug]KMSI page handled.
2023-04-21T17:33:55.4182444Z ##[debug]Authentication succeeded.
2023-04-21T17:34:04.8722376Z Processing page https://ms.portal.azure.com/#home
2023-04-21T17:34:04.8922955Z �[31mERROR�[39m�[33m PuppeteerCrawler:�[39m handleRequestFunction failed, reclaiming failed request back to the list or queue�[90m {"url":"https://portal.azure.com","retryCount":1,"id":"uhzXA4X8fGqJ7gN"}�[39m
2023-04-21T17:34:04.8946049Z   Error: Evaluation failed: TypeError: pQuerySelectorAll is not a function
2023-04-21T17:34:04.8948224Z       at pptr://__puppeteer_evaluation_script__:2:12
2023-04-21T17:34:04.8949879Z       at ExecutionContext._ExecutionContext_evaluate (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/puppeteer-core/lib/cjs/puppeteer/common/ExecutionContext.js:252:15)
2023-04-21T17:34:04.8951083Z       at processTicksAndRejections (node:internal/process/task_queues:96:5)
2023-04-21T17:34:04.8952457Z       at async CDPJSHandle.evaluateHandle (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/puppeteer-core/lib/cjs/puppeteer/common/JSHandle.js:65:16)
2023-04-21T17:34:04.9003632Z       at async Function.queryAll (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/puppeteer-core/lib/cjs/puppeteer/common/QueryHandler.js:73:24)
2023-04-21T17:34:04.9004981Z       at async Function.collect (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/puppeteer-core/lib/cjs/puppeteer/util/AsyncIterableUtil.js:20:26)
2023-04-21T17:34:04.9007651Z       at async CDPElementHandle.$$eval (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/puppeteer-core/lib/cjs/puppeteer/common/ElementHandle.js:115:25)
2023-04-21T17:34:04.9009207Z       at async ClassicPageProcessor.enqueueLinks [as enqueueLinksExt] (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/apify/build/enqueue_links/enqueue_links.js:112:25)
2023-04-21T17:34:04.9010588Z       at async ClassicPageProcessor.enqueueLinks (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/accessibility-insights-scan/dist/index.js:4425:26)
2023-04-21T17:34:04.9011841Z       at async ClassicPageProcessor.processPage (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/accessibility-insights-scan/dist/index.js:4263:13)
2023-04-21T17:34:04.9013148Z       at async PuppeteerCrawler.PageProcessorBase.pageHandler [as handlePageFunction] (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/accessibility-insights-scan/dist/index.js:4338:17)
2023-04-21T17:34:16.2056825Z Processing page https://ms.portal.azure.com/#home
2023-04-21T17:34:16.3233201Z �[31mERROR�[39m�[33m PuppeteerCrawler:�[39m handleRequestFunction failed, reclaiming failed request back to the list or queue�[90m {"url":"https://portal.azure.com","retryCount":2,"id":"uhzXA4X8fGqJ7gN"}�[39m
2023-04-21T17:34:16.3235588Z   Error: Evaluation failed: TypeError: pQuerySelectorAll is not a function
2023-04-21T17:34:16.3346298Z       at pptr://__puppeteer_evaluation_script__:2:12
2023-04-21T17:34:16.3348181Z       at ExecutionContext._ExecutionContext_evaluate (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/puppeteer-core/lib/cjs/puppeteer/common/ExecutionContext.js:252:15)
2023-04-21T17:34:16.3349007Z       at processTicksAndRejections (node:internal/process/task_queues:96:5)
2023-04-21T17:34:16.3350032Z       at async CDPJSHandle.evaluateHandle (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/puppeteer-core/lib/cjs/puppeteer/common/JSHandle.js:65:16)
2023-04-21T17:34:16.3351387Z       at async Function.queryAll (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/puppeteer-core/lib/cjs/puppeteer/common/QueryHandler.js:73:24)
2023-04-21T17:34:16.3352436Z       at async Function.collect (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/puppeteer-core/lib/cjs/puppeteer/util/AsyncIterableUtil.js:20:26)
2023-04-21T17:34:16.3353479Z       at async CDPElementHandle.$$eval (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/puppeteer-core/lib/cjs/puppeteer/common/ElementHandle.js:115:25)
2023-04-21T17:34:16.3354540Z       at async ClassicPageProcessor.enqueueLinks [as enqueueLinksExt] (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/apify/build/enqueue_links/enqueue_links.js:112:25)
2023-04-21T17:34:16.3355546Z       at async ClassicPageProcessor.enqueueLinks (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/accessibility-insights-scan/dist/index.js:4425:26)
2023-04-21T17:34:16.3356541Z       at async ClassicPageProcessor.processPage (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/accessibility-insights-scan/dist/index.js:4263:13)
2023-04-21T17:34:16.3357831Z       at async PuppeteerCrawler.PageProcessorBase.pageHandler [as handlePageFunction] (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/accessibility-insights-scan/dist/index.js:4338:17)
2023-04-21T17:34:29.5812393Z Processing page https://ms.portal.azure.com/#home
2023-04-21T17:34:29.5928967Z �[31mERROR�[39m�[33m PuppeteerCrawler:�[39m handleRequestFunction failed, reclaiming failed request back to the list or queue�[90m {"url":"https://portal.azure.com","retryCount":3,"id":"uhzXA4X8fGqJ7gN"}�[39m
2023-04-21T17:34:29.5930230Z   Error: Evaluation failed: TypeError: pQuerySelectorAll is not a function
2023-04-21T17:34:29.5930778Z       at pptr://__puppeteer_evaluation_script__:2:12
2023-04-21T17:34:29.5932030Z       at ExecutionContext._ExecutionContext_evaluate (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/puppeteer-core/lib/cjs/puppeteer/common/ExecutionContext.js:252:15)
2023-04-21T17:34:29.5932868Z       at processTicksAndRejections (node:internal/process/task_queues:96:5)
2023-04-21T17:34:29.5934006Z       at async CDPJSHandle.evaluateHandle (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/puppeteer-core/lib/cjs/puppeteer/common/JSHandle.js:65:16)
2023-04-21T17:34:29.5935157Z       at async Function.queryAll (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/puppeteer-core/lib/cjs/puppeteer/common/QueryHandler.js:73:24)
2023-04-21T17:34:29.5936565Z       at async Function.collect (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/puppeteer-core/lib/cjs/puppeteer/util/AsyncIterableUtil.js:20:26)
2023-04-21T17:34:29.5937638Z       at async CDPElementHandle.$$eval (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/puppeteer-core/lib/cjs/puppeteer/common/ElementHandle.js:115:25)
2023-04-21T17:34:29.5938940Z       at async ClassicPageProcessor.enqueueLinks [as enqueueLinksExt] (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/apify/build/enqueue_links/enqueue_links.js:112:25)
2023-04-21T17:34:29.5939934Z       at async ClassicPageProcessor.enqueueLinks (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/accessibility-insights-scan/dist/index.js:4425:26)
2023-04-21T17:34:29.5940865Z       at async ClassicPageProcessor.processPage (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/accessibility-insights-scan/dist/index.js:4263:13)
2023-04-21T17:34:29.5941978Z       at async PuppeteerCrawler.PageProcessorBase.pageHandler [as handlePageFunction] (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/accessibility-insights-scan/dist/index.js:4338:17)
2023-04-21T17:34:35.1823898Z ##[debug]�[33m PuppeteerCrawler:�[39m All the requests from request list and/or request queue have been processed, the crawler will shut down.
2023-04-21T17:34:35.1863068Z ##[debug]�[33m PuppeteerCrawler:�[39m Final request statistics:�[90m {"requestsFinished":0,"requestsFailed":1,"retryHistogram":[null,null,null,1],"requestAvgFailedDurationMillis":2064,"requestAvgFinishedDurationMillis":null,"requestsFinishedPerMinute":0,"requestsFailedPerMinute":1,"requestTotalDurationMillis":2064,"requestsTotal":1,"crawlerRuntimeMillis":59200}�[39m
2023-04-21T17:34:35.1926478Z ##[error]Scan failed with 1 error(s)
2023-04-21T17:34:35.1936165Z ##[error][Exception]ErrorWithCause: An error occurred while scanning website page: https://portal.azure.com
2023-04-21T17:34:35.1937827Z     at Logger.trackExceptionAny (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/index.js:187845:29)
2023-04-21T17:34:35.1941262Z     at Scanner.logAndTrackScanningException (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/index.js:189115:21)
2023-04-21T17:34:35.1942704Z     at /mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/index.js:189046:30
2023-04-21T17:34:35.1943644Z     at Array.forEach (<anonymous>)
2023-04-21T17:34:35.2008498Z     at Scanner.<anonymous> (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/index.js:189045:47)
2023-04-21T17:34:35.2009312Z     at Generator.next (<anonymous>)
2023-04-21T17:34:35.2010153Z     at fulfilled (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/index.js:188948:58)
2023-04-21T17:34:35.2010802Z     at processTicksAndRejections (node:internal/process/task_queues:96:5)
2023-04-21T17:34:35.2011380Z caused by: Error: '{\n' +
2023-04-21T17:34:35.2011862Z   "  name: 'Error',\n" +
2023-04-21T17:34:35.2012520Z   "  message: 'Execution context was destroyed, most likely because of a navigation.',\n" +
2023-04-21T17:34:35.2013327Z   "  stack: 'Error: Execution context was destroyed, most likely because of a navigation.\\n' +\n" +
2023-04-21T17:34:35.2014461Z   "    '    at rewriteError (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/puppeteer-core/lib/cjs/puppeteer/common/ExecutionContext.js:309:15)\\n' +\n" +
2023-04-21T17:34:35.2015407Z   "    '    at processTicksAndRejections (node:internal/process/task_queues:96:5)\\n' +\n" +
2023-04-21T17:34:35.2016507Z   "    '    at async ExecutionContext._ExecutionContext_evaluate (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/puppeteer-core/lib/cjs/puppeteer/common/ExecutionContext.js:216:60)\\n' +\n" +
2023-04-21T17:34:35.2018222Z   "    '    at async ExecutionContext.convertArgument (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/puppeteer-core/lib/cjs/puppeteer/common/ExecutionContext.js:259:19)\\n' +\n" +
2023-04-21T17:34:35.2019326Z   "    '    at async Promise.all (index 0)\\n' +\n" +
2023-04-21T17:34:35.2020444Z   "    '    at async ExecutionContext._ExecutionContext_evaluate (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/puppeteer-core/lib/cjs/puppeteer/common/ExecutionContext.js:237:24)\\n' +\n" +
2023-04-21T17:34:35.2021755Z   "    '    at async Frame.addStyleTag (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/puppeteer-core/lib/cjs/puppeteer/common/Frame.js:626:75)\\n' +\n" +
2023-04-21T17:34:35.2023016Z   "    '    at async PageNavigationHooks.disableAnimation (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/accessibility-insights-scan/dist/index.js:7210:9)\\n' +\n" +
2023-04-21T17:34:35.2024344Z   "    '    at async PageNavigationHooks.postNavigation (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/accessibility-insights-scan/dist/index.js:7185:9)\\n' +\n" +
2023-04-21T17:34:35.2025633Z   "    '    at async PageProcessorBase.postNavigation (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/node_modules/accessibility-insights-scan/dist/index.js:4360:17)'\n" +
2023-04-21T17:34:35.2026375Z   '}'
2023-04-21T17:34:35.2027164Z     at Logger.trackExceptionAny (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/index.js:187844:94)
2023-04-21T17:34:35.2028210Z     at Scanner.logAndTrackScanningException (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/index.js:189115:21)
2023-04-21T17:34:35.2029210Z     at /mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/index.js:189046:30
2023-04-21T17:34:35.2029823Z     at Array.forEach (<anonymous>)
2023-04-21T17:34:35.2030654Z     at Scanner.<anonymous> (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/index.js:189045:47)
2023-04-21T17:34:35.2031248Z     at Generator.next (<anonymous>)
2023-04-21T17:34:35.2032039Z     at fulfilled (/mnt/vss/_work/_tasks/accessibility-insights_aebf5565-d905-5999-8faf-a44d4db6c0fa/3.0.9/index.js:188948:58)
2023-04-21T17:34:35.2032698Z     at processTicksAndRejections (node:internal/process/task_queues:96:5)
2023-04-21T17:34:35.2033354Z ##[debug][Telemetry] tracking a 'ErrorFound' event
2023-04-21T17:34:35.2033845Z Accessibility scanning of URL https://portal.azure.com completed
2023-04-21T17:34:35.2749511Z ##[error]Scan failed with 1 error(s)
2023-04-21T17:34:35.8350216Z ##[section]Finishing: case 12: url, azure portal auth test

Additional context

This bug has been present in the ADO extension since it upgraded the accessibility-insights-scan package from version 1.6.0 to version 1.7.0. This issue is being tracked in the extension as well: microsoft/accessibility-insights-action#1713

lamaks commented

The workaround implemented in version 2.4.1. To scan protected page use command line option --browserOptions disable-web-security to disable CORS.

This particular website blocks puppeteer from loading internal script. Other websites do not require this workaround.