-
Notifications
You must be signed in to change notification settings - Fork 326
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support for HEAD and PATCH #117
Comments
Hi, PyRestTest is supposed to provide support for these, but since it's still a new feature, it may be that the settings are not correct for your server (or there is a bug). To assist in troubleshooting, please can you provide the following:
Thanks! That should let us determine why this is occurring. |
curl.txt Please find the files attached. I have also redacted certain information like hostnames, tokens etc. |
@ksramchandani This is solved, thanks to @lerrua for providing a fix -- the root cause was incomplete configuration. The fix is merged to the master branch now, but not released to PyPi yet (the release is scheduled for the next month, after additional testing and several new features). However you can still use this to install and test, with instructions here. I'm going to go ahead and close out this issue since we have a tested fix, but let us know if you still encounter any issues, and we can re-open it. Thanks! |
@ksramchandani I'm reopening and will take a look at HEAD again to see what's going on there |
@ksramchandani and @lerrua I've added an automated test to confirm that the HEAD method works as expected against at least one additional public API: 010a18e When I run this, it succeeds against GitHub's API at least:
(to run this yourself, you'll need some additional libraries installed): Maybe @ksramchandani can provide the curl & pyresttest results for HEAD, as with PATCH? As far as I can tell, this should be all that's required for basic HEAD support, but might be wrong here. |
I have attached the curl, resttest and its corresponding yaml file for help in further debugging the issue for HEAD requests |
HEAD probably needs to set NOBODY option - https://curl.haxx.se/libcurl/c/CURLOPT_NOBODY.html |
@ksramchandani This one is an issue with SSL, probably peer verification. Alternately, one can update/change the CA info if you need a newer CA bundle or have a central CA for your internal work. You can probably work around it by setting the "--ssl_insecure" command line or testset-config option. |
Fixed with PR (broader HEAD support) |
Are you planning to add support for HEAD and PATCH HTTP methods ?
Currently it results in a HTTP 400 i.e. Bad Request while trying to use those methods
The text was updated successfully, but these errors were encountered: