danielpalme / ReportGenerator

ReportGenerator converts coverage reports generated by coverlet, OpenCover, dotCover, Visual Studio, NCover, Cobertura, JaCoCo, Clover, gcov or lcov into human readable reports in various formats.
https://reportgenerator.io
Apache License 2.0
2.58k stars 281 forks source link

Azure DevOps Services Sign In during report generation #574

Closed lKoTl closed 1 year ago

lKoTl commented 1 year ago

Hi,

We started seeing next picture when the coverage is generated.

  1. When there is no branch coverage for the classes the it generates the report and ends up with HTML page to sign in into DevOps when viewing the line coverage. image

  2. When there is a branch coverage during report generation it hits 500 error image

When navigating manually to the file view as a logged in user (via browser) the file is reachable.

Is there anything that could be configured / changed to make it work?

danielpalme commented 1 year ago

Please have a look at my comment here: https://github.com/danielpalme/ReportGenerator/issues/501#issuecomment-1073008102

This comment describes how you can create a "Personal access token" and pass the token to ReportGenerator.

lKoTl commented 1 year ago

Great, that solves it. Went with System Access token instead Personal, didn't want to personalize the pipelines.

customSettings: 'settings:customHeadersForRemoteFiles=Authorization=Bearer $(System.AccessToken)'