potiuk commented on a change in pull request #7724: [AIRFLOW-1536] Inherit
umask from parent process in daemon mode
URL: https://github.com/apache/airflow/pull/7724#discussion_r392612429
##########
File path: airflow/utils/cli.py
##########
@@ -238,3 +238,12 @@ def sigquit_handler(sig, frame): # pylint:
disable=unused-argument
if line:
code.append(" {}".format(line.strip()))
print("\n".join(code))
+
+
+def get_umask():
+ """
+ Returns umask to control default file permission for new files
+ """
+ cur_mask = os.umask(0)
+ os.umask(cur_mask)
Review comment:
I see - then it's yet another reason why we should not set/reset the umask.
We really do not need to find out what is the current umask - we should set a
reasonable value from configuration.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services