Describe the bug
I can see this error if I have: query_string > 2036. As I can see the problem in pyga.requsts.py in build_http_request link to method
So, as you can see when query_string > 2036 we try to use post and set query_string as a data post = query_string. Than it raise this error.
Error stack-trace:
File "pyga/requests.py", line 880, in track_event
request.fire()
File "pyga/requests.py", line 110, in fire
self.__send()
File "pyga/requests.py", line 96, in __send
request, timeout=self.config.request_timeout)
File "/usr/local/lib/python3.7/urllib/request.py", line 222, in urlopen
return opener.open(url, data, timeout)
File "/usr/local/lib/python3.7/urllib/request.py", line 523, in open
req = meth(req)
File "/usr/local/lib/python3.7/urllib/request.py", line 1280, in do_request_
raise TypeError(msg)
TypeError: POST data should be bytes, an iterable of bytes, or a file object. It cannot be of type str.
To Reproduce
Steps to reproduce the behavior:
- Use Python3.7
- Build http request where query_string > 2036 and use this library
- See error
Expected behavior
It should not give an error.
Describe the bug
I can see this error if I have:
query_string > 2036. As I can see the problem inpyga.requsts.pyinbuild_http_requestlink to methodSo, as you can see when query_string > 2036 we try to use post and set query_string as a data
post = query_string. Than it raise this error.Error stack-trace:
To Reproduce
Steps to reproduce the behavior:
Expected behavior
It should not give an error.