make run_locally work with --dry-run