You can replace the three lines with:
```
stderr_level = kwargs.pop("stderr_level", None)
```