question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

`pull_request_closed_no_merge` metric is broken

See original GitHub issue

Describe the bug: The pull_request_closed_no_merge metric returns a 500 internal server error.

To Reproduce: Steps to reproduce the behavior:

  1. Checkout dev
  2. Run augur run --disable-housekeeper
  3. Hit http://localhost:5000/api/unstable/repo/21000/pull-request-closed-no-merge
  4. Observe error

Expected behavior: I expected the metric to return a valid response object, even if it was empty.

Screenshots If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: macOS v 10.14.6

Additional context I noticed that there is a missing GROUP_BY clause in the SQL query, based on the usage of COUNT. This appears to be the main culprit of the issue.

Broken Travis build: https://travis-ci.org/chaoss/augur/builds/657396384

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:7 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
ccarterlandiscommented, Mar 2, 2020

I didn’t even notice this earlier, but the metrics API test is also failing because the route is incorrect. It should be ...unstable/repos/... instead of .../unstable/repo/ - this is why it’s returning a 404. I’d also suggest using the same repo ID in both your metric and API test.

1reaction
ccarterlandiscommented, Mar 2, 2020

Check out this line of the metrics test: https://travis-ci.org/chaoss/augur/jobs/657396385#L581. You’ll see the SQL error I’m referring to

Read more comments on GitHub >

github_iconTop Results From Across the Web

EM 12c, EM 13c: Troubleshooting the Metric Collection Error ...
The 'Metric Collection Error' status for a database target in Enterprise Manager (EM) Cloud Control means that ... IOException: Broken pipe.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found