How to install mitmproxy in Kali?

I try to install mitmproxy in Kali via command
sudo pip install mitmproxy
but error happend
Command python setup.py egg_info failed with error code 1 in /tmp/pip-build-bwI1st/brotlipy
Anyone can help me? Thanks for your hep.

Hi,

This is an issue with installing brotlipy, not mitmproxy. Can you please lodge an issue in the brotlipy bug tracker? https://github.com/python-hyper/brotlipy/