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

Provide more info when reviewpad fails #635

Open
ferreiratiago opened this issue Jan 24, 2023 · 0 comments
Open

Provide more info when reviewpad fails #635

ferreiratiago opened this issue Jan 24, 2023 · 0 comments
Labels
enhancement New feature or request

Comments

@ferreiratiago
Copy link
Member

Is your feature request related to a problem? Please describe.
Currently, when Reviewpad fails we are collecting the error to mixpanel in order to understand the reasoning behind a failure. However, the current shared information is not enough to fully understand the issue behind a failure.

Describe the solution you'd like
We should share more information with mixpanel, mainly:

  • File and line
  • Func
  • Error message details (for instance, if a GitHub request then the request error details).
  • Log stack

Here's an example:

  • "file": "/service/handler/runner.go:140",
  • "func": "github.com/reviewpad/reviewpad/handler.run",
  • "error": "error loading reviewpad.yml file. trying to load reviewpad.yaml",
  • "errorDetails": "error loading reviewpad file: GET https://api.github.com/repos/ferreiratiago/.github/contents/reviewpad-config?ref=main: 404 Not Found []",
  • "log stack":
    time="2023-01-19T11:05:53Z" level=info msg="processing pull_request event"
    time="2023-01-19T11:05:53Z" level=info msg="found pull request 7"
    2023/01/19 11:05:53 using local config file reviewpad.yml
    time="2023-01-19T11:05:54Z" level=info msg="analyzing workflow 'review'"
    time="2023-01-19T11:05:54Z" level=info msg="evaluating workflow 'review'"
    time="2023-01-19T11:05:54Z" level=info msg="rule 'true' activated" workflow=review
    time="2023-01-19T11:05:54Z" level=info msg="executing program"
    time="2023-01-19T11:05:55Z" level=info msg="action $comment("Comment") executed"
    time="2023-01-19T11:05:55Z" level=warning msg="the Label label was not found in the environment" builtin=addLabel
    time="2023-01-19T11:05:56Z" level=info msg="action $addLabel("Label") executed"
    time="2023-01-19T11:05:57Z" level=info msg="action $commentOnce("Comment once") executed"
    time="2023-01-19T11:05:58Z" level=info msg="creating review APPROVE with body LGTM" builtin=review
    time="2023-01-19T11:05:58Z" level=error msg="error executing configuration file" error="POST https://api.github.com/repos/ferreiratiago/action-test/pulls/7/reviews: 422 Unprocessable Entity [{Resource: Field: Code: Message:Can not approve your own pull request}]"
@ferreiratiago ferreiratiago added the enhancement New feature or request label Jan 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant