# Jointlcmm error when trying to use competing risks

I am still attempting to use jointLCMM to model trajectories of a risk variable while controlling for data missing not at random due to survival events.

I am trying to control for multiple events resulting in sequence truncation. My code for the survival component is

Surv(time_event, status)~covariate, hazard="Weibull"


I keep getting an error message

Error in rep(c(sqrt(sum(devt == i)/sum(tsurv[devt == i])), 1), ifelse(risqcom == : invalid 'times' argument

When I was running it without competing events, using

Surv(entrytime, exittime, event_flag)


it worked fine. I tried a bunch of potential fixes but none of them worked. Have any of you got ideas of what this error message means/how to fix it? Thanks!!