Parametric daylight analysis 1. Solution exception:'NoneType' object has no attribute 'X'

Hello,
I tried running a parametric daylight analysis. I used a script that is similar to @Mostapha’s example file that is uploaded here. I get the following error, although all parameters are correct.

  1. Solution exception:‘NoneType’ object has no attribute ‘X’

I don’t get this error when I run @Mostapha’s file. I would really appreciate your inputs.

Tower1.gh (616.9 KB)
Mostapha_ Parametric_Daylight_Analysis.gh (529.6 KB)