SparkKubernetes doesn't work with the "application_file" kwarg #38537
Labels
area:providers
kind:bug
This is a clearly a bug
needs-triage
label for new issues that we didn't triage yet
Apache Airflow Provider(s)
cncf-kubernetes
Versions of Apache Airflow Providers
apache-airflow-providers-cncf-kubernetes==8.0.0
Apache Airflow version
2.8.2
Operating System
Deployment
Official Apache Airflow Helm Chart
Deployment details
No response
What happened
When using the "application_file" kwarg and passing a yaml file path the operator fails because it tries to open a file that is not found.
The issue is that because application_file is a template_field and "yaml" is a template_ext, Airflow reads the yaml file, renders the jinja template and sets the attribute to be the content of the file, which then in "manage_template_specs" method the operator tries to open (that's the 2nd time) and fails
What you think should happen instead
passing a path to an application file using the application_file should work without failures
How to reproduce
Use the SparkKubernetesOperator with the application_file kwarg without failures
Anything else
No response
Are you willing to submit PR?
Code of Conduct
The text was updated successfully, but these errors were encountered: