Search code examples
azure-pipelinesaccessibilityaccessibility-insights

accessibility-insights@3 task - An error occurred while scanning website page http://localhost:49487


What is the cause for the following accessibility task error?

enter image description here

Scanning URL http://localhost:49487/ ##[debug]Starting accessibility scanning of URL http://localhost:49487/ ##[debug]Chrome app executable: system default ##[debug] Created a data storage folder at C:__w_temp\accessibility-insights-action-8e9SZl. You can override the path by setting the APIFY_LOCAL_STORAGE_DIR environment variable ##[debug] PuppeteerCrawler:AutoscaledPool:Snapshotter: Setting max memory of this run to 16384 MB. Use the APIFY_MEMORY_MBYTES environment variable to override it. ##[debug] PuppeteerCrawler:AutoscaledPool: state {"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}}} ERROR PuppeteerCrawler: handleRequestFunction failed, reclaiming failed request back to the list or queue {"url":"http://localhost:49487/","retryCount":1,"id":"hgW4ugjCDUL55FU"} [object Object] ERROR PuppeteerCrawler: handleRequestFunction failed, reclaiming failed request back to the list or queue {"url":"http://localhost:49487/","retryCount":2,"id":"hgW4ugjCDUL55FU"} [object Object] ERROR PuppeteerCrawler: handleRequestFunction failed, reclaiming failed request back to the list or queue {"url":"http://localhost:49487/","retryCount":3,"id":"hgW4ugjCDUL55FU"} [object Object] ##[debug] PuppeteerCrawler: All the requests from request list and/or request queue have been processed, the crawler will shut down. ##[debug] PuppeteerCrawler: Final request statistics: {"requestsFinished":0,"requestsFailed":1,"retryHistogram":[null,null,null,1],"requestAvgFailedDurationMillis":8621,"requestAvgFinishedDurationMillis":null,"requestsFinishedPerMinute":0,"requestsFailedPerMinute":1,"requestTotalDurationMillis":8621,"requestsTotal":1,"crawlerRuntimeMillis":46750} ##[error][Exception]ErrorWithCause: An error occurred while scanning website page http://localhost:49487/ at Logger.trackExceptionAny (C:__w_tasks\accessibility-insights_4811a442-2fd3-5aa8-ba1a-14cb7e24c113\3.0.0\index.js:189828:29) at Scanner. (C:__w_tasks\accessibility-insights_4811a442-2fd3-5aa8-ba1a-14cb7e24c113\3.0.0\index.js:191013:29) at Generator.next () at fulfilled (C:__w_tasks\accessibility-insights_4811a442-2fd3-5aa8-ba1a-14cb7e24c113\3.0.0\index.js:190928:58) at processTicksAndRejections (node:internal/process/task_queues:96:5) caused by: TypeError: Cannot read properties of undefined (reading 'baseUrl') at Scanner.getCombinedReportParameters (C:__w_tasks\accessibility-insights_4811a442-2fd3-5aa8-ba1a-14cb7e24c113\3.0.0\index.js:191027:60) at Scanner. (C:__w_tasks\accessibility-insights_4811a442-2fd3-5aa8-ba1a-14cb7e24c113\3.0.0\index.js:191005:55) at Generator.next () at fulfilled (C:__w_tasks\accessibility-insights_4811a442-2fd3-5aa8-ba1a-14cb7e24c113\3.0.0\index.js:190928:58) at processTicksAndRejections (node:internal/process/task_queues:96:5) Accessibility scanning of URL http://localhost:49487/ completed ##[error]Exit code 1 returned from process: file name 'C:\Program Files\Docker\docker.EXE', arguments 'exec -i 785e0512e3002c77e853922ed34bf803dedbc3eecbf978a22d01bd3768098802 C:__a\externals\node\bin\node.exe C:__w_temp\containerHandlerInvoker.js'.


Solution

  • Apologies for the late response! This form of error used to be emitted whenever the Accessibility Insights for Azure DevOps task encountered a browser error during a scan. It wasn't very actionable, and it was improved as part of resolving issue #1315. Whatever underlying browser issue was causing the error for you should be explained more clearly in error output nowadays.

    If someone viewing this question today is still seeing an error like this (specifically, containing the line caused by: TypeError: Cannot read properties of undefined (reading 'baseUrl')), double check that you're using the latest version of the task (as of writing, @3).