python-osc icon indicating copy to clipboard operation
python-osc copied to clipboard

Dispatcher withholds messages due to bundle timetag

Open xioTechnologies opened this issue 6 years ago • 3 comments

A mismatch between the client and server date/time causes dispatcher will withhold all messages until the application runs out of memory and crashes!

Please add an option to disable this scheduling and instead allow the application to handle the bundle timetags. I suggest a flag named "disable bundle scheduling", or similar. If this flag is set then the dispatcher would:

  • Provide OSC messages as soon as they are received
  • Include the timetag associated with each message

xioTechnologies avatar Oct 21 '19 11:10 xioTechnologies

Indeed, another alternative could be to have a set of flags to:

  • cap number of messages held in memory (easy, can lead to unexpected behavior)
  • discard messages scheduled too far in the future (easy, can lead to unexpected behavior)
  • have a special dispatch /currenttimestamp method or something alike for the client to verify that its clock is somewhat synchronised with the server (requires client work, only takes care of the synchronisation issue)

attwad avatar Oct 27 '19 11:10 attwad

You seem to be looking past the simplest use case: To just print received OSC.

I expect this is something that almost all users would want to do at some point, even if just for debugging. No buffering, no scheduling, no discarding of messages; just provide the data that was received when it was received.

xioTechnologies avatar Oct 27 '19 23:10 xioTechnologies

Yup that would also work, the purpose of that library was to be somewhat useful and abstract that away from the clients but offering them a way to get the raw messages/bundles if they want is also fair.

attwad avatar Oct 29 '19 08:10 attwad