WFN not saved from a frequency calculation

Hello!
I hope I’m not missing something here but I have the following input:

molecule TS {
*coordinates*
} 

set {
	basis Def2-SVP
}

e, wfn = frequency('M06-2X-D3ZERO2B', return_wfn=True)   
wfn.to_file('freq_calc')

But it gives me the following error:

Traceback (most recent call last):
  File "/home/ivan/mambaforge/envs/valfractal/bin/psi4", line 338, in <module>
    exec(content)
  File "<string>", line 87, in <module>
  File "/home/ivan/mambaforge/envs/valfractal/lib//python3.9/site-packages/psi4/driver/p4util/python_helpers.py", line 358, in _core_wavefunction_to_file
    'Ca':       wfn.Ca().to_array()       if wfn.Ca()       else None,

RuntimeError: 
Fatal Error: Wavefunction::Ca: Unable to obtain MO coefficients.
Error occurred in file: /scratch/psilocaluser/conda-builds/psi4-multiout_1670980379431/work/psi4/src/psi4/libmints/wavefunction.cc on line: 804
The most recent 5 function calls were:

psi::Wavefunction::Ca() const



Printing out the relevant lines from the Psithon --> Python processed input file:
    core.set_global_option("DFT_RADIAL_POINTS", 75)
    core.set_global_option("DFT_PRUNING_SCHEME", "robust")
    core.set_global_option("OPT_TYPE", "irc")
    core.set_global_option("GEOM_MAXITER", 100)
    e, wfn = frequency('M06-2X-D3ZERO2B', return_wfn=True)  
--> wfn.to_file('TS_radH_abstraction_primary_00_freq')   
    core.set_global_option("IRC_STEP_SIZE", 0.25)
    core.set_global_option("IRC_POINTS", 20)
    core.set_global_option("IRC_DIRECTION", "forward")
    e, irc_forw = optimize('M06-2X-D3ZERO2B', ref_gradient=wfn.gradient(), molecule=irc_forwards)
    irc_forwards.save_xyz_file('TS_radH_abstraction_primary_00_ircf.xyz',1)

!----------------------------------------------------------------------------------!
!                                                                                                  !
! Fatal Error: Wavefunction::Ca: Unable to obtain MO coefficients.                 !
! Error occurred in file: /scratch/psilocaluser/conda-                                        !
!     builds/psi4-multiout_1670980379431/work/psi4/src/psi4/libmints/wavefunction. !
!     cc on line: 804                                                                            !
! The most recent 5 function calls were:                                           !
! psi::Wavefunction::Ca() const                                                         !
!                                                                                                         !
!----------------------------------------------------------------------------------!

My plan was to use the WFN file for subsequent IRC calculations.
I have found this input structure in other topics in here but in my case it does not seem to work.

Thanks!