AttributeError: 'NoneType' object has no attribute 'scheduleNotification_' on macOS Sierra (10.12.6)
- Dominant language
- Python
- Stars
- 5k
- Forks
- 216
- PR merge metrics
- No merged PRs in 30d
Description
#### update
If I use the system python, it seems to work. Therefore, I added a simple wrapper:
```
ntpy () {
pyenv shell system
ntfy "$@"
pyenv shell --unset
}
```
This fixes triggering a notification, for now. But haven't even tried messing around with all the other fancy stuff `ntfy` does.
Mac support is not a huge priority for me as I'm migrating off it (hopefully) anyhow.
#### debugging
I'm guessing this might have something to do with permissions or something...
Running:
* ntfy 2.5.1
* iTerm`Build 3.1.5.beta.2`
* GNU bash, version 4.4.12(1)-release (x86_64-apple-darwin15.6.0)
* python 3.6.1
* pyenv 1.1.0
Did the install quickly with `sudo pip install ntfy` (later tried omitting the sudo) and did `ntfy send test`:

(also tried above command with sudo)
Seems like `NSUserNotificationCenter.defaultUserNotificationCenter()` (docs at https://developer.apple.com/documentation/foundation/nsusernotificationcenter) is not returning anything

Got curious and started printing out stuff using https://pythonhosted.org/pyobjc/api/module-objc.html - no protocols on `NSUserNotificationCenter` and the properties are shown below - don't really know anything about Objective C

Notifications center settings don't look too interesting:

Looks like the Console.app log says this:

Nothing in the system.log..
I also set up a very minimal `~/.ntfy.yml`:

Also tried adding
```
darwin:
prio: DEBUG
```
Not sure that's right - but I seem to see more logs? This taskgated thing seems to do with SIP, or System Integrity Protection and it seems to be not so easy to disable (https://apple.stackexchange.com/questions/281006/how-to-stop-taskgated-on-sierra)

Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.