Fix deprecations

Merging the changes originating from dim and tamird in order to fix issues with poseidon_cluster