# State files are becoming huge

**URL:** https://discourse.paraview.org/t/state-files-are-becoming-huge/11770
**Category:** ParaView Support
**Tags:** python
**Created:** [March 30, 2023, 5:13pm UTC](https://discourse.paraview.org/t/state-files-are-becoming-huge/11770 "2023-03-30T17:13:30Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![Xabier\_Morales\_Ferez](https://discourse.paraview.org/user_avatar/discourse.paraview.org/xabier_morales_ferez/32/2890_2.png) [@Xabier\_Morales\_Ferez](https://discourse.paraview.org/u/Xabier_Morales_Ferez)
#### Post date: [March 30, 2023, 5:13pm UTC](https://discourse.paraview.org/t/state-files-are-becoming-huge/11770/1 "2023-03-30T17:13:30Z")

</div>

Hi,

I’m running a Python script in Paraview 5.11.0 to read some already existing Paraview state files, add some filters, and save the state files back. As I go through the cases, the state file size increases really fast. The state files work perfectly afterwards, but they become so big that it takes a lot of time to open them. Do you know what might be the problem?

I tried running this code I found on an old forum post, and after each iteration, the state files don’t increase that much in size, but they continue to do so.

```auto
def ResetSession():
    pxm = servermanager.ProxyManager()
    pxm.UnRegisterProxies()
    del pxm
    Disconnect()
    Connect()

```

Kind regards,  
Xabier
