Skip to content

error in cb_write(): "Element Label Stem doesn't exist." #40

@ccsarapas

Description

@ccsarapas

When writing codebook created from REDCap with .split_var_labels specified:

Error in `dplyr::mutate()`:
ℹ In argument: `all_of(grp)`.
Caused by error in `all_of()`:
! Can't subset elements that don't exist.
✖ Element `Label Stem` doesn't exist.
---
Backtrace:
     ▆
  1. ├─lighthouse.codebook::cb_write(...)
  2. │ └─lighthouse.codebook:::cb_write_impl(...)
  3. │   └─lighthouse.codebook:::cb_write_codebook(...)
  4. │     └─lighthouse.codebook:::cb_prep_sheet_data(...)
  5. │       ├─dplyr::mutate(...)
  6. │       └─dplyr:::mutate.data.frame(...)
  7. │         └─dplyr:::compute_by(...)
  8. │           └─dplyr:::eval_select_by(by, data, error_call = error_call)
  9. │             └─tidyselect::eval_select(...)
 10. │               └─tidyselect:::eval_select_impl(...)
 11. │                 ├─tidyselect:::with_subscript_errors(...)
 12. │                 │ └─base::withCallingHandlers(...)
 13. │                 └─tidyselect:::vars_select_eval(...)
 14. │                   └─tidyselect:::walk_data_tree(expr, data_mask, context_mask)
 15. │                     └─tidyselect:::eval_context(expr, context_mask, call = error_call)
 16. │                       ├─tidyselect:::with_chained_errors(...)
 17. │                       │ └─base::withCallingHandlers(...)
 18. │                       └─rlang::eval_tidy(as_quosure(expr, env), context_mask)
 19. └─tidyselect::all_of(grp)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions