fix(kugetsu-index): call kugetsu_add_notification from bash instead of os.system() #169
Reference in New Issue
Block a user
Delete Branch "fix/issue-167-notification-bash"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Fix notifications for completed/error states by calling kugetsu_add_notification from bash instead of via Python os.system().
Problem
Issue #167: update_queue_item_state() in kugetsu-index.sh was calling kugetsu_add_notification via os.system():
This failed silently because os.system() spawns a NEW subprocess that cannot access bash functions defined in the parent shell. kugetsu_add_notification is a bash function, not an executable.
Impact
Fix
This works because kugetsu-index.sh sources kugetsu-log.sh which defines kugetsu_add_notification, so it's available in the same shell context.
Fixes #167
lgtm