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

Label version service #9

Closed
xuanxu opened this issue Jul 30, 2021 · 1 comment
Closed

Label version service #9

xuanxu opened this issue Jul 30, 2021 · 1 comment
Assignees
Labels

Comments

@xuanxu
Copy link
Member

xuanxu commented Jul 30, 2021

As mentioned here, in order to get the latest versioned stats label, an external service is needed.

It should receive the grade (bronze/silver/gold) and the repo + issue number and should label that issue with the correct versioned label, for example: 6/approved-bronze-v0.0.1

Once it's ready, we can change the ApproveResponder to use it.

@mpadge mpadge self-assigned this Jul 30, 2021
@mpadge mpadge added the must do label Jul 30, 2021
mpadge added a commit that referenced this issue Aug 23, 2021
mpadge added a commit that referenced this issue Aug 23, 2021
mpadge added a commit that referenced this issue Aug 23, 2021
@mpadge mpadge closed this as completed in 35e3201 Aug 23, 2021
@mpadge
Copy link
Member

mpadge commented Aug 23, 2021

@xuanxu The endpoint is stats_badge with 2 parameters of:

  • repo in org/repo form (like ropensci/software-review), which should always be the repo from which a call is made
  • issue_num of review issue, which should always be the issue from which a call is made

Example

port <- 8000L
repo <- "ropenscilabs/statistical-software-review"
issue_num <- 10

library (httr)
sprintf ("http://<server-IP-address>:%s/stats_badge?repo=%s&issue_num=%s",
         as.integer (port), repo, issue_num) |>
    GET () |>
    content ()
#> [[1]]
#> [1] "6\approved-bronze-v0.0.1"

Created on 2021-08-23 by the reprex package (v2.0.0.9000)

There are 3 issues it can be tested with here, here, and here, which should respectively return bronze, silver, and gold. Let me know if there's anything that should be done here. Thanks!


Edit: The <server-IP-address> is in current settings-production.yml for the editorcheck endpoint.

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

No branches or pull requests

2 participants