ClosedSendChannelException
Indicates an attempt to send to a closed-for-sending channel that was closed without a cause.
If a cause was provided, that cause is thrown from send instead of this exception. In particular, if the channel was closed because it was cancelled, this exception will never be thrown: either the cause
of the cancellation is thrown, or a new CancellationException gets constructed to be thrown from SendChannel.send.
This exception is a subclass of IllegalStateException, because the sender should not attempt to send to a closed channel after it itself has closed it, and indicates an error on the part of the programmer. Usually, this exception can be avoided altogether by restructuring the code.