|
assert(port.state == .connected) |
This assertion fires when you unplug a MIDI device of which a port is used.
I think removing this cause for runtime exceptions in DEBUG builds is a good fit (because the assumption that the device is still connected isn't always true!) and cannot gracefully be handled at all.
WebMIDIKit/Sources/WebMIDIKit/MIDIPortMap.swift
Line 70 in 6f35069
This assertion fires when you unplug a MIDI device of which a port is used.
I think removing this cause for runtime exceptions in DEBUG builds is a good fit (because the assumption that the device is still connected isn't always true!) and cannot gracefully be handled at all.