Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error related to merging on character vs factor column #5391

Closed
iMissile opened this issue May 23, 2022 · 1 comment · Fixed by #5446
Closed

Error related to merging on character vs factor column #5391

iMissile opened this issue May 23, 2022 · 1 comment · Fixed by #5446

Comments

@iMissile
Copy link

iMissile commented May 23, 2022

Hello.
I've tested data.table dev version 1.14.3 as it has so many features and bugfixes.
Unfortunately package bupaverse/processmapR) become broken due some changes in data.table internal logic.
I suppose current issue can be a clarification of #5361 as it influence @ work of another packages, not my personal code.

Error can be reproduced enven in public bupaR sample:

library(bupaR)
patients %>%
    process_map()
#> Error in rbindlist(l, use.names, fill, idcol) : 
#>   Class attribute on column 7 of item 2 does not match with column 7 of item 1.

More precisely, I tried to debug and found that error raised at this line https://github.com/bupaverse/processmapR/blob/6dbf8d776204b6706432f2fdf81b22a1ab6dcaae/R/process_map.R#L198
during data.table::merge by ordered factor and character.

When I rollback data.table to version 1.14.2 everything returns to working state.

SessionInfo()

R version 4.2.0 (2022-04-22 ucrt)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 19044)

Matrix products: default

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
 [1] petrinetR_0.2.1     processmonitR_0.1.0 xesreadR_0.2.3      processmapR_0.3.4   eventdataR_0.3.0   
 [6] edeaR_0.8.6         bupaR_0.4.4         fstcore_0.9.12      lgr_0.4.3           tsibble_1.1.1      
[11] furrr_0.3.0         future_1.25.0       dqrng_0.3.0         rTRNG_4.23.1-2      anytime_0.3.9      
[16] stringi_1.7.6       data.table_1.14.3   tictoc_1.0.1        datapasta_3.1.0     magrittr_2.0.3     
[21] forcats_0.5.1       stringr_1.4.0       dplyr_1.0.9         purrr_0.3.4         readr_2.1.2        
[26] tidyr_1.2.0         tibble_3.1.7        ggplot2_3.3.6       tidyverse_1.3.1    
@jangorecki
Copy link
Member

Could we have a minimal example code to reproduce?

@jangorecki jangorecki removed this from the 1.15.0 milestone Dec 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants