OHDSI / FeatureExtraction

An R package for generating features (covariates) for a cohort using data in the Common Data Model.
http://ohdsi.github.io/FeatureExtraction/
61 stars 60 forks source link

Weekly R-check fails #239

Closed ginberg closed 7 months ago

ginberg commented 7 months ago

I noticed the weekly R check is failing, see error below. There haven't been any code changes, it might be because a newer version of a library is used.

  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error ('test-spot-checks.R:201:3'): Run spot-checks at per-person level on Oracle ──
  <purrr_error_indexed/rlang_error/error/condition>
  Error in `purrr::map(op$joins$table, ~sql_optimise(sql_build(.x, con, sql_options = sql_options), 
      con))`: ℹ In index: 1.
  Caused by error in `rlang::sym()`:
  ! No known SQL translation

  [ FAIL 1 | WARN 4 | SKIP 85 | PASS 72 ]
  Error: Test failures
  Execution halted
Running the tests in ‘tests/testPostgres.R’ failed.
Last 13 lines of output:
   13.               └─tidyselect:::walk_data_tree(new, data_mask, context_mask)
   14.                 └─tidyselect:::expr_kind(expr, context_mask, error_call)
   15.                   └─tidyselect:::call_kind(expr, context_mask, error_call)

  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error ('test-spot-checks.R:187:3'): Run spot-checks at per-person level on PostgreSQL ──
  <purrr_error_indexed/rlang_error/error/condition>
  Error in `purrr::map(op$joins$table, ~sql_optimise(sql_build(.x, con, sql_options = sql_options), 
      con))`: ℹ In index: 1.
  Caused by error in `rlang::sym()`:
  ! No known SQL translation

  [ FAIL 1 | WARN 3 | SKIP 85 | PASS 72 ]
  Error: Test failures
  Execution halted
Running the tests in ‘tests/testSqlite.R’ failed.
Last 13 lines of output:
   30. │ └─dbplyr:::escape_infix_expr(enexpr(x), x)
   31. └─rlang::sym
   32.   └─cli::cli_abort(...)
   33.     └─rlang::abort(...)
  ── Error ('test-spot-checks.R:213:3'): Run spot-checks at per-person level on Eunomia ──
  <purrr_error_indexed/rlang_error/error/condition>
  Error in `purrr::map(op$joins$table, ~sql_optimise(sql_build(.x, con, sql_options = sql_options), 
      con))`: ℹ In index: 1.
  Caused by error in `rlang::sym()`:
  ! No known SQL translation

  [ FAIL 3 | WARN 5 | SKIP 57 | PASS 141 ]
  Error: Test failures
  Executing SQL took 0.00473 secs
  Execution halted
Running the tests in ‘tests/testSqlServer.R’ failed.
Last 13 lines of output:
   13.               └─tidyselect:::walk_data_tree(new, data_mask, context_mask)
   14.                 └─tidyselect:::expr_kind(expr, context_mask, error_call)
   15.                   └─tidyselect:::call_kind(expr, context_mask, error_call)

  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error ('test-spot-checks.R:194:3'): Run spot-checks at per-person level on SQL Server ──
  <purrr_error_indexed/rlang_error/error/condition>
  Error in `purrr::map(op$joins$table, ~sql_optimise(sql_build(.x, con, sql_options = sql_options), 
      con))`: ℹ In index: 1.
  Caused by error in `rlang::sym()`:
  ! No known SQL translation
ginberg commented 7 months ago

it seems to be related to a version update of dbplyr, see

schuemie commented 7 months ago

@ginberg : Thanks for fixing this! I'm preparing the 2024Q1 HADES-wide release, which should be ready by the end of this month (so just a couple of more days). I currently am failing unit tests because of this FeatureExtraction issue.

Would it be possible to create a patch release of FeatureExtraction (or any release) that fixes this issue today or tomorrow?

ginberg commented 7 months ago

@schuemie sure we can make a patch release, I will work on that today or latest by tomorrow