fn get_data_dir(state: &Arc<AppState>) -> Result<String, String>
Helper to extract the version-specific data dir from AppState.