SaveFigureThread, does not attach files when there is no write permission
This commit is contained in:
4
base.py
4
base.py
@@ -129,7 +129,7 @@ class BaseWindow(QMainWindow):
|
||||
_dirname = os.path.dirname(save_dest)
|
||||
|
||||
if os.access(_dirname, os.W_OK):
|
||||
print("We have write permission", flush=True)
|
||||
|
||||
all_fig_data[canvas][idx].savefig(save_dest)
|
||||
elif not write_message_fired:
|
||||
|
||||
@@ -138,7 +138,7 @@ class BaseWindow(QMainWindow):
|
||||
"host {1}. Images not saved and " +
|
||||
"cannot be sent to elog").format(
|
||||
_dirname, os.uname()[1])
|
||||
print(_mess, flush=True)
|
||||
|
||||
self.parent.trigger_log_message.emit(
|
||||
MsgSeverity.WARN.name, _pymodule,
|
||||
_line(), _mess, {})
|
||||
|
||||
Reference in New Issue
Block a user