Skip to content
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

correct curl patch url is not generated by python requests #68

Closed
zerolaser opened this issue Nov 7, 2017 · 3 comments
Closed

correct curl patch url is not generated by python requests #68

zerolaser opened this issue Nov 7, 2017 · 3 comments
Assignees
Labels

Comments

@zerolaser
Copy link

this is the sample code. which i was trying to convert to python, but is showing up POST instead of PATCH

curl 'https://ci.example.com/go/api/agents/adb9540a-b954-4571-9d9b-2f330739d4da' \
      -u 'username:password' \
      -H 'Accept: application/vnd.go.cd.v4+json' \
      -H 'Content-Type: application/json' \
      -X PATCH \
      -d '{
        "hostname": "agent02.example.com",
        "agent_config_state": "Enabled",
        "resources": ["Java","Linux"],
        "environments": ["Dev"]
        }'
@NickCarneiro NickCarneiro self-assigned this Nov 7, 2017
@zerolaser
Copy link
Author

@NickCarneiro Also add the -v verbose option. whenever we use this option this should output the debug http information.

@NickCarneiro
Copy link
Member

fixed in 1.13.0.

Support for -v is an interesting idea. Right now we don't even print out responses.

@zerolaser
Copy link
Author

@NickCarneiro thanks for the fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

No branches or pull requests

2 participants