notion-py
notion-py copied to clipboard
Fix Callbacks
I think the callbacks needs still to be fixed. Can someone say, why or what is broken with monitoring/callbacks? Maybe I can help then.
Yea, this stuff is kinda broken. I'll allow for contributions but only after #41 gets merged. You can start working on it if you want but it's not stable yet, so that might end up with more frustrations than its worth.
Can you tell me what exactly is broken, because I tried the callback and for me, it worked?
I can't tell you exactly what is not working because I haven't written tests for Monitor/reactive parts of the library. The readme states that automatic updates from motion to python are not working.
You can test it by doing the steps below:
- create a block
- set some value
- modify the value by hand on the notion page
- notice that the new value is not shown in python (i.e. the representation did not refresh automatically)
I'm also not sure if the long polling works, never tested that feature.
Good news is that I just finished that nasty rewrite so I'm now working on getting the last missing bits in shape for a final release.
In a previous version Jamie used websockets instead of long polling. Maybe this can be reused. I will look into it in the next days maybe I get some ideas
I just checked jamalex version of callbacks works right now