It should make no difference if you are using an older version of R.
The following code works:
library(forecast)
CalSales <- ts(c(197,211,203,247,239,269,308,262,258,256,261,288,296,276,
305,308,356,393,363,386,443,308,358,384),
frequency=12)
Cal_model <- holt(CalSales, h=4)
summary(Cal_model[["model"]])
#> Holt's method
#>
#> Call:
#> holt(y = CalSales, h = 4)
#>
#> Smoothing parameters:
#> alpha = 1e-04
#> beta = 1e-04
#>
#> Initial states:
#> l = 199.7736
#> b = 7.9699
#>
#> sigma: 33.2374
#>
#> AIC AICc BIC
#> 250.0740 253.4073 255.9643
#>
#> Training set error measures:
#> ME RMSE MAE MPE MAPE MASE
#> Training set -0.4254659 30.34144 23.29228 -1.067513 7.490028 0.2374744
#> ACF1
#> Training set 0.1562895
Created on 2022-05-02 by the reprex package (v2.0.1)
My guess is that the problem is to do with how you've read in your data. If it has come in as character instead of numerical, this error may appear.