Merge pull request #630 from CrazyPython/patch-1

Clarify error message
This commit is contained in:
Jakub Roztocil 2017-12-13 21:15:43 +01:00 committed by GitHub
commit 02b28093a8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -302,7 +302,8 @@ class HTTPieArgumentParser(ArgumentParser):
"""
if self.args.data:
self.error('Request body (from stdin or a file) and request '
'data (key=value) cannot be mixed.')
'data (key=value) cannot be mixed. Pass '
'--ignore-stdin to let key/value take priority.')
self.args.data = getattr(fd, 'buffer', fd).read()
def _guess_method(self):