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

Improve server debugging experience #24

Open
mpacer opened this issue Mar 13, 2018 · 7 comments
Open

Improve server debugging experience #24

mpacer opened this issue Mar 13, 2018 · 7 comments

Comments

@mpacer
Copy link
Collaborator

mpacer commented Mar 13, 2018

Right now it's not straight-forward to debug the server, because the easiest way to actually deposit a payload to a running server is to actually create a new PR that meets the Paper: naming criteria on scipy-conference/scipy_proceedings.

There are a number of things to improve:

  • trigger individual builds
  • trigger the webhook
@stefanv
Copy link
Member

stefanv commented Mar 14, 2018

The first should be much easier, once we complete the message bus work.

The second we can do by making a POST to the webhook URL with the following format data:

{
  'pull_request': {
    'html_url': 'https://github.com/scipy-conference/scipy_proceedings/pull/335'
  }
}

We can write a script with a signature like trigger_webhook.py N where N is a paper number, then look up the PR url in the cache, and do the POST request as outlined above.

@mpacer
Copy link
Collaborator Author

mpacer commented Mar 14, 2018

I think we’ll need more header information when tying to debug this in the past.

@mpacer
Copy link
Collaborator Author

mpacer commented Mar 14, 2018

Also, I’m not sure how we’re going to redirect the Webhook calls from
GitHub to the appropriate location at procbuild.scipy.org

@stefanv
Copy link
Member

stefanv commented Mar 14, 2018

The README explains how to add a webhook:

In the scipy-conference/scipy_proceedings repo: in the webhooks add a payload
URL pointing to the webapp (such as http://server.com:5000/webhook). You must
select only Pull Requests in the checkbox menu.

@stefanv
Copy link
Member

stefanv commented Mar 14, 2018

I think we’ll need more header information when tying to debug this in the past.

Can you explain what you mean by this?

@mpacer
Copy link
Collaborator Author

mpacer commented Mar 14, 2018

Sorry, my tenses got messed up.

When I was trying to mock up these requests with Katy last year we needed more header information from the GitHub webhook for the request to work properly. I don’t remember what that information was off the top of my head.

@stefanv
Copy link
Member

stefanv commented Mar 14, 2018

You can see the code that handles the incoming request here: https://github.com/scipy-conference/procbuild/blob/master/procbuild/server.py#L249

It only reads the fields I mentioned.

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

No branches or pull requests

2 participants