Repository: stable-diffusion-webui
Issue: Error verifying pickled file from \stable-diffusion-webui\models\Stable-diffusion\Inpainting-anythingV3.ckpt:
Labels: bug-report

### Is there an existing issue for this?

- [X] I have searched the existing issues and checked the recent builds/commits

### What happened?

after update + extension update error on some models
used to work prior to this update

### Steps to reproduce the problem

0. update all extensions
1. prompt "elon musk as a donut"
2. XYZ plot > x= checkpoint names = all
generate
Error verifying pickled file from \stable-diffusion-webui\models\Stable-diffusion\Inpainting-anythingV3.ckpt:

### What should have happened?

generate with no problem like it used to be
python: 3.10.11  •  torch: 1.13.1+cu117  •  xformers: 0.0.17.dev464  •  gradio: 3.28.1  •  commit: [696c338e](https://github.com/AUTOMATIC1111/stable-diffusion-webui/commit/696c338ee2841830fd5010427d90347329d5786a)  •  checkpoint: [108ed54c98](https://google.com/search?q=108ed54c986d56ba0f3ef7d9c034938645f645607faecf70852953f09ad191d8)

### Commit where the problem happens

72cd27a

### What platforms do you use to access the UI ?

Windows

### What browsers do you use to access the UI ?

Brave

### Command Line Arguments

```Shell
@echo off

set PYTHON=
set GIT=
set VENV_DIR=
set COMMANDLINE_ARGS=--api --xformers

call webui.bat
```


### List of extensions

@echo off

set PYTHON=
set GIT=
set VENV_DIR=
set COMMANDLINE_ARGS=--api --xformers

call webui.bat


### Console logs

```Shell
Loading weights [92cb44cc9a] from Z:\__TESTS\stable-diffusion-webui\models\Stable-diffusion\Inpainting-anythingV3.ckpt | 380/880 [02:45<01:15,  6.58it/s]
Error verifying pickled file from Z:\__TESTS\stable-diffusion-webui\models\Stable-diffusion\Inpainting-anythingV3.ckpt:
Traceback (most recent call last):
  File "Z:\__TESTS\stable-diffusion-webui\modules\safe.py", line 132, in load_with_extra
    check_pt(filename, extra_handler)
  File "Z:\__TESTS\stable-diffusion-webui\modules\safe.py", line 90, in check_pt
    unpickler.load()
  File "Z:\__TESTS\stable-diffusion-webui\modules\safe.py", line 27, in persistent_load
    return TypedStorage(_internal=True)
TypeError: TypedStorage.__new__() got an unexpected keyword argument '_internal'


The file may be malicious, so the program is not going to read it.
You can skip this check with --disable-safe-unpickle commandline argument.


Loading weights [108ed54c98] from Z:\__TESTS\stable-diffusion-webui\models\Stable-diffusion\aistaticmodv1_.safetensors
Creating model from config: Z:\__TESTS\stable-diffusion-webui\configs\v1-inference.yaml
LatentDiffusion: Running in eps-prediction mode
DiffusionWrapper has 859.52 M params.
Applying xformers cross attention optimization.
Model loaded in 3.9s (create model: 0.3s, apply weights to model: 2.7s, apply half(): 0.3s, move model to device: 0.5s).
Error completing request
Arguments: ('task(1j5t5h3g1i7i1mz)', 'elon musk as a donut', '', [], 20, 0, False, False, 1, 1, 7, -1.0, -1.0, 0, 0, 0, False, 512, 512, False, 0.7, 2, 'Latent', 0, 0, 0, [], 3, False, False, 'LoRA', 'None', 1, 1, 'LoRA', 'None', 1, 1, 'LoRA', 'None', 1, 1, 'LoRA', 'None', 1, 1, 'LoRA', 'None', 1, 1, None, 'Refresh models', False, True, False, 'none', 'None', 1, None, False, 'Scale to Fit (Inner Fit)', False, False, 64, 64, 64, 0, 1, False, False, 'none', 'None', 1, None, False, 'Scale to Fit (Inner Fit)', False, False, 64, 64, 64, 0, 1, False, False, 'none', 'None', 1, None, False, 'Scale to Fit (Inner Fit)', False, False, 64, 64, 64, 0, 1, False, False, False, False, False, False, 'positive', 'comma', 0, False, False, '', 10, '', ['2dn_1.safetensors [83569a04f4]', 'aistaticmodv1_.safetensors [108ed54c98]', 'analog-diffusion-1.0.safetensors [51f6fff508]', 'anything-v3-fp32-pruned.safetensors [3088848987]', 'anything-v4.0-pruned.safetensors [69528490df]', 'anything-v4.5-pruned.safetensors [6e430eb514]', 'AOM3.safetensors [d124fc18f0]', 'aToZovyaRPGArtistsTools15_sd15V1.safetensors [e28b2e61fb]', 'aZovyaRPGArtistTools_v2Art.safetensors [565ee15273]', 'chikmix_V1.safetensors [bb6e6362d8]', 'chilloutmix_NiPrunedFp32Fix.safetensors [fc2511737a]', 'clarity_19.safetensors [a64810e2e1]', 'Counterfeit-V2.5_pruned.safetensors [a074b8864e]', 'deliberate_v2.safetensors [9aba26abdf]', 'dreamlike-diffusion-1.0.safetensors [c86a1a99b8]', 'dreamlike-photoreal-2.0.safetensors [92970aa785]', 'dreamshaper_4BakedVae.safetensors [7f16bbcd80]', 'faetastic_.safetensors [46d105afa7]', 'illuminatiDiffusionV1_v11.safetensors [cae1bee30e]', 'Inpainting-anythingV3.ckpt [92cb44cc9a]', 'inpainting-djzAirlockV21768V21512_21768.safetensors [6b52307e80]', 'inpainting-djzGingertomcatV21768V21_21768.safetensors [e764e24b18]', 'inpainting-galaxytimemachines_v5.safetensors [747e13e576]', 'inpainting-hassanblendv15.safetensors [b0b817c9c4]', 'inpainting-sd-v1-5.ckpt [c6bbc15e32]', 'lyriel_v13.safetensors [1c0ed90d69]', 'openjourneyLora.safetensors [75ef5457d3]', 'pastelmix-better-vae.safetensors [430c9b7350]', 'perfectWorld_v2Baked.safetensors [79e42fb744]', 'protogenX34Photorealism_1.safetensors [44f90a0972]', 'realisticVisionV20_v20.safetensors [e6415c4892]', 'revAnimated_v11.safetensors [d725be5d18]', 'theAllysMixIII_v10.safetensors [f427dd7a4f]', 'tinyPlanets_V1.safetensors [3e5adab0bf]', 'uberRealisticPornMerge_urpmv13.safetensors [f93e6a50ac]', 'unstableinkdream_v5Photoreal.safetensors [199638b9b2]', 'UnstableinkdreamV4.safetensors [168e8b89a6]', 'UnstableinkdreamV5.safetensors [aca2683176]', 'UnstableinkdreamV6.7.safetensors [095e34dbd5]', 'UnstableinkdreamV6.9.safetensors [cfaaa9b29a]', 'UnstableinkdreamV6.safetensors [d855c1d2ba]', 'UnstableinkdreamV7.0.safetensors [153dad0b82]', 'UnstableSamInkDream.safetensors [e05992510c]', 'v2-1_768-nonema-pruned.safetensors [ff144a4984]'], 0, '', [], 0, '', [], True, False, False, False, 0, None, None, None, 50) {}
Traceback (most recent call last):
  File "Z:\__TESTS\stable-diffusion-webui\modules\call_queue.py", line 57, in f
    res = list(func(*args, **kwargs))
  File "Z:\__TESTS\stable-diffusion-webui\modules\call_queue.py", line 37, in f
    res = func(*args, **kwargs)
  File "Z:\__TESTS\stable-diffusion-webui\modules\txt2img.py", line 53, in txt2img
    processed = modules.scripts.scripts_txt2img.run(p, *args)
  File "Z:\__TESTS\stable-diffusion-webui\modules\scripts.py", line 407, in run
    processed = script.run(p, *script_args)
  File "Z:\__TESTS\stable-diffusion-webui\scripts\xyz_grid.py", line 669, in run
    processed = draw_xyz_grid(
  File "Z:\__TESTS\stable-diffusion-webui\scripts\xyz_grid.py", line 288, in draw_xyz_grid
    process_cell(x, y, z, ix, iy, iz)
  File "Z:\__TESTS\stable-diffusion-webui\scripts\xyz_grid.py", line 251, in process_cell
    processed: Processed = cell(x, y, z, ix, iy, iz)
  File "Z:\__TESTS\stable-diffusion-webui\scripts\xyz_grid.py", line 632, in cell
    res = process_images(pc)
  File "Z:\__TESTS\stable-diffusion-webui\modules\processing.py", line 510, in process_images
    sd_models.reload_model_weights()
  File "Z:\__TESTS\stable-diffusion-webui\modules\sd_models.py", line 505, in reload_model_weights
    state_dict = get_checkpoint_state_dict(checkpoint_info, timer)
  File "Z:\__TESTS\stable-diffusion-webui\modules\sd_models.py", line 271, in get_checkpoint_state_dict
    res = read_state_dict(checkpoint_info.filename)
  File "Z:\__TESTS\stable-diffusion-webui\modules\sd_models.py", line 257, in read_state_dict
    sd = get_state_dict_from_checkpoint(pl_sd)
  File "Z:\__TESTS\stable-diffusion-webui\modules\sd_models.py", line 206, in get_state_dict_from_checkpoint
    pl_sd = pl_sd.pop("state_dict", pl_sd)
AttributeError: 'NoneType' object has no attribute 'pop'
```


### Additional information

_No response_