Removed duplicated code

Improved deprecated warning assertion
Added a deprecation warning when the `setup_ini` field is used