hterik commented on issue #42542: URL: https://github.com/apache/airflow/issues/42542#issuecomment-2647101331
> Despite the symlink that points these directories to a contract directory, the [get_dag_directory](https://github.com/apache/airflow/blob/2.9.1/airflow/dag_processing/manager.py#L963) resolves this path to its canonical path, which will be different across re-syncs. This path get passed all the way to the [deactivate_deleted_dags](https://github.com/apache/airflow/blob/2.9.1/airflow/models/dag.py#L3830) function in the dag model, by which is used to mark the dag inactive and therefore hidden from the UI. The deletion is not happening since the processor_subdir value does not match the previously registered processor_subdir. Nice find @TerryYin1777. 👍 > Not fully sure the reason why we need to resolve the dag folder path to its canonical. I understand it's not an issue with Airflow itself and probably happens only when git-sync is used for dag deployment. But given it's a quite widely adopted combination, is it possible to add a configuration like GET_DAG_FOLDER_RESOLVE=False so the symlink path is not resolved to its canonical path? If possible, let's all try to not add any more configuration options please. If this can be solved by not resolving the directory or through some other means, that should always work even when not using gitsync. I'm not against configuration but this is one of those options that is going to have very subtle impact and will result in footguns if not set correctly, and both modes need to work and be tested anyway, meaning more maintenance. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
