Error in cs function of GAMLSS framework: variable lengths differ

The following is an official example of the use of the 'cs' function in GAMLSS framework(

# cubic splines example
# fitting a smoothing cubic spline with 7 degrees of freedom
# plus the a quarterly  effect  
aids1<-gamlss(y~cs(x,df=7)+qrt,data=aids,family=PO) # 

But it gives such an error message:

variable lengths differ (found for 'cs(aids$x, df = 7)')

Please help me. Thank you all