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

api/v1/repos/:owner/:repo/pulls/*** not implemented #3472

Closed
1 of 3 tasks
bkcsoft opened this issue Feb 8, 2018 · 11 comments
Closed
1 of 3 tasks

api/v1/repos/:owner/:repo/pulls/*** not implemented #3472

bkcsoft opened this issue Feb 8, 2018 · 11 comments
Labels
issue/confirmed Issue has been reviewed and confirmed to be present or accepted to be implemented issue/regression Indicates a previously functioning feature or behavior that has broken or regressed after a change modifies/api This PR adds API routes or modifies them

Comments

@bkcsoft
Copy link
Member

bkcsoft commented Feb 8, 2018

Seems like we don't have /pulls-endpoints implemented at all. I do remember them being implemented before though so they must've been removed in a refactor some time ago.

The following outputs are both for the same PR #5

$ curl https://try.gitea.io/api/v1/repos/gitea/gitea/issues/5/comments/ | jq .
[
  {
    "id": 2059,
    "html_url": "https://try.gitea.io/gitea/gitea/pulls/5#issuecomment-2059",
    "pull_request_url": "https://try.gitea.io/gitea/gitea/pulls/5",
    "issue_url": "",
    "user": {
      "id": 4,
      "login": "bkc",
      "full_name": "Kim \"BKC\" Carlbäcker",
      "email": "[email protected]",
      "avatar_url": "https://secure.gravatar.com/avatar/d05dbfb80d6b9a461cd4578f18709a83?d=identicon",
      "username": "bkc"
    },
    "body": "Foobar",
    "created_at": "2018-02-08T01:32:01Z",
    "updated_at": "2018-02-08T01:32:01Z"
  }
]
$ curl -v https://try.gitea.io/api/v1/repos/gitea/gitea/pulls/5/comments/
[...]
> GET /api/v1/repos/gitea/gitea/pulls/5/comments/ HTTP/2
> Host: try.gitea.io
> User-Agent: curl/7.58.0
> Accept: */*
> 
* Connection state changed (MAX_CONCURRENT_STREAMS updated)!
< HTTP/2 404 
< content-type: text/plain; charset=utf-8
< date: Thu, 08 Feb 2018 01:35:09 GMT
< set-cookie: lang=en-US; Path=/; Max-Age=2147483647
< set-cookie: i_like_gitea=f71a34e0b91ce9db; Path=/; HttpOnly
< set-cookie: _csrf=RSpu7TlGgDC_5rh6Fw5QyPEkcUI6MTUxODA1MzcwOTExNDM2MzQwNg%3D%3D; Path=/; Expires=Fri, 09 Feb 2018 01:35:09 GMT; HttpOnly
< x-frame-options: SAMEORIGIN
< content-length: 0
< 
@bkcsoft bkcsoft added issue/regression Indicates a previously functioning feature or behavior that has broken or regressed after a change modifies/api This PR adds API routes or modifies them labels Feb 8, 2018
@bkcsoft
Copy link
Member Author

bkcsoft commented Feb 8, 2018

It's causing importing to GitLab to fail https://gitlab.com/gitlab-org/gitlab-ce/issues/31480#note_58059568

@Dunky13
Copy link

Dunky13 commented Apr 23, 2018

Looking at the api folder: routers/api/v1/repo/you see the filesissue.go&issue_comment.go`

I'd expect the same for pull: pull.go & pull_comment.go

But the latter doesn't exist, and when searching through the history using:

git log --stat --all --full-history -- routers/api/v1/repo/pull.* it only shows pull.go as the only edited file.

If the pull-endpoints were implemented, then they weren't implemented the same way as issue-endpoints.

@bkcsoft
Copy link
Member Author

bkcsoft commented Apr 23, 2018

@Dunky13 Commenting on PRs was just using issue.Comment IIRC. The only special code was in pull.go

@aliechti
Copy link

Is there any progress on this?

@lunny
Copy link
Member

lunny commented Jun 13, 2018

@thejahweh there is not still

@cljk
Copy link

cljk commented Oct 22, 2018

It's causing importing to GitLab to fail https://gitlab.com/gitlab-org/gitlab-ce/issues/31480#note_58059568

Can confirm it on my install - since I tried a migration of some projects to gitlab.


[Macaron] 2018-10-22 14:25:23: Completed GET /api/v1/repos/xxREDACTEDxx/xxREDACTEDxx/pulls/comments?page=1&per_page=100 404 Not Found in 3.914201ms

gitea:1.6

@stale
Copy link

stale bot commented Jan 6, 2019

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs during the next 2 weeks. Thank you for your contributions.

@stale stale bot added the issue/stale label Jan 6, 2019
@livelace
Copy link

Bump.

Gitea Version: 19e651c
Gitlab-ce: 11.6.0

@stale stale bot removed the issue/stale label Jan 19, 2019
@stale
Copy link

stale bot commented Mar 20, 2019

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs during the next 2 weeks. Thank you for your contributions.

@stale stale bot added the issue/stale label Mar 20, 2019
@lunny lunny added the issue/confirmed Issue has been reviewed and confirmed to be present or accepted to be implemented label Mar 21, 2019
@stale stale bot removed the issue/stale label Mar 21, 2019
@debMan
Copy link

debMan commented Nov 28, 2019

Importing from gitea to GitLab has some problems which I've faced and listed here:

  1. API pagination on issue importing problem, which described in detail at API paginater problem #9165.
    I've fixed this in wrong way, changed per page rows from 10 to 1000 on modules/setting/setting.go from IssuePagingNum: 10, to IssuePagingNum: 1000, and re-compiled. The issue importing process is done.
  2. Importing pull requests to GitLab which I'm working on

Update:
Importing pull requests to GitLab is not possible, so comment import_pull_requests inside def execute on /opt/gitlab/embedded/service/gitlab-rails/lib/gitlab/legacy_github_import/importer.rb

@6543
Copy link
Member

6543 commented Feb 1, 2020

I think we can close this issue?

https://try.gitea.io/api/swagger#/repository/repoListPullRequests

the endpoint is implemented

@lunny lunny closed this as completed Feb 1, 2020
@go-gitea go-gitea locked and limited conversation to collaborators Nov 24, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
issue/confirmed Issue has been reviewed and confirmed to be present or accepted to be implemented issue/regression Indicates a previously functioning feature or behavior that has broken or regressed after a change modifies/api This PR adds API routes or modifies them
Projects
None yet
Development

No branches or pull requests

8 participants