TypeError: 'NoneType' object is not iterable
https://github.com/dpkp/kafka-python/blob/bd557dabd487cc44c11bf003600c82477ea5de11/kafka/producer/kafka.py#L711
Intermittently getting this issue - not sure what is going on - I'm intending for topics to be auto-created. So obviously they don't have partitions. Though it still manages to work overall somehow. Perhaps if I'm pushing one message, and the topic is being created, and doesn't yet have any partitions, then pushing second message to the same topic would produce this error. Very strange error, and I'm getting it a lot!
Can you include example code and the full traceback? I realize the code works 99% of the time, and only intermittently throws the error and only with a new auto-created topic, but it'd still be helpful for stepping through what's happening.
Hi, have you found any solution for this?
This is probably caused by a race condition caused by a new metadata response between _wait_for_metadata and _partition.