You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2022/07/27 05:00:10 UTC

[GitHub] [airflow] uranusjr commented on pull request #25331: BashOperator - resolve bash by absolute path

uranusjr commented on PR #25331:
URL: https://github.com/apache/airflow/pull/25331#issuecomment-1196267728

   > I'm a little confused why this is not a more common failure mode, does subprocess have a list of default locations to look or something?
   
   Yes. When you supply a “bare“ command (instead of a path), `subprocess` relies on the OS to look up the actual executable. This is the same as looking up in `PATH` _most of the time_, but also depends on a bunch of other run-time configurations set in the OS. So the general suggestion is to always pass in a pre-resolved path instead of a bare command, since it is the behaviour most people expect in most situations, unless you are actively trying to replicate the OS behaviour down to implementation details.


-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org