thevalidatoR icon indicating copy to clipboard operation
thevalidatoR copied to clipboard

Error in covr::package_coverage()

Open venkatesh588 opened this issue 4 months ago • 12 comments

What happened?

Hi Team,

I'm getting for many packages the below mentioned error message in the coverage section. Can someone help on this.

Error in covr::package_coverage(): ! Package installation did not succeed. Backtrace:

covr::package_coverage(Sys.getenv("INPUT_REPORT_PKG_DIR", ".")) Quitting from lines 164-166 [coverage] (template.qmd) Execution halted WARN: Should not have arrived here: ERROR: [non-error-thrown] undefined

Stack trace: at _Command.handleError (file:///opt/quarto/bin/quarto.js:10025:117) at _Command.parseCommand (file:///opt/quarto/bin/quarto.js:9712:12) at eventLoopTick (ext:core/01_core.js:178:7) at async quarto (file:///opt/quarto/bin/quarto.js:175825:5) at async file:///opt/quarto/bin/quarto.js:175853:5 at async file:///opt/quarto/bin/quarto.js:175708:14 at async mainRunner (file:///opt/quarto/bin/quarto.js:175710:5) at async file:///opt/quarto/bin/quarto.js:175846:3 Error in quarto_render(): ! Error running quarto CLI from R. Caused by error in quarto_render(): ✖ Error returned by quarto CLI. processing file: template.qmd 1/20 2/20 [setup] 3/20 4/20 [execution_info] 5/20 6/20 [version_control] 7/20 8/20 [session_info] 9/20 10/20 [riskmetric] 11/20 12/20 [r_cmd_check] 13/20 14/20 [coverage] Error in covr::package_coverage(): ! Package installation did not succeed. Backtrace:

covr::package_coverage(Sys.getenv("INPUT_REPORT_PKG_DIR", ".")) Quitting from lines 164-166 [coverage] (template.qmd) Execution halted WARN: Should not have arrived here: ERROR: [non-error-thrown] undefined

Stack trace: at _Command.handleError (file:///opt/quarto/bin/quarto.js:10025:117) at _Command.parseCommand (file:///opt/quarto/bin/quarto.js:9712:12) at eventLoopTick (ext:core/01_core.js:178:7) at async quarto (file:///opt/quarto/bin/quarto.js:175825:5) at async file:///opt/quarto/bin/quarto.js:175853:5 at async file:///opt/quarto/bin/quarto.js:175708:14 at async mainRunner (file:///opt/quarto/bin/quarto.js:175710:5) at async file:///opt/quarto/bin/quarto.js:175846:3

Caused by error: ! System command 'quarto' failed Backtrace: ▆

├─quarto::quarto_render(template_path, output_file = "validation_report.pdf") │ └─quarto:::quarto_run(args, echo = TRUE, quarto_bin = quarto_bin) │ ├─base::withCallingHandlers(...) │ └─processx::run(...) │ └─throw(...) │ └─base::signalCondition(cond) └─quarto (local) (<systm___>) └─quarto:::wrap_quarto_error(e, args, .call = .call) └─cli::cli_abort(msg, call = .call, parent = cnd, ) └─rlang::abort(...) Execution halted Error: Process completed with exit code 1.

Regards, Venkateswar

Relevant log output

No response

Code of Conduct

  • [x] I agree to follow this project's Code of Conduct.

Contribution Guidelines

  • [x] I agree to follow this project's Contribution Guidelines.

Security Policy

  • [x] I agree to follow this project's Security Policy.

venkatesh588 avatar Aug 15 '25 16:08 venkatesh588

@venkatesh588 - looks like the package installation failed. Make sure you're installing dependencies needed for the package prior to running the action.

cicdguy avatar Aug 15 '25 16:08 cicdguy

Hi @cicdguy Thank you for the update. Action completed the R CMD check and its failing in the coverage stage. I installed the dependency and tried however still having the same issue.

venkatesh588 avatar Aug 15 '25 17:08 venkatesh588

Feel free to fork the repo and add debugging logs. That should help you determine where the failure occurs.

cicdguy avatar Aug 15 '25 17:08 cicdguy

@cicdguy I have tired that and having same issue. This action should install dependency automatically during the execution. I'm facing same issue for the multiple packages for all the packages its failing in the same stage.

venkatesh588 avatar Aug 15 '25 17:08 venkatesh588

You added debugging logs? What do your debug logs say?

cicdguy avatar Aug 15 '25 17:08 cicdguy

@cicdguy Please find the logs and can't see many details in debug as well.

r-validation.log

venkatesh588 avatar Aug 15 '25 18:08 venkatesh588

What I meant was that you can modify the contents of the action on your fork and add your own custom logging to narrow down where the issue is.

Alternatively you can post the reproducible example here with your workflow so we can determine what the issue could be.

cicdguy avatar Aug 15 '25 18:08 cicdguy

workflow-arrow.yml

@cicdguy Please find the my workflow file and please validate arrow package, admiral and admiraldev. You can re-produce using these packages.

venkatesh588 avatar Aug 15 '25 18:08 venkatesh588

@cicdguy Can you please help me, if you are able to re-produce the issue?

venkatesh588 avatar Aug 15 '25 19:08 venkatesh588

@cicdguy Can you please help me, if you are able to re-produce the issue?

venkatesh588 avatar Aug 15 '25 20:08 venkatesh588

@cicdguy @donyunardi @pawelru Can you please help me, if you are able to re-produce the issue?

venkatesh588 avatar Aug 18 '25 11:08 venkatesh588

So it looks like your analysed package cannot be installed correctly and covr runs installation in the background. There might be multiple reasons behind this but this is because of missing dependencies - R package(s) and/or system dependencies (if any). @cicdguy gave you a good hint:

  • fork the repo
  • introduce debug statements printing list of available packages and checking system deps (if any)
  • change url from this repo to your fork so that you will use it
  • run it and analyse the results

It has been months (if not years) for me since I last looked into this repo - sorry if this is not what you expected.

pawelru avatar Aug 18 '25 13:08 pawelru