alufers / mitmproxy2swagger

Automagically reverse-engineer REST APIs via capturing traffic
5.01k stars 215 forks source link

Error with parsing urlencoded requests #46

Open alufers opened 1 year ago

alufers commented 1 year ago

https://github.com/alufers/mitmproxy2swagger/commit/d04b127870fb711ce6b31a21a830a4f8aaa3842f#r113463641

AttributeError: 'str' object has no attribute 'decode'. Did you mean: 'encode'? parse_qsl seems to return list of string pairs already.

vividsystem commented 10 months ago

https://docs.python.org/3/library/urllib.parse.html

Parse a query string given as a string argument (data of type application/x-www-form-urlencoded). Data are returned as a list of name, value pairs.

This is the description I could find on the official docs. I get the same issue

vividsystem commented 10 months ago

Fixed it with #103